drm/ttm: Fix a NULL pointer dereference
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 |
|
|
6.1.216.2.86.3In the Linux kernel, the following vulnerability has been resolved:
drm/ttm: Fix a NULL pointer dereference
The LRU mechanism may look up a resource in the process of being removed from an object. The locking rules here are a bit unclear but it looks currently like res->bo assignment is protected by the LRU lock, whereas bo->resource is protected by the object lock, while *clearing* of bo->resource is also protected by the LRU lock. This means that if we check that bo->resource points to the LRU resource under the LRU lock we should be safe. So perform that check before deciding to swap out a bo. That avoids dereferencing a NULL bo->resource in ttm_bo_swapout().
From the CVE record · Linux
The Linux kernel’s drm/ttm LRU mechanism can encounter a resource while it is being removed from an object, leading to a NULL pointer dereference in ttm_bo_swapout(). The input does not specify what an attacker could do to trigger this or whether network access, authentication, or user interaction is required.
Engineers running the Linux kernel should check affected versions; none are specified in the input.