serial: samsung: use dma_ops of DMA if attached
When DMA is used for TX and RX by serial driver, it should pass the DMA device pointer to DMA API instead of UART device pointer. DMA device should be used for DMA API because only the DMA device is aware of how the device connects to the memory. There might be an extra level of address translation due to a SMMU attached to the DMA device. When serial device is used for DMA API, the DMA API will have no clue of the SMMU attached to the DMA device. This patch is necessary to fix the SMMU page faults which is observed when a DMA(with SMMU enabled) is attached to UART for transfer. Acked-by: NMarek Szyprowski <m.szyprowski@samsung.com> Acked-by: NKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Signed-off-by: NTamseel Shams <m.shams@samsung.com> Signed-off-by: NAjay Kumar <ajaykumar.rs@samsung.com> Link: https://lore.kernel.org/r/20210629045902.48912-1-m.shams@samsung.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Showing
想要评论请 注册 或 登录