aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc
diff options
context:
space:
mode:
authorGuennadi Liakhovetski <g.liakhovetski@gmx.de>2011-05-24 06:24:07 -0400
committerChris Ball <cjb@laptop.org>2011-06-25 18:52:20 -0400
commit3e713373ce07b9f59c3901e7d39bc1edccda28da (patch)
treef067a8e07336c35ad375951e03b57808478f22dc /drivers/mmc
parent7d8b4c2a4b73da8e3632603691838ca5b2a8c26d (diff)
mmc: sdhi: DMA slave ID 0 is invalid
Don't try to allocate DMA resources if the platform didn't specify positive DMA slave IDs. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/host/sh_mobile_sdhi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/host/sh_mobile_sdhi.c b/drivers/mmc/host/sh_mobile_sdhi.c
index 2353bb797d6c..ce500f03df85 100644
--- a/drivers/mmc/host/sh_mobile_sdhi.c
+++ b/drivers/mmc/host/sh_mobile_sdhi.c
@@ -92,7 +92,7 @@ static int __devinit sh_mobile_sdhi_probe(struct platform_device *pdev)
92 mmc_data->ocr_mask = p->tmio_ocr_mask; 92 mmc_data->ocr_mask = p->tmio_ocr_mask;
93 mmc_data->capabilities |= p->tmio_caps; 93 mmc_data->capabilities |= p->tmio_caps;
94 94
95 if (p->dma_slave_tx >= 0 && p->dma_slave_rx >= 0) { 95 if (p->dma_slave_tx > 0 && p->dma_slave_rx > 0) {
96 priv->param_tx.slave_id = p->dma_slave_tx; 96 priv->param_tx.slave_id = p->dma_slave_tx;
97 priv->param_rx.slave_id = p->dma_slave_rx; 97 priv->param_rx.slave_id = p->dma_slave_rx;
98 priv->dma_priv.chan_priv_tx = &priv->param_tx; 98 priv->dma_priv.chan_priv_tx = &priv->param_tx;