Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 340720
b: refs/heads/master
c: be44389
h: refs/heads/master
v: v3
  • Loading branch information
Amerigo Wang authored and David S. Miller committed Nov 9, 2012
1 parent 1875b35 commit 9b044e6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c068e7774f6382a15e7a5ee7cd31ea662d2a5f97
refs/heads/master: be44389964c1855ccffedbfbf5d2a943bb84ad66
12 changes: 4 additions & 8 deletions trunk/drivers/net/virtio_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,7 @@ static struct sk_buff *page_to_skb(struct virtnet_info *vi,
* the case of a broken device.
*/
if (unlikely(len > MAX_SKB_FRAGS * PAGE_SIZE)) {
if (net_ratelimit())
pr_debug("%s: too much data\n", skb->dev->name);
net_dbg_ratelimited("%s: too much data\n", skb->dev->name);
dev_kfree_skb(skb);
return NULL;
}
Expand Down Expand Up @@ -333,9 +332,8 @@ static void receive_buf(struct net_device *dev, void *buf, unsigned int len)
skb_shinfo(skb)->gso_type = SKB_GSO_TCPV6;
break;
default:
if (net_ratelimit())
printk(KERN_WARNING "%s: bad gso type %u.\n",
dev->name, hdr->hdr.gso_type);
net_warn_ratelimited("%s: bad gso type %u.\n",
dev->name, hdr->hdr.gso_type);
goto frame_err;
}

Expand All @@ -344,9 +342,7 @@ static void receive_buf(struct net_device *dev, void *buf, unsigned int len)

skb_shinfo(skb)->gso_size = hdr->hdr.gso_size;
if (skb_shinfo(skb)->gso_size == 0) {
if (net_ratelimit())
printk(KERN_WARNING "%s: zero gso size.\n",
dev->name);
net_warn_ratelimited("%s: zero gso size.\n", dev->name);
goto frame_err;
}

Expand Down

0 comments on commit 9b044e6

Please sign in to comment.