diff mbox

[U-Boot,v2,2/6] spi: Fix flag collision for SST_WP

Message ID 1418393176-16002-3-git-send-email-jagannadh.teki@gmail.com
State Accepted
Delegated to: Simon Glass
Headers show

Commit Message

Jagan Teki Dec. 12, 2014, 2:06 p.m. UTC
From: Simon Glass <sjg@chromium.org>

At present SECT_4K is the same as SST_WP so we cannot tell these apart. Fix
this so that the table in sf_params.c can be used correctly.

Reported-by: Jens Rottmann <Jens.Rottmann@adlinktech.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
---
 drivers/mtd/spi/sf_internal.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Simon Glass Dec. 14, 2014, 5:35 a.m. UTC | #1
On 12 December 2014 at 07:06, Jagannadha Sutradharudu Teki
<jagannadh.teki@gmail.com> wrote:
> From: Simon Glass <sjg@chromium.org>
>
> At present SECT_4K is the same as SST_WP so we cannot tell these apart. Fix
> this so that the table in sf_params.c can be used correctly.
>
> Reported-by: Jens Rottmann <Jens.Rottmann@adlinktech.com>
> Signed-off-by: Simon Glass <sjg@chromium.org>
> Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
> ---
>  drivers/mtd/spi/sf_internal.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to u-boot-x86, thanks!
diff mbox

Patch

diff --git a/drivers/mtd/spi/sf_internal.h b/drivers/mtd/spi/sf_internal.h
index e159f04..7218e69 100644
--- a/drivers/mtd/spi/sf_internal.h
+++ b/drivers/mtd/spi/sf_internal.h
@@ -41,6 +41,7 @@  enum {
 	SECT_32K	= 1 << 1,
 	E_FSR		= 1 << 2,
 	WR_QPP		= 1 << 3,
+	SST_WP		= 1 << 4,
 };
 
 #define SPI_FLASH_3B_ADDR_LEN		3
@@ -104,7 +105,6 @@  enum {
 
 /* SST specific */
 #ifdef CONFIG_SPI_FLASH_SST
-# define SST_WP		0x01	/* Supports AAI word program */
 # define CMD_SST_BP		0x02    /* Byte Program */
 # define CMD_SST_AAI_WP	0xAD	/* Auto Address Incr Word Program */