'\" t .\" Title: dmi_find_device .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: June 2017 .\" Manual: Firmware Interfaces .\" Source: Kernel Hackers Manual 4.11.3 .\" Language: English .\" .TH "DMI_FIND_DEVICE" "9" "June 2017" "Kernel Hackers Manual 4\&.11\&" "Firmware Interfaces" .\" ----------------------------------------------------------------- .\" * 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" dmi_find_device \- find onboard device by type/name .SH "SYNOPSIS" .HP \w'const\ struct\ dmi_device\ *\ dmi_find_device('u .BI "const struct dmi_device * dmi_find_device(int\ " "type" ", const\ char\ *\ " "name" ", const\ struct\ dmi_device\ *\ " "from" ");" .SH "ARGUMENTS" .PP \fIint type\fR .RS 4 device type or \fBDMI_DEV_TYPE_ANY\fR to match all device types .RE .PP \fIconst char * name\fR .RS 4 device name string or \fBNULL\fR to match all .RE .PP \fIconst struct dmi_device * from\fR .RS 4 previous device found in search, or \fBNULL\fR for new search\&. .RE .SH "DESCRIPTION" .PP Iterates through the list of known onboard devices\&. If a device is found with a matching \fItype\fR and \fIname\fR, a pointer to its device structure is returned\&. Otherwise, \fBNULL\fR is returned\&. A new search is initiated by passing \fBNULL\fR as the \fIfrom\fR argument\&. If \fIfrom\fR is not \fBNULL\fR, searches continue from next device\&. .SH "COPYRIGHT" .br