drm/xe: Fix dma-buf attachment leak in xe_gem_prime_import()
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: Fix dma-buf attachment leak in xe_gem_prime_import()
When xe_dma_buf_init_obj() fails, the attachment from dma_buf_dynamic_attach() is not detached. Add dma_buf_detach() before returning the error. Note: we cannot use goto out_err here because xe_dma_buf_init_obj() already frees bo on failure, and out_err would double-free it.
(cherry picked from commit a828eb185aac41800df8eae4b60501ccc0dbbe51)
From the CVE record · Linux
The Linux kernel’s drm/xe driver fails to detach a dma-buf attachment when xe_dma_buf_init_obj() fails during import. This leaks the attachment; the input does not specify how an attacker could trigger the failure or whether authentication or user interaction is required.
Teams running Linux kernels with the drm/xe driver should check their kernel versions; affected versions are not specified.