projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f36992e
)
KVM: Sanitize KVM_IRQFD flags
author
Alex Williamson
<alex.williamson@redhat.com>
Fri, 29 Jun 2012 15:56:24 +0000
(09:56 -0600)
committer
Marcelo Tosatti
<mtosatti@redhat.com>
Tue, 3 Jul 2012 00:10:30 +0000
(21:10 -0300)
We only know of one so far.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
virt/kvm/eventfd.c
patch
|
blob
|
blame
|
history
diff --git
a/virt/kvm/eventfd.c
b/virt/kvm/eventfd.c
index c307c24c147affbc0dfadf65f938c8073f1067fb..7d7e2aaffece234a81cef3f4181cc7ffe5bb14cb 100644
(file)
--- a/
virt/kvm/eventfd.c
+++ b/
virt/kvm/eventfd.c
@@
-340,6
+340,9
@@
kvm_irqfd_deassign(struct kvm *kvm, struct kvm_irqfd *args)
int
kvm_irqfd(struct kvm *kvm, struct kvm_irqfd *args)
{
+ if (args->flags & ~KVM_IRQFD_FLAG_DEASSIGN)
+ return -EINVAL;
+
if (args->flags & KVM_IRQFD_FLAG_DEASSIGN)
return kvm_irqfd_deassign(kvm, args);