mbox series

[0/1] KVM: selftests: kvm_vm_elf_load() and elfhdr_get() should close fd

Message ID 20221220170921.2499209-1-reijiw@google.com (mailing list archive)
Headers show
Series KVM: selftests: kvm_vm_elf_load() and elfhdr_get() should close fd | expand

Message

Reiji Watanabe Dec. 20, 2022, 5:09 p.m. UTC
kvm_vm_elf_load() and elfhdr_get() open one file each, but they
never close the opened file descriptor.  Fix those two functions
to close the file descriptor.

This patch is the same as the one included in the patch series [1],
with minor updates to the commit log (including adding Reviewed-bys
I got).

[1] https://lore.kernel.org/linux-arm-kernel/20220217034947.180935-1-reijiw@google.com/

Reiji Watanabe (1):
  KVM: selftests: kvm_vm_elf_load() and elfhdr_get() should close fd

 tools/testing/selftests/kvm/lib/elf.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Sean Christopherson Jan. 19, 2023, 9:01 p.m. UTC | #1
On Tue, 20 Dec 2022 09:09:20 -0800, Reiji Watanabe wrote:
> kvm_vm_elf_load() and elfhdr_get() open one file each, but they
> never close the opened file descriptor.  Fix those two functions
> to close the file descriptor.
> 
> This patch is the same as the one included in the patch series [1],
> with minor updates to the commit log (including adding Reviewed-bys
> I got).
> 
> [...]

Applied to kvm-x86 selftests, thanks!

[1/1] KVM: selftests: kvm_vm_elf_load() and elfhdr_get() should close fd
      https://github.com/kvm-x86/linux/commit/a6854fecd0b2

--
https://github.com/kvm-x86/linux/tree/next
https://github.com/kvm-x86/linux/tree/fixes