spi: Remove out of date comment and reorder flash table
What is described by the comment has already been fixed in f0d038f4
(flash: use two bytes of device ID to identify stmicro chips).
This also means that STM_ID_N25Q128 doesn't have to be at the top of
stmicro_spi_flash_table anymore.
TEST=Untested, due to lack of hardware
Change-Id: I7a9e9a0cdfdb1cf34e914e186fc6957c1d9b5ca6
Signed-off-by: David Imhoff <dimhoff_devel@xs4all.nl>
Reviewed-on: http://review.coreboot.org/10068
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
This commit is contained in:
parent
8d4377b56d
commit
7249572b80
|
@ -60,11 +60,6 @@
|
||||||
#define STM_ID_N25Q256A 0xba19
|
#define STM_ID_N25Q256A 0xba19
|
||||||
#define STM_ID_N25Q128 0xbb18
|
#define STM_ID_N25Q128 0xbb18
|
||||||
|
|
||||||
/* Some SPI flash share the same .idcode1 (idcode[2]). To handle this without
|
|
||||||
* (possibly) breaking existing implementations, add the new device at the top
|
|
||||||
* of the flash table array and set its .idcode1 = STM_ID_USE_ALT_ID. The .id
|
|
||||||
* is then (idcode[1] << 8 | idcode[2]).
|
|
||||||
*/
|
|
||||||
struct stmicro_spi_flash_params {
|
struct stmicro_spi_flash_params {
|
||||||
u16 device_id;
|
u16 device_id;
|
||||||
u8 op_erase;
|
u8 op_erase;
|
||||||
|
@ -87,14 +82,6 @@ static inline struct stmicro_spi_flash *to_stmicro_spi_flash(struct spi_flash
|
||||||
}
|
}
|
||||||
|
|
||||||
static const struct stmicro_spi_flash_params stmicro_spi_flash_table[] = {
|
static const struct stmicro_spi_flash_params stmicro_spi_flash_table[] = {
|
||||||
{
|
|
||||||
.device_id = STM_ID_N25Q128,
|
|
||||||
.op_erase = CMD_M25PXX_SSE,
|
|
||||||
.page_size = 256,
|
|
||||||
.pages_per_sector = 16,
|
|
||||||
.nr_sectors = 4096,
|
|
||||||
.name = "N25Q128",
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
.device_id = STM_ID_M25P10,
|
.device_id = STM_ID_M25P10,
|
||||||
.op_erase = CMD_M25PXX_SE,
|
.op_erase = CMD_M25PXX_SE,
|
||||||
|
@ -159,6 +146,14 @@ static const struct stmicro_spi_flash_params stmicro_spi_flash_table[] = {
|
||||||
.nr_sectors = 64,
|
.nr_sectors = 64,
|
||||||
.name = "M25P128",
|
.name = "M25P128",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
.device_id = STM_ID_N25Q128,
|
||||||
|
.op_erase = CMD_M25PXX_SSE,
|
||||||
|
.page_size = 256,
|
||||||
|
.pages_per_sector = 16,
|
||||||
|
.nr_sectors = 4096,
|
||||||
|
.name = "N25Q128",
|
||||||
|
},
|
||||||
{
|
{
|
||||||
.device_id = STM_ID_N25Q256A,
|
.device_id = STM_ID_N25Q256A,
|
||||||
.page_size = 256,
|
.page_size = 256,
|
||||||
|
|
Loading…
Reference in New Issue