'\" t .\" Title: __platform_create_bundle .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: January 2017 .\" Manual: Device drivers infrastructure .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "__PLATFORM_CREATE_BU" "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" __platform_create_bundle \- register driver and create corresponding device .SH "SYNOPSIS" .HP \w'struct\ platform_device\ *\ __platform_create_bundle('u .BI "struct platform_device * __platform_create_bundle(struct\ platform_driver\ *\ " "driver" ", int\ (*" "probe" ")\ (struct\ platform_device\ *), struct\ resource\ *\ " "res" ", unsigned\ int\ " "n_res" ", const\ void\ *\ " "data" ", size_t\ " "size" ", struct\ module\ *\ " "module" ");" .SH "ARGUMENTS" .PP \fIdriver\fR .RS 4 platform driver structure .RE .PP \fIprobe\fR .RS 4 the driver probe routine, probably from an __init section .RE .PP \fIres\fR .RS 4 set of resources that needs to be allocated for the device .RE .PP \fIn_res\fR .RS 4 number of resources .RE .PP \fIdata\fR .RS 4 platform specific data for this platform device .RE .PP \fIsize\fR .RS 4 size of platform specific data .RE .PP \fImodule\fR .RS 4 module which will be the owner of the driver .RE .SH "DESCRIPTION" .PP Use this in legacy\-style modules that probe hardware directly and register a single platform device and corresponding platform driver\&. .PP Returns struct platform_device pointer on success, or \fBERR_PTR\fR on error\&. .SH "COPYRIGHT" .br