]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
accel/amdxdna: Allow forcing IOVA-based DMA via module parameter
authorLizhi Hou <lizhi.hou@amd.com>
Mon, 26 Jan 2026 19:30:01 +0000 (11:30 -0800)
committerLizhi Hou <lizhi.hou@amd.com>
Thu, 12 Mar 2026 19:37:56 +0000 (12:37 -0700)
commitece3e8980907818c72dc9faa7bbaf40488ef1824
tree8605d632c2eb90b59096fb2ee04f79ad16358f33
parentd11ac9043435cf1ddf1abc59fa774eb6c0ca4e51
accel/amdxdna: Allow forcing IOVA-based DMA via module parameter

The amdxdna driver normally performs DMA using userspace virtual address
plus PASID. For debugging and validation purposes, add a module parameter,
force_iova, to force DMA to go through IOMMU IOVA mapping.

When force_iova=1 is set, the driver will allocate and map DMA buffers
using IOVA.

Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org>
Signed-off-by: Lizhi Hou <lizhi.hou@amd.com>
Link: https://patch.msgid.link/20260126193001.1400545-1-lizhi.hou@amd.com
drivers/accel/amdxdna/Makefile
drivers/accel/amdxdna/aie2_ctx.c
drivers/accel/amdxdna/aie2_error.c
drivers/accel/amdxdna/aie2_message.c
drivers/accel/amdxdna/aie2_pci.h
drivers/accel/amdxdna/amdxdna_gem.c
drivers/accel/amdxdna/amdxdna_gem.h
drivers/accel/amdxdna/amdxdna_iommu.c [new file with mode: 0644]
drivers/accel/amdxdna/amdxdna_pci_drv.c
drivers/accel/amdxdna/amdxdna_pci_drv.h