Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

KVM: Sanitize KVM_IRQFD flags

We only know of one so far.

Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>

authored by

Alex Williamson and committed by
Marcelo Tosatti
326cf033 f36992e3

+3
+3
virt/kvm/eventfd.c
··· 340 340 int 341 341 kvm_irqfd(struct kvm *kvm, struct kvm_irqfd *args) 342 342 { 343 + if (args->flags & ~KVM_IRQFD_FLAG_DEASSIGN) 344 + return -EINVAL; 345 + 343 346 if (args->flags & KVM_IRQFD_FLAG_DEASSIGN) 344 347 return kvm_irqfd_deassign(kvm, args); 345 348