]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
spi: zynq_qspi: Remove command merge feature
authorJohn Linn <john.linn@xilinx.com>
Wed, 5 Dec 2012 20:17:46 +0000 (12:17 -0800)
committerMichal Simek <michal.simek@xilinx.com>
Fri, 14 Dec 2012 10:15:46 +0000 (11:15 +0100)
The command merge feature has been de-featured such
that the driver should not be using it. It works fine
without it but there may be a minor performance degrade.

The command merge feature was in bit 26 of the linear
configuration register before it was removed. Magic
values are also removed for clarity.

Signed-off-by: John Linn <john.linn@xilinx.com>
Acked-by: Michal Simek <michal.simek@xilinx.com>
drivers/spi/zynq_qspi.c

index 642241d0fc25d04c06ecbeb5d01ba06108307c62..9146ee92985d324dc301fa39ff4e753e4b24dd84 100755 (executable)
@@ -168,6 +168,19 @@ typedef enum irqreturn irqreturn_t;
  */
 #define XQSPIPSS_ENABLE_ENABLE_MASK    0x00000001 /* QSPI Enable Bit Mask */
 
+/*
+ * QSPI Linear Configuration Register
+ *
+ * It is named Linear Configuration but it controls other modes when not in
+ * linear mode also.
+ */
+#define XQSPIPS_LCFG_TWO_MEM_MASK      0x40000000 /* QSPI Enable Bit Mask */
+#define XQSPIPS_LCFG_SEP_BUS_MASK      0x20000000 /* QSPI Enable Bit Mask */
+
+#define XQSPIPS_LCFG_DUMMY_SHIFT       8
+
+#define XQSPIPS_FAST_READ_QOUT_CODE    0x6B    /* read instruction code */
+
 /*
  * The modebits configurable by the driver to make the SPI support different
  * data formats
@@ -363,7 +376,10 @@ void xqspips_init_hw(void __iomem *regs_base, unsigned int is_dual)
        if (is_dual == 1)
                /* Enable two memories on seperate buses */
                xqspips_write(regs_base + XQSPIPSS_LINEAR_CFG_OFFSET,
-                               0x6400016B);
+                       (XQSPIPS_LCFG_TWO_MEM_MASK |
+                        XQSPIPS_LCFG_SEP_BUS_MASK |
+                        (1 << XQSPIPS_LCFG_DUMMY_SHIFT) |
+                        XQSPIPS_FAST_READ_QOUT_CODE));
 
        xqspips_write(regs_base + XQSPIPSS_ENABLE_OFFSET,
                        XQSPIPSS_ENABLE_ENABLE_MASK);