diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2013-11-08 04:50:24 -0500 |
---|---|---|
committer | Vinod Koul <vinod.koul@intel.com> | 2013-11-13 08:19:43 -0500 |
commit | 02808b427689d46136d9662c5013145f70119f42 (patch) | |
tree | 5c2e323b7d9504fe7368d2ac4e175033a6ad850c /drivers/dma/pl330.c | |
parent | 2dcbdce3610a1ba190a74b782b9f7f1f7f976325 (diff) |
dma: pl330: off by one in pl330_probe()
There are only AMBA_NR_IRQS (2) elements in adev->irq[]. This code
maybe works if the there is a zero directly after the array.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma/pl330.c')
-rw-r--r-- | drivers/dma/pl330.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c index 75328f9870d2..ebd23b036a69 100644 --- a/drivers/dma/pl330.c +++ b/drivers/dma/pl330.c | |||
@@ -2922,7 +2922,7 @@ pl330_probe(struct amba_device *adev, const struct amba_id *id) | |||
2922 | 2922 | ||
2923 | amba_set_drvdata(adev, pdmac); | 2923 | amba_set_drvdata(adev, pdmac); |
2924 | 2924 | ||
2925 | for (i = 0; i <= AMBA_NR_IRQS; i++) { | 2925 | for (i = 0; i < AMBA_NR_IRQS; i++) { |
2926 | irq = adev->irq[i]; | 2926 | irq = adev->irq[i]; |
2927 | if (irq) { | 2927 | if (irq) { |
2928 | ret = devm_request_irq(&adev->dev, irq, | 2928 | ret = devm_request_irq(&adev->dev, irq, |