summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorLizhi Hou <lizhi.hou@amd.com>2025-12-10 20:51:25 -0800
committerLizhi Hou <lizhi.hou@amd.com>2025-12-12 09:49:10 -0800
commit343f5683cfa443000904c88ce2e23656375fc51c (patch)
tree2b1798ac4810e3ff783619c630ad20d11e7d12eb /include
parent470cb09a2936d3c1ff8aeff46e3c14dcc4314e9b (diff)
accel/amdxdna: Fix race where send ring appears full due to delayed head update
The firmware sends a response and interrupts the driver before advancing the mailbox send ring head pointer. As a result, the driver may observe the response and attempt to send a new request before the firmware has updated the head pointer. In this window, the send ring still appears full, causing the driver to incorrectly fail the send operation. This race can be triggered more easily in a multithreaded environment, leading to unexpected and spurious "send ring full" failures. To address this, poll the send ring head pointer for up to 100us before returning a full-ring condition. This allows the firmware time to update the head pointer. Fixes: b87f920b9344 ("accel/amdxdna: Support hardware mailbox") Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org> Signed-off-by: Lizhi Hou <lizhi.hou@amd.com> Link: https://patch.msgid.link/20251211045125.1724604-1-lizhi.hou@amd.com
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions