diff options
Diffstat (limited to 'drivers/virtio')
-rw-r--r-- | drivers/virtio/virtio_ring.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/virtio/virtio_ring.c b/drivers/virtio/virtio_ring.c index c2fa5c630813..937a49d6772c 100644 --- a/drivers/virtio/virtio_ring.c +++ b/drivers/virtio/virtio_ring.c | |||
@@ -184,6 +184,11 @@ static void *vring_get_buf(struct virtqueue *_vq, unsigned int *len) | |||
184 | 184 | ||
185 | START_USE(vq); | 185 | START_USE(vq); |
186 | 186 | ||
187 | if (unlikely(vq->broken)) { | ||
188 | END_USE(vq); | ||
189 | return NULL; | ||
190 | } | ||
191 | |||
187 | if (!more_used(vq)) { | 192 | if (!more_used(vq)) { |
188 | pr_debug("No more buffers in queue\n"); | 193 | pr_debug("No more buffers in queue\n"); |
189 | END_USE(vq); | 194 | END_USE(vq); |