aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/spi-nor/fsl-quadspi.c
diff options
context:
space:
mode:
authorBrian Norris <computersforpeace@gmail.com>2014-04-08 22:16:49 -0400
committerBrian Norris <computersforpeace@gmail.com>2014-04-14 14:23:00 -0400
commit58b89a1f4c2a65b10b8f7b90b6ff2161b19bb0d1 (patch)
tree4c66af58cbfddd308c20271ae68f4959c6644117 /drivers/mtd/spi-nor/fsl-quadspi.c
parentb02e7f3ef0beb72da8fc64542f0ac977996ec56b (diff)
mtd: spi-nor: unify read opcode variants with ST SPI FSM
serial_flash_cmds.h defines our opcodes a little differently. Let's borrow its naming, since it's borrowed from the SFDP standard, and it's more extensible. This prepares us for merging serial_flash_cmds.h and spi-nor.h opcode listing. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Reviewed-by: Marek Vasut <marex@denx.de> Acked-by: Huang Shijie <b32955@freescale.com>
Diffstat (limited to 'drivers/mtd/spi-nor/fsl-quadspi.c')
-rw-r--r--drivers/mtd/spi-nor/fsl-quadspi.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/mtd/spi-nor/fsl-quadspi.c b/drivers/mtd/spi-nor/fsl-quadspi.c
index 2977f026f39d..b41bbbc531ff 100644
--- a/drivers/mtd/spi-nor/fsl-quadspi.c
+++ b/drivers/mtd/spi-nor/fsl-quadspi.c
@@ -294,12 +294,12 @@ static void fsl_qspi_init_lut(struct fsl_qspi *q)
294 lut_base = SEQID_QUAD_READ * 4; 294 lut_base = SEQID_QUAD_READ * 4;
295 295
296 if (q->nor_size <= SZ_16M) { 296 if (q->nor_size <= SZ_16M) {
297 cmd = SPINOR_OP_QUAD_READ; 297 cmd = SPINOR_OP_READ_1_1_4;
298 addrlen = ADDR24BIT; 298 addrlen = ADDR24BIT;
299 dummy = 8; 299 dummy = 8;
300 } else { 300 } else {
301 /* use the 4-byte address */ 301 /* use the 4-byte address */
302 cmd = SPINOR_OP_QUAD_READ; 302 cmd = SPINOR_OP_READ_1_1_4;
303 addrlen = ADDR32BIT; 303 addrlen = ADDR32BIT;
304 dummy = 8; 304 dummy = 8;
305 } 305 }
@@ -388,7 +388,7 @@ static void fsl_qspi_init_lut(struct fsl_qspi *q)
388static int fsl_qspi_get_seqid(struct fsl_qspi *q, u8 cmd) 388static int fsl_qspi_get_seqid(struct fsl_qspi *q, u8 cmd)
389{ 389{
390 switch (cmd) { 390 switch (cmd) {
391 case SPINOR_OP_QUAD_READ: 391 case SPINOR_OP_READ_1_1_4:
392 return SEQID_QUAD_READ; 392 return SEQID_QUAD_READ;
393 case SPINOR_OP_WREN: 393 case SPINOR_OP_WREN:
394 return SEQID_WREN; 394 return SEQID_WREN;