All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] kvm tools: virtio-mmio: init_ioeventfd should use MMIO for ioeventfd__add_event()
@ 2013-08-30 13:58 Ying-Shiuan Pan
  2013-09-04  9:21 ` Pekka Enberg
  0 siblings, 1 reply; 5+ messages in thread
From: Ying-Shiuan Pan @ 2013-08-30 13:58 UTC (permalink / raw)
  To: kvm; +Cc: yspan, penberg, asias.hejun, Ying-Shiuan Pan

From: Ying-Shiuan Pan <yingshiuan.pan@gmail.com>

This patch fixes a bug that vtirtio_mmio_init_ioeventfd() passed a wrong
value when it invoked ioeventfd__add_event(). True value of 2nd parameter
indicates the eventfd uses PIO bus which is used by virito-pci, however,
for virtio-mmio, the value should be false.

Signed-off-by: Ying-Shiuan Pan <yspan@itri.org.tw>
---
 tools/kvm/virtio/mmio.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/kvm/virtio/mmio.c b/tools/kvm/virtio/mmio.c
index afa2692..3838774 100644
--- a/tools/kvm/virtio/mmio.c
+++ b/tools/kvm/virtio/mmio.c
@@ -55,10 +55,10 @@ static int virtio_mmio_init_ioeventfd(struct kvm *kvm,
 		 * Vhost will poll the eventfd in host kernel side,
 		 * no need to poll in userspace.
 		 */
-		err = ioeventfd__add_event(&ioevent, true, false);
+		err = ioeventfd__add_event(&ioevent, false, false);
 	else
 		/* Need to poll in userspace. */
-		err = ioeventfd__add_event(&ioevent, true, true);
+		err = ioeventfd__add_event(&ioevent, false, true);
 	if (err)
 		return err;
 
-- 
1.8.1.2


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-09-04 10:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-30 13:58 [PATCH] kvm tools: virtio-mmio: init_ioeventfd should use MMIO for ioeventfd__add_event() Ying-Shiuan Pan
2013-09-04  9:21 ` Pekka Enberg
2013-09-04 10:07   ` Will Deacon
2013-09-04 10:13     ` Pekka Enberg
2013-09-04 10:20       ` Will Deacon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.