diff options
| author | Heiko Stuebner <[email protected]> | 2022-07-07 01:15:33 +0200 |
|---|---|---|
| committer | Palmer Dabbelt <[email protected]> | 2022-07-28 15:30:20 -0700 |
| commit | 12b827758f51d4b614a677dd453b0e854e46aa65 (patch) | |
| tree | ac1a5426c5da997208039af6bf9859f96fef889f /lib/crypto/mpi/mpi-bit.c | |
| parent | 73448ae6204faa636292ae0d7ba8b2f6eb48179d (diff) | |
of: also handle dma-noncoherent in of_dma_is_coherent()
of_dma_is_coherent() currently expects the architecture to be
non-coherent and some devices being coherent getting marked
as such with the dma-coherent devicetree property.
For PowerPC CONFIG_OF_DMA_DEFAULT_COHERENT was added which currently
makes of_dma_is_coherent() always return true but doesn't handle
the case of the architecture being coherent but some devices not.
So modify the function to also check for dma-noncoherent and
set a suitable default return value. If CONFIG_OF_DMA_DEFAULT_COHERENT
is set the value starts with true and finding dma-noncoherent will
set it to false and without CONFIG_OF_DMA_DEFAULT_COHERENT, the
behaviour is reversed.
Reviewed-by: Christoph Hellwig <[email protected]>
Reviewed-by: Rob Herring <[email protected]>
Reviewed-by: Guo Ren <[email protected]>
Signed-off-by: Heiko Stuebner <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Palmer Dabbelt <[email protected]>
Diffstat (limited to 'lib/crypto/mpi/mpi-bit.c')
0 files changed, 0 insertions, 0 deletions