diff options
Diffstat (limited to 'drivers/spi/spi-mxs.c')
-rw-r--r-- | drivers/spi/spi-mxs.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/spi/spi-mxs.c b/drivers/spi/spi-mxs.c index 2884f0c2f5f0..51460878af04 100644 --- a/drivers/spi/spi-mxs.c +++ b/drivers/spi/spi-mxs.c | |||
@@ -85,7 +85,7 @@ static int mxs_spi_setup_transfer(struct spi_device *dev, | |||
85 | mxs_ssp_set_clk_rate(ssp, hz); | 85 | mxs_ssp_set_clk_rate(ssp, hz); |
86 | /* | 86 | /* |
87 | * Save requested rate, hz, rather than the actual rate, | 87 | * Save requested rate, hz, rather than the actual rate, |
88 | * ssp->clk_rate. Otherwise we would set the rate every trasfer | 88 | * ssp->clk_rate. Otherwise we would set the rate every transfer |
89 | * when the actual rate is not quite the same as requested rate. | 89 | * when the actual rate is not quite the same as requested rate. |
90 | */ | 90 | */ |
91 | spi->sck = hz; | 91 | spi->sck = hz; |
@@ -154,12 +154,14 @@ static int mxs_ssp_wait(struct mxs_spi *spi, int offset, int mask, bool set) | |||
154 | static void mxs_ssp_dma_irq_callback(void *param) | 154 | static void mxs_ssp_dma_irq_callback(void *param) |
155 | { | 155 | { |
156 | struct mxs_spi *spi = param; | 156 | struct mxs_spi *spi = param; |
157 | |||
157 | complete(&spi->c); | 158 | complete(&spi->c); |
158 | } | 159 | } |
159 | 160 | ||
160 | static irqreturn_t mxs_ssp_irq_handler(int irq, void *dev_id) | 161 | static irqreturn_t mxs_ssp_irq_handler(int irq, void *dev_id) |
161 | { | 162 | { |
162 | struct mxs_ssp *ssp = dev_id; | 163 | struct mxs_ssp *ssp = dev_id; |
164 | |||
163 | dev_err(ssp->dev, "%s[%i] CTRL1=%08x STATUS=%08x\n", | 165 | dev_err(ssp->dev, "%s[%i] CTRL1=%08x STATUS=%08x\n", |
164 | __func__, __LINE__, | 166 | __func__, __LINE__, |
165 | readl(ssp->base + HW_SSP_CTRL1(ssp)), | 167 | readl(ssp->base + HW_SSP_CTRL1(ssp)), |
@@ -189,7 +191,7 @@ static int mxs_spi_txrx_dma(struct mxs_spi *spi, | |||
189 | if (!len) | 191 | if (!len) |
190 | return -EINVAL; | 192 | return -EINVAL; |
191 | 193 | ||
192 | dma_xfer = kzalloc(sizeof(*dma_xfer) * sgs, GFP_KERNEL); | 194 | dma_xfer = kcalloc(sgs, sizeof(*dma_xfer), GFP_KERNEL); |
193 | if (!dma_xfer) | 195 | if (!dma_xfer) |
194 | return -ENOMEM; | 196 | return -ENOMEM; |
195 | 197 | ||