Skip to content

Commit 7bcfab2

Browse files
author
Christoph Hellwig
committed
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: Mathieu Malaterre <[email protected]> Tested-by: Mathieu Malaterre <[email protected]> Reported-by: Meelis Roos <[email protected]> Tested-by: Meelis Roos <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
1 parent ecc2dc5 commit 7bcfab2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/macintosh/macio_asic.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,7 @@ static struct macio_dev * macio_add_one_device(struct macio_chip *chip,
375375
dev->ofdev.dev.of_node = np;
376376
dev->ofdev.archdata.dma_mask = 0xffffffffUL;
377377
dev->ofdev.dev.dma_mask = &dev->ofdev.archdata.dma_mask;
378+
dev->ofdev.dev.coherent_dma_mask = dev->ofdev.archdata.dma_mask;
378379
dev->ofdev.dev.parent = parent;
379380
dev->ofdev.dev.bus = &macio_bus_type;
380381
dev->ofdev.dev.release = macio_release_dev;

0 commit comments

Comments
 (0)