diff options
-rw-r--r-- | tizen/src/hw/virtio/maru_virtio_tablet.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/tizen/src/hw/virtio/maru_virtio_tablet.c b/tizen/src/hw/virtio/maru_virtio_tablet.c index 9a564ba502..5bab39cc95 100644 --- a/tizen/src/hw/virtio/maru_virtio_tablet.c +++ b/tizen/src/hw/virtio/maru_virtio_tablet.c @@ -148,9 +148,7 @@ static void maru_tablet_bh(void *opaque) qemu_mutex_unlock(&vt->mutex); /* Get a queue buffer which is written by guest side. */ - do { - elem = virtqueue_pop(vt->vq, sizeof(VirtQueueElement)); - } while (elem); + elem = virtqueue_pop(vt->vq, sizeof(VirtQueueElement)); qemu_mutex_lock(&vt->mutex); while (!QTAILQ_EMPTY(&events_queue)) { @@ -160,10 +158,10 @@ static void maru_tablet_bh(void *opaque) /* copy event into virtio buffer */ len = iov_from_buf(elem->in_sg, elem->in_num, push_len, &(event_entry->tablet), sizeof(EmulTabletEvent)); - if(len != sizeof(EmulTabletEvent)) { + if (len != sizeof(EmulTabletEvent)) { LOG_WARNING("len != sizeof(EmulTabletEvent).\n"); LOG_WARNING("len: %zu, sizeof(EmulTabletEvent): %zu\n", - len, sizeof(EmulTabletEvent)); + len, sizeof(EmulTabletEvent)); } push_len += sizeof(EmulTabletEvent); |