When dri3 is enabled, kwin, plasma, and kde screenlocker hang sometimes after screen lock and always after resume. I'm not sure, but have an impression that in case of resume they hang for a time spent in suspended state. At least if I suspend and resume in a few seconds, screenlocker and kwin unfreeze after approximately same amount of time. Manually invoked screen lock does not hang.
If kwin and plasma are relaunched, new instances run normally.
I did not find anything special in logs.
Created attachment 103264 [details] [review]
Neuter explicit fencing
your patch indeed fixes the described issues in my case. Please include it in the driver.
It just highlights a deficiency in the current DRI3 code. Degrading it to DRI2 should only be the last resort.
*** This bug has been marked as a duplicate of bug 81551 ***