STRUCT PCH_SPI_DATA(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

struct pch_spi_data(9) πŸ’…βœ¨

okay so bestie, this is the Kernel API Manual page for struct pch_spi_data(9) β€” literally the struct that holds the SPI channel specific details. no cap, it's giving β€œdriver state goes here” energy, and we're gonna go through every single member because we do not skip in this house. πŸ’–


🌸 NAME 🌸

struct pch_spi_data β€” Holds the SPI channel specific details. That's the whole vibe: channel-specific details, held. iconic. πŸ’…


✨ SYNOPSIS ✨

here's the struct in all its glory, verbatim, character for character β€” do not touch, just admire:

struct pch_spi_data {
    void __iomem *io_remap_addr;
    unsigned long io_base_addr;
    struct spi_controller *host;
    struct work_struct work;
    wait_queue_head_t wait;
    u8 transfer_complete;
    u8 bcurrent_msg_processing;
    spinlock_t lock;
    struct list_head queue;
    u8 status;
    u32 bpw_len;
    u8 transfer_active;
    u32 tx_index;
    u32 rx_index;
    u16 *pkt_tx_buff;
    u16 *pkt_rx_buff;
    u8 n_curnt_chip;
    struct spi_device *current_chip;
    struct spi_message *current_msg;
    struct spi_transfer *cur_trans;
    struct pch_spi_board_data *board_dat;
    struct platform_device  *plat_dev;
    int ch;
    struct pch_spi_dma_ctrl dma;
    int use_dma;
    u8 irq_reg_sts;
    int save_total_len;
};

🫢 Members 🫢

okay bestie, member-by-member tour, no skipping, we respect the whole struct in this house:

  • io_remap_addr β€” The remapped PCI base address. πŸ’…
  • io_base_addr β€” Base address.
  • host β€” Pointer to the SPI controller structure.
  • work β€” Reference to work queue handler.
  • wait β€” Wait queue for waking up upon receiving an interrupt.
  • transfer_complete β€” Status of SPI Transfer.
  • bcurrent_msg_processing β€” Status flag for message processing.
  • lock β€” Lock for protecting this structure.
  • queue β€” SPI Message queue.
  • status β€” Status of the SPI driver.
  • bpw_len β€” Length of data to be transferred in bits per word.
  • transfer_active β€” Flag showing active transfer.
  • tx_index β€” Transmit data count; for bookkeeping during transfer.
  • rx_index β€” Receive data count; for bookkeeping during transfer.
  • pkt_tx_buff β€” Buffer for data to be transmitted.
  • pkt_rx_buff β€” Buffer for received data.
  • n_curnt_chip β€” The chip number that this SPI driver currently operates on.
  • current_chip β€” Reference to the current chip that this SPI driver currently operates on.
  • current_msg β€” The current message that this SPI driver is handling.
  • cur_trans β€” The current transfer that this SPI driver is handling.
  • board_dat β€” Reference to the SPI device data structure.
  • plat_dev β€” platform_device structure.
  • ch β€” SPI channel number.
  • dma β€” Local DMA information.
  • use_dma β€” True if DMA is to be used.
  • irq_reg_sts β€” Status of IRQ registration.
  • save_total_len β€” Save length while data is being transferred.

🌈 SEE ALSO 🌈

go look at these, bestie β€” the related kernel file and API pages are all right here:


k bye bestie β€” this iconic page is from the Kernel API Manual, the source/version footer says ./drivers/spi, it's dated October 2026, and it's literally the struct pch_spi_data(9) page. slay, stay hydrated, read your manpages. πŸ’…βœ¨πŸ«Ά

πŸ“¦ where this page comes from