summaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-12-08 21:58:51 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2017-12-08 21:58:51 +0100
commit900add27f55660158e7cac07674882befec49297 (patch)
treeb3537ac60c6ab0001bfe1b3c4ed6c2a20bc82738 /drivers/net
parentMerge tag 'for-linus-4.15-rc3-tag' of git://git.kernel.org/pub/scm/linux/kern... (diff)
parentvirtio_net: fix return value check in receive_mergeable() (diff)
downloadlinux-900add27f55660158e7cac07674882befec49297.tar.xz
linux-900add27f55660158e7cac07674882befec49297.zip
Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
Pull virtio bugfixes from Michael Tsirkin: "A couple of minor bugfixes" * tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost: virtio_net: fix return value check in receive_mergeable() virtio_mmio: add cleanup for virtio_mmio_remove virtio_mmio: add cleanup for virtio_mmio_probe
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/virtio_net.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 19a985ef9104..559b215c0169 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers/net/virtio_net.c
@@ -756,7 +756,7 @@ static struct sk_buff *receive_mergeable(struct net_device *dev,
int num_skb_frags;
buf = virtqueue_get_buf_ctx(rq->vq, &len, &ctx);
- if (unlikely(!ctx)) {
+ if (unlikely(!buf)) {
pr_debug("%s: rx error: %d buffers out of %d missing\n",
dev->name, num_buf,
virtio16_to_cpu(vi->vdev,