powerpc/ps3: Set driver coherent_dma_mask

Set the coherent_dma_mask for the PS3 ehci, ohci, and snd devices.

Silences WARN_ON_ONCE messages emitted by the dma_alloc_attrs() routine.

Reported-by: Fredrik Noring <[email protected]>
Signed-off-by: Geoff Levand <[email protected]>
Acked-by: Greg Kroah-Hartman <[email protected]>
Acked-by: Alan Stern <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
This commit is contained in:
Geoff Levand 2018-07-18 15:08:33 -07:00 • committed by Michael Ellerman
commit 48e9184686
3 changed files with 13 additions and 4 deletions

View file

@ -930,6 +930,7 @@ static int snd_ps3_driver_probe(struct ps3_system_bus_device *dev)
{
int i, ret;
u64 lpar_addr, lpar_size;
static u64 dummy_mask;
if (WARN_ON(!firmware_has_feature(FW_FEATURE_PS3_LV1)))
return -ENODEV;
@ -970,6 +971,10 @@ static int snd_ps3_driver_probe(struct ps3_system_bus_device *dev)
goto clean_mmio;
}
dummy_mask = DMA_BIT_MASK(32);
dev->core.dma_mask = &dummy_mask;
dma_set_coherent_mask(&dev->core, dummy_mask);
snd_ps3_audio_set_base_addr(dev->d_region->bus_addr);
/* CONFIG_SND_PS3_DEFAULT_START_DELAY */