diff options
author | Rabin Vincent <rabin.vincent@stericsson.com> | 2010-10-06 08:20:35 +0000 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2010-10-07 14:54:54 -0700 |
commit | f57b407cfd5fbd70251e9fa0ea7aa083ac06d25c (patch) | |
tree | 061a24030aa22991f3510b1823171db06ce97b13 /drivers/dma | |
parent | 3c0f24019f69c5199996ed9c76d05c92c6186ba8 (diff) | |
download | blackbird-op-linux-f57b407cfd5fbd70251e9fa0ea7aa083ac06d25c.tar.gz blackbird-op-linux-f57b407cfd5fbd70251e9fa0ea7aa083ac06d25c.zip |
DMAENGINE: ste_dma40: fix disabled channels list
The value in the array, not the index, specifies the channel to be
disabled.
Acked-by: Jonas Aaberg <jonas.aberg@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/dma')
-rw-r--r-- | drivers/dma/ste_dma40.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c index 05d0a9937617..2f73e366111e 100644 --- a/drivers/dma/ste_dma40.c +++ b/drivers/dma/ste_dma40.c @@ -2449,9 +2449,11 @@ static int __init d40_phy_res_init(struct d40_base *base) /* Mark disabled channels as occupied */ for (i = 0; base->plat_data->disabled_channels[i] != -1; i++) { - base->phy_res[i].allocated_src = D40_ALLOC_PHY; - base->phy_res[i].allocated_dst = D40_ALLOC_PHY; - num_phy_chans_avail--; + int chan = base->plat_data->disabled_channels[i]; + + base->phy_res[chan].allocated_src = D40_ALLOC_PHY; + base->phy_res[chan].allocated_dst = D40_ALLOC_PHY; + num_phy_chans_avail--; } dev_info(base->dev, "%d of %d physical DMA channels available\n", |