diff options
author | Ashish Kumar | 2018-05-07 16:01:47 +0530 |
---|---|---|
committer | Jagan Teki | 2018-05-16 18:56:49 +0530 |
commit | 4eaa2fa16968359ffcf207e63848ed7f3a6e4309 (patch) | |
tree | 2003fc16112c08e273c7c8a4d7140de8700f21bd | |
parent | 39b9e9bc72cef52abb8532ffa92c42be9f010e2f (diff) |
sf: Default page size Spansion flash "S25FS512S" is 256b
page size for JEDEC EXT starting 0x4d00 is 512b,
except JEDEC ID 0x215, 0x216 and 0x220
Signed-off-by: Ashish Kumar <Ashish.Kumar@nxp.com>
[jagan: added proper commit message]
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
-rw-r--r-- | drivers/mtd/spi/spi_flash.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/mtd/spi/spi_flash.c b/drivers/mtd/spi/spi_flash.c index 2911729b289..0ed23175547 100644 --- a/drivers/mtd/spi/spi_flash.c +++ b/drivers/mtd/spi/spi_flash.c @@ -1202,14 +1202,15 @@ int spi_flash_scan(struct spi_flash *flash) flash->shift = (flash->dual_flash & SF_DUAL_PARALLEL_FLASH) ? 1 : 0; flash->page_size = info->page_size; /* - * The Spansion S25FL032P and S25FL064P have 256b pages, yet use the - * 0x4d00 Extended JEDEC code. The rest of the Spansion flashes with - * the 0x4d00 Extended JEDEC code have 512b pages. All of the others - * have 256b pages. + * The Spansion S25FS512S, S25FL032P and S25FL064P have 256b pages, + * yet use the 0x4d00 Extended JEDEC code. The rest of the Spansion + * flashes with the 0x4d00 Extended JEDEC code have 512b pages. + * All of the others have 256b pages. */ if (JEDEC_EXT(info) == 0x4d00) { if ((JEDEC_ID(info) != 0x0215) && - (JEDEC_ID(info) != 0x0216)) + (JEDEC_ID(info) != 0x0216) && + (JEDEC_ID(info) != 0x0220)) flash->page_size = 512; } flash->page_size <<= flash->shift; |