aboutsummaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
Diffstat (limited to 'net/core')
-rw-r--r--net/core/dev.c2
-rw-r--r--net/core/rtnetlink.c5
2 files changed, 4 insertions, 3 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index 92584bfef09b..f769098774b7 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -1990,7 +1990,7 @@ static struct netdev_queue *dev_pick_tx(struct net_device *dev,
1990 queue_index = skb_tx_hash(dev, skb); 1990 queue_index = skb_tx_hash(dev, skb);
1991 1991
1992 if (sk) { 1992 if (sk) {
1993 struct dst_entry *dst = rcu_dereference(sk->sk_dst_cache); 1993 struct dst_entry *dst = rcu_dereference_bh(sk->sk_dst_cache);
1994 1994
1995 if (dst && skb_dst(skb) == dst) 1995 if (dst && skb_dst(skb) == dst)
1996 sk_tx_queue_set(sk, queue_index); 1996 sk_tx_queue_set(sk, queue_index);
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index 4568120d8533..fe776c9ddeca 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -1270,10 +1270,11 @@ replay:
1270 err = ops->newlink(net, dev, tb, data); 1270 err = ops->newlink(net, dev, tb, data);
1271 else 1271 else
1272 err = register_netdevice(dev); 1272 err = register_netdevice(dev);
1273 if (err < 0 && !IS_ERR(dev)) { 1273
1274 if (err < 0 && !IS_ERR(dev))
1274 free_netdev(dev); 1275 free_netdev(dev);
1276 if (err < 0)
1275 goto out; 1277 goto out;
1276 }
1277 1278
1278 err = rtnl_configure_link(dev, ifm); 1279 err = rtnl_configure_link(dev, ifm);
1279 if (err < 0) 1280 if (err < 0)