'\" t .\" Title: __class_create .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Device drivers infrastructure .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "__CLASS_CREATE" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Device drivers infrastructure" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" __class_create \- create a struct class structure .SH "SYNOPSIS" .HP \w'struct\ class\ *\ __class_create('u .BI "struct class * __class_create(struct\ module\ *\ " "owner" ", const\ char\ *\ " "name" ", struct\ lock_class_key\ *\ " "key" ");" .SH "ARGUMENTS" .PP \fIowner\fR .RS 4 pointer to the module that is to \(lqown\(rq this struct class .RE .PP \fIname\fR .RS 4 pointer to a string for the name of this class\&. .RE .PP \fIkey\fR .RS 4 the lock_class_key for this class; used by mutex lock debugging .RE .SH "DESCRIPTION" .PP This is used to create a struct class pointer that can then be used in calls to \fBdevice_create\fR\&. .PP Returns struct class pointer on success, or \fBERR_PTR\fR on error\&. .PP Note, the pointer created here is to be destroyed when finished by making a call to \fBclass_destroy\fR\&. .SH "COPYRIGHT" .br