net: hns3: using the num_tqps in the vf driver to apply for resources
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ e2cb1dec9779ba2d89302a653eb0abaeb8682196 · < 62f28d79a6186a602a9d926a2dbb5b12b6867df7| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net: hns3: using the num_tqps in the vf driver to apply for resources
Currently, hdev->htqp is allocated using hdev->num_tqps, and kinfo->tqp is allocated using kinfo->num_tqps. However, kinfo->num_tqps is set to min(new_tqps, hdev->num_tqps); Therefore, kinfo->num_tqps may be smaller than hdev->num_tqps, which causes some hdev->htqp[i] to remain uninitialized in hclgevf_knic_setup().
Thus, this patch allocates hdev->htqp and kinfo->tqp using hdev->num_tqps, ensuring that the lengths of hdev->htqp and kinfo->tqp are consistent and that all elements are properly initialized.
From the CVE record · Linux
The Linux kernel hns3 VF driver can leave some resource-array entries uninitialized when its queue counts differ. The input does not describe an attacker action or specify access, authentication, or user-interaction conditions.
Engineers running Linux kernels with the hns3 VF driver should check their deployments; affected versions are not specified.