iPXE
Data Fields
spi_device Struct Reference

An SPI device. More...

#include <spi.h>

Data Fields

struct nvs_device nvs
 NVS device.
struct spi_busbus
 SPI bus to which device is attached.
unsigned int slave
 Slave number.
unsigned int command_len
 Command length, in bits.
unsigned int address_len
 Address length, in bits.
unsigned int munge_address: 1
 Address is munged.

Detailed Description

An SPI device.

This data structure represents a physical SPI device attached to an SPI bus.

Definition at line 86 of file spi.h.


Field Documentation

SPI bus to which device is attached.

Definition at line 90 of file spi.h.

Referenced by falcon_init_spi_device(), ifec_init_eeprom(), realtek_detect(), realtek_probe(), rtl818x_probe(), spi_read(), spi_wait(), spi_write(), threewire_read(), and threewire_write().

unsigned int spi_device::slave

Slave number.

Definition at line 92 of file spi.h.

Referenced by spi_bit_rw().

Command length, in bits.

Definition at line 94 of file spi.h.

Referenced by spi_bit_rw().

Address length, in bits.

Definition at line 96 of file spi.h.

Referenced by falcon_spi_rw(), ifec_init_eeprom(), spi_bit_rw(), and threewire_detect_address_len().

Address is munged.

Some devices with 9-bit addresses (e.g. AT25040A EEPROM) use bit 3 of the command byte as address bit A8, rather than having a two-byte address. If this flag is set, then commands should be munged in this way.

Definition at line 104 of file spi.h.

Referenced by spi_read(), and spi_write().


The documentation for this struct was generated from the following file: