diff mbox series

kvm/eventfd : unnecessory conversion to bool

Message ID 1545891737-84095-1-git-send-email-peng.hao2@zte.com.cn (mailing list archive)
State New, archived
Headers show
Series kvm/eventfd : unnecessory conversion to bool | expand

Commit Message

Peng Hao Dec. 27, 2018, 6:22 a.m. UTC
Conversion to bool is not needed in ioeventfd_in_range.

Signed-off-by: Peng Hao <peng.hao2@zte.com.cn>
---
 virt/kvm/eventfd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Radim Krčmář Jan. 11, 2019, 1:42 p.m. UTC | #1
2018-12-27 14:22+0800, Peng Hao:
> Conversion to bool is not needed in ioeventfd_in_range.
> 
> Signed-off-by: Peng Hao <peng.hao2@zte.com.cn>
> ---

Fixed the typo in subject and queued, thanks.
diff mbox series

Patch

diff --git a/virt/kvm/eventfd.c b/virt/kvm/eventfd.c
index b20b751..d4cdc9c 100644
--- a/virt/kvm/eventfd.c
+++ b/virt/kvm/eventfd.c
@@ -723,7 +723,7 @@  struct _ioeventfd {
 		return false;
 	}
 
-	return _val == p->datamatch ? true : false;
+	return _val == p->datamatch;
 }
 
 /* MMIO/PIO writes trigger an event if the addr/val match */