drm/xe/preempt_fence: enlarge the fence critical section
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
drm/xe/preempt_fence: enlarge the fence critical section
It is really easy to introduce subtle deadlocks in preempt_fence_work_func() since we operate on single global ordered-wq for signalling our preempt fences behind the scenes, so even though we signal a particular fence, everything in the callback should be in the fence critical section, since blocking in the callback will prevent other published fences from signalling. If we enlarge the fence critical section to cover the entire callback, then lockdep should be able to understand this better, and complain if we grab a sensitive lock like vm->lock, which is also held when waiting on preempt fences.
From the CVE record · Linux
The Linux kernel’s drm/xe preemption-fence callback can cause a deadlock if it blocks while processing fences on a single global ordered workqueue. The input does not describe an attacker path or specify whether network access, authentication, or user interaction is required.
Engineers running Linux kernels with the drm/xe driver should check their versions; affected versions are not specified.