SPI APIs

This topic provides details for the SPI APIs.

spi_register_driver

Synopsis
int spi_register_driver(struct spi_driver *sdrv)
Description Registers the driver of an SPI device.
Parameter
  • sdrv: SPI driver type, includeing the SPI device name, probe interface information, and so on

Return
  • Success: 0
  • Failure: Any value other than 0

spi_message_init

Synopsis
void spi_message_init(struct spi_message *m)
Description Initializes an SPI message structure to clear or initialize a transfer queue.
Parameter
  • m: The SPI message type

Return None