spi_nor_read...p_dma_unsafe(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… spi_nor_read_sfdp_dma_unsafe(9) πŸ’…

okay so this is the Kernel API Manual page for the long-name queen herself, and she's here to read Serial Flash Discoverable Parameters. bestie, the function name is doing cardio, but the plot is simple. ✨


✨ NAME ✨

spi_nor_read_sfdp_dma_unsafe β€” read Serial Flash Discoverable Parameters.

🌸 SYNOPSIS 🌸

int spi_nor_read_sfdp_dma_unsafe (struct spi_nor *nor , u32 addr , size_t len , void *buf );

πŸŽ€ ARGUMENTS πŸŽ€

  • nor β€” pointer to a struct spi_nor.
  • addr β€” offset in the SFDP area to start reading data from.
  • len β€” number of bytes to read.
  • buf β€” buffer where the SFDP data are copied into.

πŸ¦‹ DESCRIPTION πŸ¦‹

so the move here is: this wraps spi_nor_read_sfdp using a kmalloc'ed bounce buffer, because buf is now not guaranteed to be dma-safe. that's the whole vibe. 🫢

πŸ’œ RETURN πŸ’œ

  • -ENOMEM if kmalloc fails.
  • the return code of spi_nor_read_sfdp otherwise.

πŸ”₯ SEE ALSO πŸ”₯

Kernel file: ./drivers/mtd/spi-nor/sfdp.c


okay bestie, that's the whole page πŸ’– β€” source/version: ./drivers/mtd/spi-nor, dated October 2026, and the manual page is spi_nor_read...p_dma_unsafe(9). slay. πŸ’…

πŸ“¦ where this page comes from