diff --git a/virt/kvm/eventfd.c b/virt/kvm/eventfd.c index 99017e8a92ac32e442b86717c59b5771e883b50d..bb4ebd89b9fff11ee5a0227bf74805650d9ab4a8 100644 --- a/virt/kvm/eventfd.c +++ b/virt/kvm/eventfd.c @@ -230,7 +230,7 @@ kvm_irqfd_assign(struct kvm *kvm, int fd, int gsi) if (eventfd && !IS_ERR(eventfd)) eventfd_ctx_put(eventfd); - if (file && !IS_ERR(file)) + if (!IS_ERR(file)) fput(file); kfree(irqfd);