diff options
| author | Aneesh Kumar K.V (Arm) <aneesh.kumar@kernel.org> | 2026-07-17 23:34:21 +0530 |
|---|---|---|
| committer | Marek Szyprowski <m.szyprowski@samsung.com> | 2026-07-31 08:40:58 +0200 |
| commit | af95a0ebc0a0db0762be75f51eadf770bad01aaa (patch) | |
| tree | ec88b4670f99a86db31988f9c357448e25d9471c /include | |
| parent | 0510cb5b23037dbaaf57b8ddd6af32cbfc173ef2 (diff) | |
iommu/dma: Check atomic pool allocation result directly
The non-blocking, non-coherent allocation path uses dma_alloc_from_pool(),
which returns the allocated page and fills cpu_addr only on success.
Do not rely on cpu_addr to detect allocation failure in this path. Check
the returned page directly before using it for the IOMMU mapping.
Fixes: 9420139f516d ("dma-pool: fix coherent pool allocations for IOMMU mappings")
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Tested-by: Michael Kelley <mhklinux@outlook.com>
Tested-by: Mostafa Saleh <smostafa@google.com>
Reviewed-by: Petr Tesarik <ptesarik@suse.com>
Signed-off-by: Aneesh Kumar K.V (Arm) <aneesh.kumar@kernel.org>
Link: https://lore.kernel.org/r/20260717180442.110954-4-aneesh.kumar@kernel.org
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
