From: Jagan Teki Date: Mon, 28 Dec 2015 16:38:40 +0000 (+0530) Subject: sf: Make IO modes at last in read modes X-Git-Tag: baikal/mips/sdk5.9~8751 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=1c17f5ec571cac6e0867f64607b052d6ffa0b1c1;p=uboot.git sf: Make IO modes at last in read modes SLOW, FAST, DUAL, DUAL_IO, QUAD, QUAD_IO changed order to SLOW, FAST, DUAL, QUAD, DUAL_IO, QUAD_IO Cc: Simon Glass Cc: Michal Simek Cc: Siva Durga Prasad Paladugu Tested-by: Jagan Teki Reviewed-by: Bin Meng Signed-off-by: Jagan Teki --- diff --git a/drivers/mtd/spi/sf_internal.h b/drivers/mtd/spi/sf_internal.h index 55ba81e87b..007a5a085c 100644 --- a/drivers/mtd/spi/sf_internal.h +++ b/drivers/mtd/spi/sf_internal.h @@ -25,8 +25,8 @@ enum spi_read_cmds { ARRAY_SLOW = BIT(0), ARRAY_FAST = BIT(1), DUAL_OUTPUT_FAST = BIT(2), - DUAL_IO_FAST = BIT(3), - QUAD_OUTPUT_FAST = BIT(4), + QUAD_OUTPUT_FAST = BIT(3), + DUAL_IO_FAST = BIT(4), QUAD_IO_FAST = BIT(5), }; diff --git a/drivers/mtd/spi/spi_flash.c b/drivers/mtd/spi/spi_flash.c index 5766c187f9..a567414669 100644 --- a/drivers/mtd/spi/spi_flash.c +++ b/drivers/mtd/spi/spi_flash.c @@ -975,8 +975,8 @@ int spi_flash_scan(struct spi_flash *flash) CMD_READ_ARRAY_SLOW, CMD_READ_ARRAY_FAST, CMD_READ_DUAL_OUTPUT_FAST, - CMD_READ_DUAL_IO_FAST, CMD_READ_QUAD_OUTPUT_FAST, + CMD_READ_DUAL_IO_FAST, CMD_READ_QUAD_IO_FAST }; /* Read the ID codes */ diff --git a/include/spi.h b/include/spi.h index 80f8523076..85866a27fc 100644 --- a/include/spi.h +++ b/include/spi.h @@ -30,7 +30,7 @@ #define SPI_RX_SLOW BIT(0) /* receive with 1 wire slow */ #define SPI_RX_FAST BIT(1) /* receive with 1 wire fast */ #define SPI_RX_DUAL BIT(2) /* receive with 2 wires */ -#define SPI_RX_QUAD BIT(4) /* receive with 4 wires */ +#define SPI_RX_QUAD BIT(3) /* receive with 4 wires */ /* SPI bus connection options - see enum spi_dual_flash */ #define SPI_CONN_DUAL_SHARED (1 << 0)