tty: serial: fsl_lpuart: fix DMA mapping
authorMichael Walle <michael@walle.cc>
Fri, 6 Mar 2020 21:44:31 +0000 (22:44 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 Mar 2020 09:02:00 +0000 (10:02 +0100)
commita092ab25fdaa445b821f5959e458350696fce44c
tree431e93b785812c748c02977bf355d438253d256d
parent159381df1442f3c781ae3de05b5c6130fd4ee058
tty: serial: fsl_lpuart: fix DMA mapping

Use the correct device to request the DMA mapping. Otherwise the IOMMU
doesn't get the mapping and it will generate a page fault.

The error messages look like:
[   19.012140] arm-smmu 5000000.iommu: Unhandled context fault: fsr=0x402, iova=0xbbfff800, fsynr=0x3e0021, cbfrsynra=0x828, cb=9
[   19.023593] arm-smmu 5000000.iommu: Unhandled context fault: fsr=0x402, iova=0xbbfff800, fsynr=0x3e0021, cbfrsynra=0x828, cb=9

This was tested on a custom board with a LS1028A SoC.

Signed-off-by: Michael Walle <michael@walle.cc>
Link: https://lore.kernel.org/r/20200306214433.23215-3-michael@walle.cc
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/fsl_lpuart.c