accel/habanalabs: postpone mem_mgr IDR destruction to hpriv_release()
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.1896.3.46.4In the Linux kernel, the following vulnerability has been resolved:
accel/habanalabs: postpone mem_mgr IDR destruction to hpriv_release()
The memory manager IDR is currently destroyed when user releases the file descriptor. However, at this point the user context might be still held, and memory buffers might be still in use. Later on, calls to release those buffers will fail due to not finding their handles in the IDR, leading to a memory leak. To avoid this leak, split the IDR destruction from the memory manager fini, and postpone it to hpriv_release() when there is no user context and no buffers are used.
From the CVE record · Linux
The Linux kernel’s habanalabs memory manager can leak memory when a user closes a file descriptor while its context and buffers are still in use. Later buffer releases cannot find their handles. This requires local interaction with the device; the input does not specify authentication requirements.
Engineers running Linux kernels with the habanalabs driver should check their exposure; affected versions were not specified.