Skip to content

[HELP] STM32 Standardized Flash Terminology #16170

Closed
@stbenn

Description

@stbenn

Description

I will limit this discussion to STM32 architecture, as I am not familiar with other architectures.

I have been working on a progmem flash driver for the STM32H5, and noticed inconsistent terminology for "block" and "page" across other STM32 driver implementations (mainly stm32h743xx_flash.c and arch/arm/src/stm32u5/stm32_flash.c).

A quick google search for the generally accepted meanings:

  • Block = smallest unit of flash that can be erased.
  • Page = smallest unit that can be programmed (written)

The H7 driver appears to mostly adhere to the generally accepted meanings, but the U5 uses "page" to refer to what is actually a block, and does not implement pages (referring to smallest unit that can be programmed).

Additionally, drivers/mtd/mtd_progmem.c::progmem_bwrite() appears to use "block" to refer to pages.

Am I misunderstanding the implementations or am I correct that there doesn't seem to be consistent usage of "block" and "page"?

I want to make sure I understand this before creating a PR for the H5 driver so I don't add to the problem (if there is one)!

Verification

  • I have verified before submitting the report.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions