diff options
| author | Ankit Soni <Ankit.Soni@amd.com> | 2026-01-22 15:30:38 +0000 |
|---|---|---|
| committer | Joerg Roedel <joerg.roedel@amd.com> | 2026-02-03 14:27:05 +0100 |
| commit | 9e249c48412828e807afddc21527eb734dc9bd3d (patch) | |
| tree | 8db2544375a42daf8a53a5cc1f3109aca5c18016 /include | |
| parent | 5b0530bb16ec5af3cc96fc25891d6a860fd37a8c (diff) | |
iommu/amd: serialize sequence allocation under concurrent TLB invalidations
With concurrent TLB invalidations, completion wait randomly gets timed out
because cmd_sem_val was incremented outside the IOMMU spinlock, allowing
CMD_COMPL_WAIT commands to be queued out of sequence and breaking the
ordering assumption in wait_on_sem().
Move the cmd_sem_val increment under iommu->lock so completion sequence
allocation is serialized with command queuing.
And remove the unnecessary return.
Fixes: d2a0cac10597 ("iommu/amd: move wait_on_sem() out of spinlock")
Tested-by: Srikanth Aithal <sraithal@amd.com>
Reported-by: Srikanth Aithal <sraithal@amd.com>
Signed-off-by: Ankit Soni <Ankit.Soni@amd.com>
Reviewed-by: Vasant Hegde <vasant.hegde@amd.com>
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
