aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-dw.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/spi/spi-dw.h')
-rw-r--r--drivers/spi/spi-dw.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index 6d2acad34f64..83a103a76481 100644
--- a/drivers/spi/spi-dw.h
+++ b/drivers/spi/spi-dw.h
@@ -74,6 +74,10 @@
74#define SPI_INT_RXFI (1 << 4) 74#define SPI_INT_RXFI (1 << 4)
75#define SPI_INT_MSTI (1 << 5) 75#define SPI_INT_MSTI (1 << 5)
76 76
77/* Bit fields in DMACR */
78#define SPI_DMA_RDMAE (1 << 0)
79#define SPI_DMA_TDMAE (1 << 1)
80
77/* TX RX interrupt level threshold, max can be 256 */ 81/* TX RX interrupt level threshold, max can be 256 */
78#define SPI_INT_THRESHOLD 32 82#define SPI_INT_THRESHOLD 32
79 83
@@ -140,7 +144,6 @@ struct dw_spi {
140 dma_addr_t dma_addr; /* phy address of the Data register */ 144 dma_addr_t dma_addr; /* phy address of the Data register */
141 struct dw_spi_dma_ops *dma_ops; 145 struct dw_spi_dma_ops *dma_ops;
142 void *dma_priv; /* platform relate info */ 146 void *dma_priv; /* platform relate info */
143 struct pci_dev *dmac;
144 147
145 /* Bus interface info */ 148 /* Bus interface info */
146 void *priv; 149 void *priv;
@@ -217,11 +220,11 @@ static inline void spi_umask_intr(struct dw_spi *dws, u32 mask)
217 * Each SPI slave device to work with dw_api controller should 220 * Each SPI slave device to work with dw_api controller should
218 * has such a structure claiming its working mode (PIO/DMA etc), 221 * has such a structure claiming its working mode (PIO/DMA etc),
219 * which can be save in the "controller_data" member of the 222 * which can be save in the "controller_data" member of the
220 * struct spi_device 223 * struct spi_device.
221 */ 224 */
222struct dw_spi_chip { 225struct dw_spi_chip {
223 u8 poll_mode; /* 0 for contoller polling mode */ 226 u8 poll_mode; /* 1 for controller polling mode */
224 u8 type; /* SPI/SSP/Micrwire */ 227 u8 type; /* SPI/SSP/MicroWire */
225 u8 enable_dma; 228 u8 enable_dma;
226 void (*cs_control)(u32 command); 229 void (*cs_control)(u32 command);
227}; 230};