linux/net
Eric Dumazet a35165ca10 ipv4: do not use this_cpu_ptr() in preemptible context
this_cpu_ptr() in preemptible context is generally bad

Sep 22 05:05:55 br kernel: [   94.608310] BUG: using smp_processor_id()
in
preemptible [00000000] code: ip/2261
Sep 22 05:05:55 br kernel: [   94.608316] caller is
tunnel_dst_set.isra.28+0x20/0x60 [ip_tunnel]
Sep 22 05:05:55 br kernel: [   94.608319] CPU: 3 PID: 2261 Comm: ip Not
tainted
3.17.0-rc5 #82

We can simply use raw_cpu_ptr(), as preemption is safe in these
contexts.

Should fix https://bugzilla.kernel.org/show_bug.cgi?id=84991

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Joe <joe9mail@gmail.com>
Fixes: 9a4aa9af44 ("ipv4: Use percpu Cache route in IP tunnels")
Acked-by: Tom Herbert <therbert@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2014-09-22 18:31:18 -04:00
..
6lowpan 6lowpan: Allow 6LoWPAN to be modular 2014-08-07 11:44:18 -07:00
9p 9P: remove unnecessary break after return 2014-07-15 16:27:00 -07:00
802 net: set name_assign_type in alloc_netdev() 2014-07-15 16:12:48 -07:00
8021q net: Always untag vlan-tagged traffic on input. 2014-08-11 12:16:51 -07:00
appletalk Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-07-16 14:09:34 -07:00
atm lec: Use rtnl lock/unlock when updating MTU 2014-08-21 16:31:23 -07:00
ax25
batman-adv batman-adv: Fix parameter order of hlist_add_behind 2014-08-16 19:19:08 -07:00
bluetooth Bluetooth: Fix hci_conn reference counting for auto-connections 2014-08-20 21:57:39 +03:00
bridge bridge: Fix br_should_learn to check vlan_enabled 2014-09-15 17:38:30 -04:00
caif caif: remove unnecessary break after goto 2014-07-15 16:27:01 -07:00
can
ceph Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2014-08-13 17:43:29 -06:00
core net: fix creation adjacent device symlinks 2014-09-15 14:24:53 -04:00
dcb dcbnl : Fix misleading dcb_app->priority explanation 2014-07-30 17:21:05 -07:00
dccp inet: move ipv6only in sock_common 2014-07-01 23:46:21 -07:00
decnet
dns_resolver Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security 2014-08-06 08:06:39 -07:00
dsa net: set name_assign_type in alloc_netdev() 2014-07-15 16:12:48 -07:00
ethernet net: set name_assign_type in alloc_netdev() 2014-07-15 16:12:48 -07:00
hsr net/hsr: Remove left-over never-true conditional code. 2014-07-11 15:04:40 -07:00
ieee802154 ieee802154: 6lowpan: ensure MTU of 1280 for 6lowpan 2014-08-19 19:17:42 +02:00
ipv4 ipv4: do not use this_cpu_ptr() in preemptible context 2014-09-22 18:31:18 -04:00
ipv6 xfrm: Generate blackhole routes only from route lookup functions 2014-09-16 10:08:40 +02:00
ipx
irda irda: Fix rd_frame control field initialization in irlap_send_rd_frame() 2014-08-13 20:05:52 -07:00
iucv af_iucv: avoid path quiesce of severed path in shutdown() 2014-07-21 20:21:40 -07:00
key af_key: remove unnecessary break after return 2014-07-15 16:27:00 -07:00
l2tp l2tp: fix race while getting PMTU on PPP pseudo-wire 2014-09-05 14:40:18 -07:00
lapb
llc
mac80211 Two more fixes for mac80211 - one of them addresses a long-standing 2014-09-09 14:29:36 -04:00
mac802154 ieee802154: mac802154: handle the reserved dest mode by dropping the packet 2014-08-19 19:17:41 +02:00
mpls gre: Call gso_make_checksum 2014-06-04 22:46:38 -07:00
netfilter netfilter: add explicit Kconfig for NETFILTER_XT_NAT 2014-09-05 17:23:31 -07:00
netlabel Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-08-06 09:38:14 -07:00
netlink netlink: Annotate RCU locking for seq_file walker 2014-08-14 15:13:40 -07:00
netrom net: set name_assign_type in alloc_netdev() 2014-07-15 16:12:48 -07:00
nfc Merge tag 'master-2014-07-31' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next 2014-08-05 13:18:20 -07:00
openvswitch openvswitch: restore OVS_FLOW_CMD_NEW notifications 2014-09-19 17:28:26 -04:00
packet packet: handle too big packets for PACKET_V3 2014-08-21 16:44:28 -07:00
phonet net: set name_assign_type in alloc_netdev() 2014-07-15 16:12:48 -07:00
rds Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-06-12 14:27:40 -07:00
rfkill net: rfkill: gpio: Enable module auto-loading for ACPI based switches 2014-09-16 16:09:01 -04:00
rose net: set name_assign_type in alloc_netdev() 2014-07-15 16:12:48 -07:00
rxrpc RxRPC: Fix missing __user annotation 2014-09-09 20:39:40 -07:00
sched net: sched: shrink struct qdisc_skb_cb to 28 bytes 2014-09-22 14:21:47 -04:00
sctp net: sctp: fix ABI mismatch through sctp_assoc_to_state helper 2014-08-29 20:31:08 -07:00
sunrpc NFS client updates for Linux 3.17 2014-08-13 18:13:19 -06:00
tipc tipc: Fix build. 2014-08-19 11:16:38 -07:00
unix Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2014-06-12 14:27:40 -07:00
vmw_vsock
wimax
wireless nl80211: clear skb cb before passing to netlink 2014-09-03 11:13:14 +02:00
x25
xfrm xfrm: Generate queueing routes only from route lookup functions 2014-09-16 10:08:49 +02:00
Kconfig 6lowpan: introduce new net/6lowpan directory 2014-07-12 01:53:30 +02:00
Makefile 6lowpan: introduce new net/6lowpan directory 2014-07-12 01:53:30 +02:00
compat.c net: sendmsg: fix NULL pointer dereference 2014-07-29 12:20:22 -07:00
nonet.c
socket.c net:socket: set msg_namelen to 0 if msg_name is passed as NULL in msghdr struct from userland. 2014-09-09 17:35:46 -07:00
sysctl_net.c