[RFC PATCH 4/9] iommu/rockchip: skip orphaned-fault banks in rk_iommu_is_stall_active

Jiaxing Hu gahing at gahingwoo.com
Fri Jul 17 20:13:41 PDT 2026


Hi Chaoyi, thanks for looking.

You're right -- this was treating the symptom. I traced it:

The bank carries PAGE_FAULT_ACTIVE from boot firmware, and rk_iommu_enable()
runs rk_iommu_enable_stall() *before* rk_iommu_force_reset().  So the stale
fault is still set when enable_stall() polls for STALL_ACTIVE, and that bank
never stalls -- that's the timeout the two "skip" patches worked around.
(On the RK3576 NPU force_reset() was itself returning -EFAULT, "MMU_DTE_ADDR
is not functioning", until the MMU clocks were fixed, so the fault never got
cleared that way either.)

For v2 I dropped both skip patches and instead acknowledge the stale fault
with CMD_PAGE_FAULT_DONE before enabling stall, so every bank starts from a
clean state and the normal stall sequence applies to all of them -- which is
what you were getting at, deal with the fault rather than route around it.
Confirmed on a ROCK 4D: no more raw-reset error, no stall timeout, the NPU
brings up and runs to completion.

v2:
https://lore.kernel.org/all/20260718031146.3368811-1-gahing@gahingwoo.com/

Thanks,
Jiaxing



More information about the Linux-rockchip mailing list