net/mlx5: Devcom, fix error flow in mlx5_devcom_register_device
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ fadd59fc50d010145f251db583c7ccef37393d19 · < af87194352cad882d787d06fb7efa714acd95427| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net/mlx5: Devcom, fix error flow in mlx5_devcom_register_device
In case devcom allocation is failed, mlx5 is always freeing the priv. However, this priv might have been allocated by a different thread, and freeing it might lead to use-after-free bugs. Fix it by freeing the priv only in case it was allocated by the running thread.
From the CVE record · Linux
A failed devcom allocation in the Linux kernel's mlx5 driver can cause one thread to free memory allocated by another, potentially leading to use-after-free. The input does not specify an attack path, authentication requirements, or whether user interaction is needed.
Engineers running Linux kernels with the mlx5 driver should check their versions; affected versions are not specified.