Skip to content

fix(flash): add W25Q-RV QER 6 support - #19

Open
Xiling Sun (helloxiling) wants to merge 1 commit into
Azure:masterfrom
helloxiling:xsun/sfdp-fix-W25Q-RV-DTR
Open

fix(flash): add W25Q-RV QER 6 support#19
Xiling Sun (helloxiling) wants to merge 1 commit into
Azure:masterfrom
helloxiling:xsun/sfdp-fix-W25Q-RV-DTR

Conversation

@helloxiling

@helloxiling Xiling Sun (helloxiling) commented Aug 5, 2026

Copy link
Copy Markdown

Issue

Winbond W25Q-RV/DTR devices can report SFDP QER 6, which uses QE at SR2 bit 1. SR2 must be read with 35h and written independently with one-byte 31h. The existing SFDP path treats QER 6 as unknown, preventing flash initialization.

Fix

  • Select a dedicated QER 6 mechanism for Winbond W25Q-DTR devices.
  • Read and update QE using one-byte 35h/31h operations.
  • Clear SR1 and SR2 protection independently while preserving QE.
  • Add focused tests for QER selection, QE operations, and protection clearing.

@helloxiling
Xiling Sun (helloxiling) marked this pull request as ready for review August 5, 2026 22:19
adiGlick pushed a commit to Nuvoton-Israel/npcm8xx-tip-fw-project-cerberus that referenced this pull request Aug 10, 2026
Recognizes QER=6 for Winbond W25Q-RV/DTR devices that use JESD216C+ BFPT v1.8+.
- Renames QER_RESERVED1 -> QER_BIT1_SR2_35_31 and QER_RESERVED2 -> QER_RESERVED.
- Adds SPI_FLASH_SFDP_QUAD_QE_BIT1_SR2_35_31 enum: SR2 read via 0x35, written
  independently via 0x31.
- Updates clear_block_protect, enable_quad_spi and is_quad_spi_enabled accordingly.

Based on upstream PR: Azure/Project-Cerberus#19
adiGlick pushed a commit to Nuvoton-Israel/npcm8xx-tip-fw-project-cerberus that referenced this pull request Aug 10, 2026
Recognizes QER=6 for Winbond W25Q-RV/DTR devices that use JESD216C+ BFPT v1.8+.
- Renames QER_RESERVED1 -> QER_BIT1_SR2_35_31 and QER_RESERVED2 -> QER_RESERVED.
- Adds SPI_FLASH_SFDP_QUAD_QE_BIT1_SR2_35_31 enum: SR2 read via 0x35, written
  independently via 0x31.
- Updates clear_block_protect, enable_quad_spi and is_quad_spi_enabled accordingly.

Based on upstream PR: Azure/Project-Cerberus#19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant