Message ID | 20200204184240.f6qTQJrAI%akpm@linux-foundation.org |
---|---|
State | New |
Headers | show |
Series | [merged] arm-dma-api-fix-max_pfn-off-by-one-error-in-__dma_supported.patch removed from -mm tree | expand |
--- a/arch/arm/mm/dma-mapping.c~arm-dma-api-fix-max_pfn-off-by-one-error-in-__dma_supported +++ a/arch/arm/mm/dma-mapping.c @@ -221,7 +221,7 @@ EXPORT_SYMBOL(arm_coherent_dma_ops); static int __dma_supported(struct device *dev, u64 mask, bool warn) { - unsigned long max_dma_pfn = min(max_pfn, arm_dma_pfn_limit); + unsigned long max_dma_pfn = min(max_pfn - 1, arm_dma_pfn_limit); /* * Translate the device's DMA mask to a PFN limit. This