Commit 5eb13017 authored by Eliav Farber's avatar Eliav Farber Committed by Pratyush Yadav (Google)
Browse files

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: default avatarEliav Farber <farbere@amazon.com>
Reviewed-by: default avatarMichael Walle <mwalle@kernel.org>
Signed-off-by: default avatarPratyush Yadav (Google) <pratyush@kernel.org>
parent 0f0b444b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -295,6 +295,7 @@ static const struct flash_info winbond_nor_parts[] = {
		.id = SNOR_ID(0xef, 0x70, 0x17),
		.name = "w25q64jvm",
		.size = SZ_8M,
		.flags = SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB,
		.no_sfdp_flags = SECT_4K,
	}, {
		.id = SNOR_ID(0xef, 0x70, 0x18),