On PRIQ overflow, partial requests stored via report_partial_fault() whose
LAST-page entry was lost stay in iopf_param->partial. Drop them by calling
iopf_queue_discard_partial(), matching intel-iommu's handling.
Do it only after the queue is fully drained, since the visible entries all
precede the loss point: a group whose LAST-page entry is still in the queue
gets assembled before the discard, rather than losing its stored partials
to it.
Nothing can arrive in between, as an active overflow inhibits new entries
from being written to the PRI queue until a final CONS write acknowledges
it (IHI0070 8.1).
Suggested-by: Harsha Vardhan V <redacted>
Assisted-by: Claude:claude-sonnet-5
Signed-off-by: Nicolin Chen <redacted>
Reviewed-by: Jonathan Cameron <redacted>
--
Jonathan Cameron [off-list ref]