aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma/sirf-dma.c
diff options
context:
space:
mode:
authorMaxime Ripard <maxime.ripard@free-electrons.com>2014-10-16 05:01:02 -0400
committerVinod Koul <vinod.koul@intel.com>2014-11-06 01:06:18 -0500
commit35202451c8e6e5d76fe169e009f3587137686a7c (patch)
treef1d6138b1a87c4bbd0db47c11a1ddeec7018178b /drivers/dma/sirf-dma.c
parent1e916474a98eced0c2fd7dfeb13636ddf1e20348 (diff)
dmaengine: sirf: Remove chancnt affectations
chanctnt is already filled by dma_async_device_register, which uses the channel list to know how much channels there is. Since it's already filled, we can safely remove it from the drivers' probe function. Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma/sirf-dma.c')
-rw-r--r--drivers/dma/sirf-dma.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/dma/sirf-dma.c b/drivers/dma/sirf-dma.c
index aac03ab10c54..fbe291584e8a 100644
--- a/drivers/dma/sirf-dma.c
+++ b/drivers/dma/sirf-dma.c
@@ -735,7 +735,6 @@ static int sirfsoc_dma_probe(struct platform_device *op)
735 735
736 dma = &sdma->dma; 736 dma = &sdma->dma;
737 dma->dev = dev; 737 dma->dev = dev;
738 dma->chancnt = SIRFSOC_DMA_CHANNELS;
739 738
740 dma->device_alloc_chan_resources = sirfsoc_dma_alloc_chan_resources; 739 dma->device_alloc_chan_resources = sirfsoc_dma_alloc_chan_resources;
741 dma->device_free_chan_resources = sirfsoc_dma_free_chan_resources; 740 dma->device_free_chan_resources = sirfsoc_dma_free_chan_resources;
@@ -752,7 +751,7 @@ static int sirfsoc_dma_probe(struct platform_device *op)
752 dma_cap_set(DMA_INTERLEAVE, dma->cap_mask); 751 dma_cap_set(DMA_INTERLEAVE, dma->cap_mask);
753 dma_cap_set(DMA_PRIVATE, dma->cap_mask); 752 dma_cap_set(DMA_PRIVATE, dma->cap_mask);
754 753
755 for (i = 0; i < dma->chancnt; i++) { 754 for (i = 0; i < SIRFSOC_DMA_CHANNELS; i++) {
756 schan = &sdma->channels[i]; 755 schan = &sdma->channels[i];
757 756
758 schan->chan.device = dma; 757 schan->chan.device = dma;