#include <spi.h>
Data Fields | |
| unsigned int | mode |
| SPI interface mode. | |
| int(* | rw )(struct spi_bus *bus, struct spi_device *device, unsigned int command, int address, const void *data_out, void *data_in, size_t len) |
| Read/write data via SPI bus. | |
This data structure represents an SPI bus controller capable of issuing commands to attached SPI devices.
Definition at line 126 of file spi.h.
| unsigned int spi_bus::mode |
SPI interface mode.
This is the bitwise OR of zero or more of SPI_MODE_CPHA and SPI_MODE_CPOL. It is also the number conventionally used to describe the SPI interface mode. For example, SPI mode 1 is the mode in which CPOL=0 and CPHA=1, which therefore corresponds to a mode value of (0|SPI_MODE_CPHA) which, happily, equals 1.
Definition at line 136 of file spi.h.
Referenced by ifec_init_eeprom(), natsemi_init_eeprom(), rtl818x_probe(), rtl_init_eeprom(), spi_bit_rw(), spi_bit_set_slave_select(), spi_bit_transfer(), threewire_read(), and threewire_write().
| int( * spi_bus::rw)(struct spi_bus *bus, struct spi_device *device, unsigned int command, int address, const void *data_out, void *data_in, size_t len) |
Read/write data via SPI bus.
| bus | SPI bus | |
| device | SPI device | |
| command | Command | |
| address | Address to read/write (<0 for no address) | |
| data_out | TX data buffer (or NULL) | |
| data_in | RX data buffer (or NULL) | |
| len | Length of data buffer(s) |
Referenced by falcon_probe_spi(), init_spi_bit_basher(), spi_read(), spi_wait(), spi_write(), threewire_read(), and threewire_write().
1.5.7.1