]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
Xilinx: ARM: Fix warnings in qspi driver
authorJoe Hershberger <joe.hershberger@ni.com>
Tue, 5 Jun 2012 03:16:42 +0000 (22:16 -0500)
committerJohn Linn <john.linn@xilinx.com>
Tue, 5 Jun 2012 17:37:04 +0000 (10:37 -0700)
Use the unused flags
Don't build unused functions

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
board/xilinx/zynq_common/xilinx_qspi.c
board/xilinx/zynq_common/xilinx_qspips.c

index c7b40c70efa386510e3f19872b88f47d923f05d8..e88829f8595949bfce5bf75b1e7aa46b5c97721f 100644 (file)
@@ -97,13 +97,6 @@ void spi_free_slave(struct spi_slave *slave)
        free(pspi);
 }
 
-static void spi_portmux(struct spi_slave *slave)
-{
-#ifdef DEBUG
-       printf("spi_portmux: slave: 0x%08x\n", (u32)slave);
-#endif
-}
-
 int spi_claim_bus(struct spi_slave *slave)
 {
 #ifdef DEBUG
index aaa7c47f58c72fa889b81a590e2f3bbb53cfd199..a144c4a7fe1627bffca42867816556ce2ad500cd 100755 (executable)
 
 #define spin_lock_irqsave(__X__, flags) \
                flags = 0;
-#define spin_unlock_irqrestore(__X__, __Y__)
+#define spin_unlock_irqrestore(__X__, flags) \
+               flags |= 0;
 #define MODULE_ALIAS(__X__)
 
-#define dev_dbg(dev, format, arg...)            \
+#define dev_dbg(dev, format, arg...) \
         printf(format , ## arg)
 
-#define dev_err(dev, format, arg...)            \
+#define dev_err(dev, format, arg...) \
         printf(format , ## arg)
 
-#define wait_for_completion(__X__)                     \
-       {                                                                               \
-               u32 data;                                                       \
-                                                                                       \
-               do {                                                            \
-                       data = xqspips_irq_poll(xqspi);\
-               } while (data == 0);    \
+#define wait_for_completion(__X__) \
+       { \
+               u32 data; \
+\
+               do { \
+                       data = xqspips_irq_poll(xqspi); \
+               } while (data == 0); \
        }
 
 #define __devinit
@@ -579,6 +580,7 @@ int xqspips_setup_transfer(struct spi_device *qspi,
        return 0;
 }
 
+#ifdef LINUX_ONLY_NOT_UBOOT
 /**
  * xqspips_setup - Configure the QSPI controller
  * @qspi:      Pointer to the spi_device structure
@@ -602,6 +604,7 @@ static int xqspips_setup(struct spi_device *qspi)
 
        return xqspips_setup_transfer(qspi, NULL);
 }
+#endif
 
 /**
  * xqspips_fill_tx_fifo - Fills the TX FIFO with as many bytes as possible