[PATCH] riscv: kvm: fix vector context allocation leak
Markus Elfring
Markus.Elfring at web.de
Mon Mar 16 02:23:27 PDT 2026
> When the second kzalloc (host_context.vector.datap) fails in
> kvm_riscv_vcpu_alloc_vector_context, the first allocation
> (guest_context.vector.datap) is leaked. Free it before returning.
Were any source code analysis tools involved here?
How do you think about to add any tags (like “Fixes” and “Cc”) accordingly?
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v7.0-rc4#n145
Regards,
Markus
More information about the linux-riscv
mailing list