Skip to content
Commit 49bc8beb authored by Christoph Hellwig's avatar Christoph Hellwig
Browse files

ARM/dma-mappіng: don't override ->dma_coherent when set from a bus notifier



Commit ae626eb9 ("ARM/dma-mapping: use dma-direct unconditionally")
caused a regression on the mvebu platform, wherein devices that are
dma-coherent are marked as dma-noncoherent, because although
mvebu_hwcc_notifier() after that commit still marks then as coherent,
the arm_coherent_dma_ops() function, which is called later, overwrites
this setting, since it is being called from drivers/of/device.c with
coherency parameter determined by of_dma_is_coherent(), and the
device-trees do not declare the 'dma-coherent' property.

Fix this by defaulting never clearing the dma_coherent flag in
arm_coherent_dma_ops().

Fixes: ae626eb9 ("ARM/dma-mapping: use dma-direct unconditionally")
Reported-by: default avatarMarek Behún <kabel@kernel.org>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Reviewed-by: default avatarRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Tested-by: default avatarMarek Behún <kabel@kernel.org>
parent f7f04d19
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment