summaryrefslogtreecommitdiff
path: root/content.tex
diff options
context:
space:
mode:
authorrusty <rusty@0c8fb4dd-22a2-4bb5-bc14-6c75a5f43652>2014-02-10 10:31:48 +0000
committerrusty <rusty@0c8fb4dd-22a2-4bb5-bc14-6c75a5f43652>2014-02-10 10:31:48 +0000
commit261e83f3478c58327444d88db755444659f30574 (patch)
treeedb710cb2dd3e4a63cc90792ff5924228ee46500 /content.tex
parent9d7baf4228cb7c12dbd9749bfc327585015aa634 (diff)
example code does not have to be optimal but it
seems cleaner to disable interrupts after we recheck the ring empty state. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> git-svn-id: https://tools.oasis-open.org/version-control/svn/virtio@218 0c8fb4dd-22a2-4bb5-bc14-6c75a5f43652
Diffstat (limited to 'content.tex')
-rw-r--r--content.tex2
1 files changed, 2 insertions, 0 deletions
diff --git a/content.tex b/content.tex
index 2adc393..bc53749 100644
--- a/content.tex
+++ b/content.tex
@@ -760,6 +760,8 @@ for (;;) {
if (vq->last_seen_used != le16_to_cpu(vring->used.idx))
break;
+
+ vring_disable_interrupts(vq);
}
struct vring_used_elem *e = vring.used->ring[vq->last_seen_used%vsz];