aboutsummaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2015-03-20 18:51:09 -0400
committerDavid S. Miller <davem@davemloft.net>2015-03-20 18:51:09 -0400
commit0fa74a4be48e0f810d3dc6ddbc9d6ac7e86cbee8 (patch)
treeccfee93ede4e36d6d355e00e485d3d1c0fec0bdd /net/core
parent6626af692692b52c8f9e20ad8201a3255e5ab25b (diff)
parent4de930efc23b92ddf88ce91c405ee645fe6e27ea (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts: drivers/net/ethernet/emulex/benet/be_main.c net/core/sysctl_net_core.c net/ipv4/inet_diag.c The be_main.c conflict resolution was really tricky. The conflict hunks generated by GIT were very unhelpful, to say the least. It split functions in half and moved them around, when the real actual conflict only existed solely inside of one function, that being be_map_pci_bars(). So instead, to resolve this, I checked out be_main.c from the top of net-next, then I applied the be_main.c changes from 'net' since the last time I merged. And this worked beautifully. The inet_diag.c and sysctl_net_core.c conflicts were simple overlapping changes, and were easily to resolve. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r--net/core/rtnetlink.c26
-rw-r--r--net/core/skbuff.c10
-rw-r--r--net/core/sock.c4
-rw-r--r--net/core/sysctl_net_core.c10
4 files changed, 30 insertions, 20 deletions
diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
index 6abe634c666c..e7695104dbf0 100644
--- a/net/core/rtnetlink.c
+++ b/net/core/rtnetlink.c
@@ -2187,28 +2187,28 @@ replay:
2187 } 2187 }
2188 } 2188 }
2189 err = rtnl_configure_link(dev, ifm); 2189 err = rtnl_configure_link(dev, ifm);
2190 if (err < 0) { 2190 if (err < 0)
2191 if (ops->newlink) { 2191 goto out_unregister;
2192 LIST_HEAD(list_kill);
2193
2194 ops->dellink(dev, &list_kill);
2195 unregister_netdevice_many(&list_kill);
2196 } else {
2197 unregister_netdevice(dev);
2198 }
2199 goto out;
2200 }
2201
2202 if (link_net) { 2192 if (link_net) {
2203 err = dev_change_net_namespace(dev, dest_net, ifname); 2193 err = dev_change_net_namespace(dev, dest_net, ifname);
2204 if (err < 0) 2194 if (err < 0)
2205 unregister_netdevice(dev); 2195 goto out_unregister;
2206 } 2196 }
2207out: 2197out:
2208 if (link_net) 2198 if (link_net)
2209 put_net(link_net); 2199 put_net(link_net);
2210 put_net(dest_net); 2200 put_net(dest_net);
2211 return err; 2201 return err;
2202out_unregister:
2203 if (ops->newlink) {
2204 LIST_HEAD(list_kill);
2205
2206 ops->dellink(dev, &list_kill);
2207 unregister_netdevice_many(&list_kill);
2208 } else {
2209 unregister_netdevice(dev);
2210 }
2211 goto out;
2212 } 2212 }
2213} 2213}
2214 2214
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index 47c32413d5b9..cdb939b731aa 100644
--- a/net/core/skbuff.c
+++ b/net/core/skbuff.c
@@ -3689,9 +3689,13 @@ void __skb_tstamp_tx(struct sk_buff *orig_skb,
3689 struct sock *sk, int tstype) 3689 struct sock *sk, int tstype)
3690{ 3690{
3691 struct sk_buff *skb; 3691 struct sk_buff *skb;
3692 bool tsonly = sk->sk_tsflags & SOF_TIMESTAMPING_OPT_TSONLY; 3692 bool tsonly;
3693 3693
3694 if (!sk || !skb_may_tx_timestamp(sk, tsonly)) 3694 if (!sk)
3695 return;
3696
3697 tsonly = sk->sk_tsflags & SOF_TIMESTAMPING_OPT_TSONLY;
3698 if (!skb_may_tx_timestamp(sk, tsonly))
3695 return; 3699 return;
3696 3700
3697 if (tsonly) 3701 if (tsonly)
@@ -4129,7 +4133,7 @@ void skb_scrub_packet(struct sk_buff *skb, bool xnet)
4129 skb->ignore_df = 0; 4133 skb->ignore_df = 0;
4130 skb_dst_drop(skb); 4134 skb_dst_drop(skb);
4131 skb->mark = 0; 4135 skb->mark = 0;
4132 skb->sender_cpu = 0; 4136 skb_sender_cpu_clear(skb);
4133 skb_init_secmark(skb); 4137 skb_init_secmark(skb);
4134 secpath_reset(skb); 4138 secpath_reset(skb);
4135 nf_reset(skb); 4139 nf_reset(skb);
diff --git a/net/core/sock.c b/net/core/sock.c
index 744a04ddb61c..841108b5649f 100644
--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -1655,6 +1655,10 @@ void sock_rfree(struct sk_buff *skb)
1655} 1655}
1656EXPORT_SYMBOL(sock_rfree); 1656EXPORT_SYMBOL(sock_rfree);
1657 1657
1658/*
1659 * Buffer destructor for skbs that are not used directly in read or write
1660 * path, e.g. for error handler skbs. Automatically called from kfree_skb.
1661 */
1658void sock_efree(struct sk_buff *skb) 1662void sock_efree(struct sk_buff *skb)
1659{ 1663{
1660 sock_put(skb->sk); 1664 sock_put(skb->sk);
diff --git a/net/core/sysctl_net_core.c b/net/core/sysctl_net_core.c
index e1c85db5216f..95b6139d710c 100644
--- a/net/core/sysctl_net_core.c
+++ b/net/core/sysctl_net_core.c
@@ -24,6 +24,8 @@
24 24
25static int zero = 0; 25static int zero = 0;
26static int one = 1; 26static int one = 1;
27static int min_sndbuf = SOCK_MIN_SNDBUF;
28static int min_rcvbuf = SOCK_MIN_RCVBUF;
27 29
28static int net_msg_warn; /* Unused, but still a sysctl */ 30static int net_msg_warn; /* Unused, but still a sysctl */
29 31
@@ -236,7 +238,7 @@ static struct ctl_table net_core_table[] = {
236 .maxlen = sizeof(int), 238 .maxlen = sizeof(int),
237 .mode = 0644, 239 .mode = 0644,
238 .proc_handler = proc_dointvec_minmax, 240 .proc_handler = proc_dointvec_minmax,
239 .extra1 = &one, 241 .extra1 = &min_sndbuf,
240 }, 242 },
241 { 243 {
242 .procname = "rmem_max", 244 .procname = "rmem_max",
@@ -244,7 +246,7 @@ static struct ctl_table net_core_table[] = {
244 .maxlen = sizeof(int), 246 .maxlen = sizeof(int),
245 .mode = 0644, 247 .mode = 0644,
246 .proc_handler = proc_dointvec_minmax, 248 .proc_handler = proc_dointvec_minmax,
247 .extra1 = &one, 249 .extra1 = &min_rcvbuf,
248 }, 250 },
249 { 251 {
250 .procname = "wmem_default", 252 .procname = "wmem_default",
@@ -252,7 +254,7 @@ static struct ctl_table net_core_table[] = {
252 .maxlen = sizeof(int), 254 .maxlen = sizeof(int),
253 .mode = 0644, 255 .mode = 0644,
254 .proc_handler = proc_dointvec_minmax, 256 .proc_handler = proc_dointvec_minmax,
255 .extra1 = &one, 257 .extra1 = &min_sndbuf,
256 }, 258 },
257 { 259 {
258 .procname = "rmem_default", 260 .procname = "rmem_default",
@@ -260,7 +262,7 @@ static struct ctl_table net_core_table[] = {
260 .maxlen = sizeof(int), 262 .maxlen = sizeof(int),
261 .mode = 0644, 263 .mode = 0644,
262 .proc_handler = proc_dointvec_minmax, 264 .proc_handler = proc_dointvec_minmax,
263 .extra1 = &one, 265 .extra1 = &min_rcvbuf,
264 }, 266 },
265 { 267 {
266 .procname = "dev_weight", 268 .procname = "dev_weight",