]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
mtd: spi-nor: winbond: Fix locking support for w25q64jvm
authorEliav Farber <farbere@amazon.com>
Wed, 18 Feb 2026 14:35:23 +0000 (14:35 +0000)
committerPratyush Yadav (Google) <pratyush@kernel.org>
Mon, 30 Mar 2026 14:07:11 +0000 (14:07 +0000)
commit5eb130177693c3470cafaf721af41c60dd891cc7
tree0115cbfedf8ea3b32ebc3ad752691324e2a09aae
parent0f0b444be36c098d34a155bbe9e5a2f714a462fb
mtd: spi-nor: winbond: Fix locking support for w25q64jvm

The Winbond w25q64jvm supports block protection through the Status
Register (SR) and provides a Top/Bottom (TB) protection bit.

Enable SPI_NOR_HAS_LOCK and SPI_NOR_HAS_TB for this device to
properly describe its locking capabilities.

The device uses Status Register bit 5 as the TB bit and supports only
three Block Protect (BP) bits. Therefore, do not set SPI_NOR_TB_SR_BIT6
or SPI_NOR_4BIT_BP.

Reference:
https://www.winbond.com/hq/support/documentation/levelOne.jsp?__locale=en&DocNo=DA00-W25Q64JV.1

Signed-off-by: Eliav Farber <farbere@amazon.com>
Reviewed-by: Michael Walle <mwalle@kernel.org>
Signed-off-by: Pratyush Yadav (Google) <pratyush@kernel.org>
drivers/mtd/spi-nor/winbond.c