Linux: net: ena: fix MMIO read buffer leak on probe failure
What fixes it
- 7bd3e9a2d0c288e54f51df260d9433163f5fbc1eLinuxCVE List
- 30ff01b4c7e419bb70f40f01dcd7f6af680808b3LinuxCVE List
- 47785f9f638b064ce6e32e8e3b6f1ffd83849fc2LinuxCVE List
- 9476b4468862927297c94c440863cd8ed1e7cc83LinuxCVE List
A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.
Description
In the Linux kernel, the following vulnerability has been resolved:
net: ena: fix MMIO read buffer leak on probe failure
ena_device_init() initializes the MMIO read mechanism with ena_com_mmio_reg_read_request_init(), which allocates a coherent DMA buffer for MMIO read responses.
The normal removal path releases this buffer through ena_com_mmio_reg_read_request_destroy(). However, if ena_probe() fails after ena_device_init() succeeds, the error path destroys the admin resources and eventually frees ena_dev without destroying the MMIO read request, leaving the coherent DMA buffer allocated.
Call ena_com_mmio_reg_read_request_destroy() in the probe error path before releasing the remaining device resources.
This issue was found by manual code inspection.
Text from CVE List
Affected versions 12
- Linuxaffected: 1738cd3ed342294360d6a74d4e58800004bff854 before a0f5fd7a285f44fa402242f26feddfe1d4a0fc6cCVE List
- Linuxaffected: 1738cd3ed342294360d6a74d4e58800004bff854 before 7bd3e9a2d0c288e54f51df260d9433163f5fbc1eCVE List
- Linuxaffected: 1738cd3ed342294360d6a74d4e58800004bff854 before 30ff01b4c7e419bb70f40f01dcd7f6af680808b3CVE List
- Linuxaffected: 1738cd3ed342294360d6a74d4e58800004bff854 before 47785f9f638b064ce6e32e8e3b6f1ffd83849fc2CVE List
- Linuxaffected: 1738cd3ed342294360d6a74d4e58800004bff854 before 9476b4468862927297c94c440863cd8ed1e7cc83CVE List
- Linuxaffected: 4.9CVE List
- Linuxunaffected: all versions before 4.9CVE List
- Linuxunaffected: 6.6.160 through 6.6.*CVE List
- Linuxunaffected: 6.12.112 through 6.12.*CVE List
- Linuxunaffected: 6.18.55 through 6.18.*CVE List
- Linuxunaffected: 7.2.9 through 7.2.*CVE List
- Linuxunaffected: 7.3CVE List
References 5
- git.kernel.org/stable/c/a0f5fd7a285f44fa402242f26feddfe1d4a0fc6cReferencevia CVE List
- git.kernel.org/stable/c/7bd3e9a2d0c288e54f51df260d9433163f5fbc1eReferencevia CVE List
- git.kernel.org/stable/c/30ff01b4c7e419bb70f40f01dcd7f6af680808b3Referencevia CVE List
- git.kernel.org/stable/c/47785f9f638b064ce6e32e8e3b6f1ffd83849fc2Referencevia CVE List
- git.kernel.org/stable/c/9476b4468862927297c94c440863cd8ed1e7cc83Referencevia CVE List