Commit 7bcfab20 authored by Christoph Hellwig's avatar Christoph Hellwig

powerpc/macio: set a proper dma_coherent_mask

We have expected busses to set up a coherent mask to properly use the
common dma mapping code for a long time, and now that I've added a warning
macio turned out to not set one up yet.  This sets it to the same value
as the dma_mask, which seems to be what the drivers expect.
Reported-by: default avatarMathieu Malaterre <malat@debian.org>
Tested-by: default avatarMathieu Malaterre <malat@debian.org>
Reported-by: default avatarMeelis Roos <mroos@linux.ee>
Tested-by: default avatarMeelis Roos <mroos@linux.ee>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent ecc2dc55
...@@ -375,6 +375,7 @@ static struct macio_dev * macio_add_one_device(struct macio_chip *chip, ...@@ -375,6 +375,7 @@ static struct macio_dev * macio_add_one_device(struct macio_chip *chip,
dev->ofdev.dev.of_node = np; dev->ofdev.dev.of_node = np;
dev->ofdev.archdata.dma_mask = 0xffffffffUL; dev->ofdev.archdata.dma_mask = 0xffffffffUL;
dev->ofdev.dev.dma_mask = &dev->ofdev.archdata.dma_mask; dev->ofdev.dev.dma_mask = &dev->ofdev.archdata.dma_mask;
dev->ofdev.dev.coherent_dma_mask = dev->ofdev.archdata.dma_mask;
dev->ofdev.dev.parent = parent; dev->ofdev.dev.parent = parent;
dev->ofdev.dev.bus = &macio_bus_type; dev->ofdev.dev.bus = &macio_bus_type;
dev->ofdev.dev.release = macio_release_dev; dev->ofdev.dev.release = macio_release_dev;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment