diff options
author | Olof Johansson <olof@lixom.net> | 2013-02-12 15:08:21 -0800 |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2013-02-12 15:08:21 -0800 |
commit | 2cb6a0708e6680f0b8e6f3ab6b0a46d1c19d8b39 (patch) | |
tree | b81bc4cc720e6a86498de1edc675e24845e611e0 /net/openvswitch/vport-netdev.c | |
parent | 78d9b8055b9aaf53ced11fc15728df31610a21e9 (diff) | |
parent | 836dc9e3fbbab0c30aa6e664417225f5c1fb1c39 (diff) | |
download | blackbird-obmc-linux-2cb6a0708e6680f0b8e6f3ab6b0a46d1c19d8b39.tar.gz blackbird-obmc-linux-2cb6a0708e6680f0b8e6f3ab6b0a46d1c19d8b39.zip |
Merge tag 'v3.8-rc7' into next/boards
Linux 3.8-rc7
Diffstat (limited to 'net/openvswitch/vport-netdev.c')
-rw-r--r-- | net/openvswitch/vport-netdev.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/net/openvswitch/vport-netdev.c b/net/openvswitch/vport-netdev.c index a9327e2e48ce..670cbc3518de 100644 --- a/net/openvswitch/vport-netdev.c +++ b/net/openvswitch/vport-netdev.c @@ -35,10 +35,11 @@ /* Must be called with rcu_read_lock. */ static void netdev_port_receive(struct vport *vport, struct sk_buff *skb) { - if (unlikely(!vport)) { - kfree_skb(skb); - return; - } + if (unlikely(!vport)) + goto error; + + if (unlikely(skb_warn_if_lro(skb))) + goto error; /* Make our own copy of the packet. Otherwise we will mangle the * packet for anyone who came before us (e.g. tcpdump via AF_PACKET). @@ -50,6 +51,10 @@ static void netdev_port_receive(struct vport *vport, struct sk_buff *skb) skb_push(skb, ETH_HLEN); ovs_vport_receive(vport, skb); + return; + +error: + kfree_skb(skb); } /* Called with rcu_read_lock and bottom-halves disabled. */ @@ -169,9 +174,6 @@ static int netdev_send(struct vport *vport, struct sk_buff *skb) goto error; } - if (unlikely(skb_warn_if_lro(skb))) - goto error; - skb->dev = netdev_vport->dev; len = skb->len; dev_queue_xmit(skb); |