aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/amba
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2013-06-27 05:25:33 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2013-10-31 10:48:38 -0400
commit446b2a9380b64b9d7410d86ee8226031e03645cf (patch)
tree1bd25472bcd24d88d1fbaf0b35bc05ebee8441d4 /drivers/amba
parent01edb5e12c7fd2170b1969a455442e8fd17cfe54 (diff)
DMA-API: amba: get rid of separate dma_mask
AMBA Primecell devices always treat streaming and coherent DMA exactly the same, so there's no point in having the masks separated. Acked-by: Grant Likely <grant.likely@linaro.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/amba')
-rw-r--r--drivers/amba/bus.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c
index c6707278a6bb..c4876ac9151a 100644
--- a/drivers/amba/bus.c
+++ b/drivers/amba/bus.c
@@ -552,7 +552,6 @@ amba_aphb_device_add(struct device *parent, const char *name,
552 if (!dev) 552 if (!dev)
553 return ERR_PTR(-ENOMEM); 553 return ERR_PTR(-ENOMEM);
554 554
555 dev->dma_mask = dma_mask;
556 dev->dev.coherent_dma_mask = dma_mask; 555 dev->dev.coherent_dma_mask = dma_mask;
557 dev->irq[0] = irq1; 556 dev->irq[0] = irq1;
558 dev->irq[1] = irq2; 557 dev->irq[1] = irq2;
@@ -619,7 +618,7 @@ static void amba_device_initialize(struct amba_device *dev, const char *name)
619 dev_set_name(&dev->dev, "%s", name); 618 dev_set_name(&dev->dev, "%s", name);
620 dev->dev.release = amba_device_release; 619 dev->dev.release = amba_device_release;
621 dev->dev.bus = &amba_bustype; 620 dev->dev.bus = &amba_bustype;
622 dev->dev.dma_mask = &dev->dma_mask; 621 dev->dev.dma_mask = &dev->dev.coherent_dma_mask;
623 dev->res.name = dev_name(&dev->dev); 622 dev->res.name = dev_name(&dev->dev);
624} 623}
625 624
@@ -663,9 +662,6 @@ int amba_device_register(struct amba_device *dev, struct resource *parent)
663 amba_device_initialize(dev, dev->dev.init_name); 662 amba_device_initialize(dev, dev->dev.init_name);
664 dev->dev.init_name = NULL; 663 dev->dev.init_name = NULL;
665 664
666 if (!dev->dev.coherent_dma_mask && dev->dma_mask)
667 dev_warn(&dev->dev, "coherent dma mask is unset\n");
668
669 return amba_device_add(dev, parent); 665 return amba_device_add(dev, parent);
670} 666}
671 667