LoongArch: KVM: Fix kvm_device leak in kvm_pch_pic_destroy()
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:
LoongArch: KVM: Fix kvm_device leak in kvm_pch_pic_destroy()
In kvm_ioctl_create_device(), kvm_device has allocated memory, kvm_device->destroy() seems to be supposed to free its kvm_device struct, but kvm_pch_pic_destroy() is not currently doing this, that would lead to a memory leak.
So, fix it.
From the CVE record · Linux
On LoongArch, the Linux kernel's KVM PCH PIC destroy function does not free an allocated kvm_device structure. This causes a memory leak when the device is destroyed. The input does not specify attacker access requirements or user interaction.
Engineers running the Linux kernel with LoongArch KVM should check their systems; affected versions are not specified.