Skip to content

Commit

Permalink
virtio_test: verify if virtqueue_kick() succeeded
Browse files Browse the repository at this point in the history
Verify if a host kick succeeded by checking return value of virtqueue_kick().

Signed-off-by: Heinz Graalfs <graalfs@linux.vnet.ibm.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
  • Loading branch information
Heinz Graalfs authored and Rusty Russell committed Oct 29, 2013
1 parent 6797590 commit 53c18c9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tools/virtio/virtio_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,8 @@ static void run_test(struct vdev_info *dev, struct vq_info *vq,
GFP_ATOMIC);
if (likely(r == 0)) {
++started;
virtqueue_kick(vq->vq);
if (unlikely(!virtqueue_kick(vq->vq))
r = -1;
}
} else
r = -1;
Expand Down

0 comments on commit 53c18c9

Please sign in to comment.