How to disable SMMU for PCIe
Mar 04, 2024
There was a problem porting the x86/x64 FPGA based PCIe device driver to nvidia.
The driver uses the remap_pfn_range function, where one of the function arguments is the page number obtained using virt_to_pfn.
When call mmap from userspace, the system goes into a reboot. I tried getting the page number with page_to_pfn(virt_to_page(virt_address)) and PHYS_PFN(phys_address) but that didn’t help.
After reading the forum, I found that the problem is in the enabled SMMU. But I couldn’t find a way to turn it off.
Could someone write here a step-by-step instruction on how to disable the SMMU?