diff options
Diffstat (limited to 'drivers/net/caif/caif_spi_slave.c')
-rw-r--r-- | drivers/net/caif/caif_spi_slave.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/drivers/net/caif/caif_spi_slave.c b/drivers/net/caif/caif_spi_slave.c index 2111dbfea6fe..b009e03cda9e 100644 --- a/drivers/net/caif/caif_spi_slave.c +++ b/drivers/net/caif/caif_spi_slave.c | |||
@@ -36,10 +36,15 @@ static inline int forward_to_spi_cmd(struct cfspi *cfspi) | |||
36 | #endif | 36 | #endif |
37 | 37 | ||
38 | int spi_frm_align = 2; | 38 | int spi_frm_align = 2; |
39 | int spi_up_head_align = 1; | 39 | |
40 | int spi_up_tail_align; | 40 | /* |
41 | int spi_down_head_align = 3; | 41 | * SPI padding options. |
42 | int spi_down_tail_align = 1; | 42 | * Warning: must be a base of 2 (& operation used) and can not be zero ! |
43 | */ | ||
44 | int spi_up_head_align = 1 << 1; | ||
45 | int spi_up_tail_align = 1 << 0; | ||
46 | int spi_down_head_align = 1 << 2; | ||
47 | int spi_down_tail_align = 1 << 1; | ||
43 | 48 | ||
44 | #ifdef CONFIG_DEBUG_FS | 49 | #ifdef CONFIG_DEBUG_FS |
45 | static inline void debugfs_store_prev(struct cfspi *cfspi) | 50 | static inline void debugfs_store_prev(struct cfspi *cfspi) |
@@ -93,7 +98,7 @@ void cfspi_xfer(struct work_struct *work) | |||
93 | 98 | ||
94 | cfspi_dbg_state(cfspi, CFSPI_STATE_FETCH_PKT); | 99 | cfspi_dbg_state(cfspi, CFSPI_STATE_FETCH_PKT); |
95 | 100 | ||
96 | /* Copy commited SPI frames after the SPI indication. */ | 101 | /* Copy committed SPI frames after the SPI indication. */ |
97 | ptr = (u8 *) cfspi->xfer.va_tx; | 102 | ptr = (u8 *) cfspi->xfer.va_tx; |
98 | ptr += SPI_IND_SZ; | 103 | ptr += SPI_IND_SZ; |
99 | len = cfspi_xmitfrm(cfspi, ptr, cfspi->tx_cpck_len); | 104 | len = cfspi_xmitfrm(cfspi, ptr, cfspi->tx_cpck_len); |
@@ -153,7 +158,7 @@ void cfspi_xfer(struct work_struct *work) | |||
153 | 158 | ||
154 | cfspi_dbg_state(cfspi, CFSPI_STATE_SIG_ACTIVE); | 159 | cfspi_dbg_state(cfspi, CFSPI_STATE_SIG_ACTIVE); |
155 | 160 | ||
156 | /* Signal that we are ready to recieve data. */ | 161 | /* Signal that we are ready to receive data. */ |
157 | cfspi->dev->sig_xfer(true, cfspi->dev); | 162 | cfspi->dev->sig_xfer(true, cfspi->dev); |
158 | 163 | ||
159 | cfspi_dbg_state(cfspi, CFSPI_STATE_WAIT_XFER_DONE); | 164 | cfspi_dbg_state(cfspi, CFSPI_STATE_WAIT_XFER_DONE); |