linux/drivers/net/ethernet
Toke Høiland-Jørgensen 2f1e432d33 stmmac: Remove rcu_read_lock() around XDP program invocation
The stmmac driver has rcu_read_lock()/rcu_read_unlock() pairs around XDP
program invocations. However, the actual lifetime of the objects referred
by the XDP program invocation is longer, all the way through to the call to
xdp_do_flush(), making the scope of the rcu_read_lock() too small. This
turns out to be harmless because it all happens in a single NAPI poll
cycle (and thus under local_bh_disable()), but it makes the rcu_read_lock()
misleading.

Rather than extend the scope of the rcu_read_lock(), just get rid of it
entirely. With the addition of RCU annotations to the XDP_REDIRECT map
types that take bh execution into account, lockdep even understands this to
be safe, so there's really no reason to keep it around.

Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Cc: Alexandre Torgue <alexandre.torgue@foss.st.com>
Cc: Jose Abreu <joabreu@synopsys.com>
Link: https://lore.kernel.org/bpf/20210624160609.292325-19-toke@redhat.com
2021-06-24 19:46:25 +02:00
..
3com net: 3com: remove leading spaces before tabs 2021-05-19 12:17:30 -07:00
8390 net: 8390: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
actions
adaptec treewide: remove editor modelines and cruft 2021-05-07 00:26:34 -07:00
aeroflex
agere
alacritech
allwinner
alteon net: alteon: remove leading spaces before tabs 2021-05-19 12:17:30 -07:00
altera
amazon ena: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:43:28 +02:00
amd net: amd: remove leading spaces before tabs 2021-05-19 12:17:30 -07:00
apm
apple net: apple: remove leading spaces before tabs 2021-05-19 12:17:30 -07:00
aquantia
arc net: arc: Demote non-compliant kernel-doc headers 2021-05-17 14:12:38 -07:00
atheros atl1c: add 4 RX/TX queue support for Mikrotik 10/25G NIC 2021-05-27 16:06:46 -07:00
broadcom bnxt: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:43:49 +02:00
brocade net: brocade: bna: Fix wrong function name in comments 2021-05-17 14:12:38 -07:00
cadence net: macb: Use devm_platform_get_and_ioremap_resource() 2021-06-07 14:07:22 -07:00
calxeda net: calxeda: Fix wrong function name in comments 2021-05-17 14:12:38 -07:00
cavium thunderx: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:44:02 +02:00
chelsio net: chelsio: cxgb4: use eth_zero_addr() to assign zero address 2021-06-16 00:53:17 -07:00
cirrus
cisco ethernet:enic: Fix a use after free bug in enic_hard_start_xmit 2021-05-03 13:23:00 -07:00
cortina net: gemini: Use devm_platform_get_and_ioremap_resource() 2021-06-07 13:20:00 -07:00
davicom net: davicom: Remove redundant assignment to ret 2021-04-26 12:48:30 -07:00
dec net: tulip: Remove the repeated declaration 2021-06-07 14:03:11 -07:00
dlink net: dlink: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
emulex
ezchip
faraday net: ftgmac100: add missing error return code in ftgmac100_probe() 2021-05-23 16:16:24 -07:00
freescale freescale: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:44:17 +02:00
fujitsu Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2021-05-27 09:55:10 -07:00
google gve: Correct SKB queue index validation. 2021-05-17 15:38:40 -07:00
hisilicon net: hns3: use bounce buffer when rx page can not be reused 2021-06-16 00:36:06 -07:00
huawei net: huawei: hinic: Fix wrong function name in comments 2021-05-17 14:12:38 -07:00
i825xx
ibm ibmvnic: fix send_request_map incompatible argument 2021-06-14 12:56:50 -07:00
intel intel: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:44:34 +02:00
marvell marvell: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:44:58 +02:00
mediatek net: ethernet: mtk_eth_soc: Fix packet statistics support for MT7628/88 2021-05-23 16:13:11 -07:00
mellanox mlx4: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:45:18 +02:00
micrel net: phy: micrel: move phy reg offsets to common header 2021-06-14 12:54:43 -07:00
microchip net: encx24j600: fix kernel-doc syntax in file headers 2021-05-20 15:25:38 -07:00
microsoft net: mana: Use struct_size() in kzalloc() 2021-05-13 15:58:46 -07:00
moxa net: moxa: Use devm_platform_get_and_ioremap_resource() 2021-06-07 14:08:30 -07:00
mscc net: mscc: ocelot: support PTP Sync one-step timestamping 2021-04-27 14:10:15 -07:00
myricom ethernet: myri10ge: Fix missing error code in myri10ge_probe() 2021-06-01 15:54:38 -07:00
natsemi net: natsemi: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
neterion net: vxge: Declare the function vxge_reset_all_vpaths as void 2021-06-01 15:29:43 -07:00
netronome nfp: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:45:26 +02:00
ni net: nixge: simplify code with devm platform functions 2021-06-08 16:36:57 -07:00
nvidia
nxp
oki-semi net: pch_gbe: remove unneeded MODULE_VERSION() call 2021-05-10 14:58:20 -07:00
packetengines
pasemi
pensando ionic: fix ptp support config breakage 2021-05-11 16:20:27 -07:00
qlogic qede: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:45:39 +02:00
qualcomm net: qualcomm: rmnet: Remove some unneeded casts 2021-06-16 12:19:50 -07:00
rdc net: r6040: Allow restarting auto-negotiation 2021-05-23 17:23:59 -07:00
realtek r8169: avoid link-up interrupt issue on RTL8106e if user enables ASPM 2021-06-11 12:54:25 -07:00
renesas net: ethernet: ravb: Use devm_platform_get_and_ioremap_resource() 2021-06-09 13:51:11 -07:00
rocker net: bridge: switchdev: include local flag in FDB notifications 2021-04-16 15:15:45 -07:00
samsung net: samsung: sxgbe: Fix wrong function name in comments 2021-05-17 14:12:39 -07:00
seeq net: seeq: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
sfc sfc: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:46:01 +02:00
sgi net: sgi: ioc3-eth: check return value after calling platform_get_resource() 2021-06-09 15:24:43 -07:00
silan
sis net: sis: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
smsc net: smsc: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
socionext netsec: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:46:12 +02:00
stmicro stmmac: Remove rcu_read_lock() around XDP program invocation 2021-06-24 19:46:25 +02:00
sun Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2021-05-27 09:55:10 -07:00
synopsys
tehuti
ti net: ti: add pp skb recycling support 2021-06-15 11:50:43 -07:00
toshiba
tundra
via net: via: Fix wrong function name in comments 2021-05-17 14:12:39 -07:00
wiznet net: w5100: Use devm_platform_get_and_ioremap_resource() 2021-06-10 13:53:13 -07:00
xilinx net: axienet: Use devm_platform_get_and_ioremap_resource() 2021-06-10 13:53:13 -07:00
xircom net: xircom: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
xscale net: ethernet: ixp4xx_eth: Use devm_platform_get_and_ioremap_resource() 2021-06-07 13:05:37 -07:00
dnet.c
dnet.h
ec_bhf.c
ethoc.c
fealnx.c net: fealnx: remove leading spaces before tabs 2021-05-19 12:17:31 -07:00
jme.c
jme.h
Kconfig net: korina: Make driver COMPILE_TESTable 2021-04-19 15:58:14 -07:00
korina.c net: korina: Fix return value check in korina_probe() 2021-05-13 15:54:08 -07:00
lantiq_etop.c
lantiq_xrx200.c net: lantiq: Use devm_platform_get_and_ioremap_resource() 2021-06-07 13:05:37 -07:00
Makefile net: mana: Add a driver for Microsoft Azure Network Adapter (MANA) 2021-04-19 15:24:25 -07:00