STRUCT SPI_NOR_ERASE_MAP(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct spi_nor_erase_map(9) πŸ’…

okay bestie, so this page lives in the Kernel API Manual and it's literally all about struct spi_nor_erase_map β€” the structure that describes the SPI NOR erase map πŸ—ΊοΈβœ¨ yes, the whole map. main character struct energy fr fr.


🌸 NAME 🌸

struct spi_nor_erase_map β€” the structure that describes the SPI NOR erase map πŸŽ€


✨ SYNOPSIS ✨

struct spi_nor_erase_map {
    struct spi_nor_erase_region     *regions;
    struct spi_nor_erase_region     uniform_region;
    struct spi_nor_erase_type       erase_type[SNOR_ERASE_TYPE_MAX];
    unsigned int                    n_regions;
 };

look at her. four members. immaculate. copy it exactly like that, no cap πŸ’…


🫢 Members 🫢

  • regions β€” an array of erase regions πŸ’– these regions are consecutive in address space, and walking through them is done incrementally. like girl, one after the other, in order, no skipping πŸšΆβ€β™€οΈ
  • uniform_region β€” a pre-allocated erase region for SPI NOR with a uniform sector size. that's the legacy implementation, just so u know 🧚 it's giving "we keep her around for the old stuff"
  • erase_type β€” an array of erase types shared by all the regions πŸ”₯ and listen: the erase types are sorted in ascending order, with the smallest Erase Type size being the first member in the erase_type array. smallest first, periodt πŸ“
  • n_regions β€” number of erase regions. literally just the count, bestie πŸ”’

πŸ‘‘ SEE ALSO πŸ‘‘

  • Kernel file ./drivers/mtd/spi-nor/core.h
  • struct spi_nor_erase_type(9)
  • struct spi_nor_erase_command(9)
  • struct spi_nor_erase_region(9)
  • struct spi_nor_locking_ops(9)
  • struct spi_nor_otp_organization(9)
  • struct spi_nor_otp_ops(9)
  • struct spi_nor_otp(9)
  • struct spi_nor_flash_parameter(9)
  • struct spi_nor_fixups(9)
  • struct spi_nor_id(9)
  • struct flash_info(9)
  • struct spi_nor_manufacturer(9)
  • struct sfdp(9)
  • spi_nor_needs_sfdp(9)

like, the whole friend group showed up πŸŒˆπŸ¦‹


ngl this one's short but she ate πŸ’€ everything above is exactly what's in the page β€” don't go inventing extra behaviour, iykyk πŸ™ˆ

mwah, that's a wrap πŸ“ this lil page comes to u from ./drivers/mtd/spi-nor, dated October 2026, and it's struct spi_nor_erase_map(9) forever and always πŸ’œβœ¨πŸŽ€

πŸ“¦ where this page comes from