'\" t .\" Title: spi_new_device .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Serial Peripheral Interface (SPI) .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "SPI_NEW_DEVICE" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Serial Peripheral Interface (S" .\" ----------------------------------------------------------------- .\" * 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" spi_new_device \- instantiate one new SPI device .SH "SYNOPSIS" .HP \w'struct\ spi_device\ *\ spi_new_device('u .BI "struct spi_device * spi_new_device(struct\ spi_master\ *\ " "master" ", struct\ spi_board_info\ *\ " "chip" ");" .SH "ARGUMENTS" .PP \fImaster\fR .RS 4 Controller to which device is connected .RE .PP \fIchip\fR .RS 4 Describes the SPI device .RE .SH "CONTEXT" .PP can sleep .SH "DESCRIPTION" .PP On typical mainboards, this is purely internal; and it\*(Aqs not needed after board init creates the hard\-wired devices\&. Some development platforms may not be able to use spi_register_board_info though, and this is exported so that for example a USB or parport based adapter driver could add devices (which it would learn about out\-of\-band)\&. .SH "RETURN" .PP the new device, or NULL\&. .SH "COPYRIGHT" .br