linux/drivers/net/ethernet/sfc
Eric Dumazet 1eb2cded45 net: annotate writes on dev->mtu from ndo_change_mtu()
Simon reported that ndo_change_mtu() methods were never
updated to use WRITE_ONCE(dev->mtu, new_mtu) as hinted
in commit 501a90c945 ("inet: protect against too small
mtu values.")

We read dev->mtu without holding RTNL in many places,
with READ_ONCE() annotations.

It is time to take care of ndo_change_mtu() methods
to use corresponding WRITE_ONCE()

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Simon Horman <horms@kernel.org>
Closes: https://lore.kernel.org/netdev/20240505144608.GB67882@kernel.org/
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Reviewed-by: Sabrina Dubroca <sd@queasysnail.net>
Reviewed-by: Simon Horman <horms@kernel.org>
Acked-by: Shannon Nelson <shannon.nelson@amd.com>
Link: https://lore.kernel.org/r/20240506102812.3025432-1-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2024-05-07 16:19:14 -07:00
..
falcon net: annotate writes on dev->mtu from ndo_change_mtu() 2024-05-07 16:19:14 -07:00
siena net: annotate writes on dev->mtu from ndo_change_mtu() 2024-05-07 16:19:14 -07:00
Kconfig
Makefile
bitfield.h
ef10.c
ef10_regs.h
ef10_sriov.c
ef10_sriov.h
ef100.c
ef100.h
ef100_ethtool.c
ef100_ethtool.h
ef100_netdev.c
ef100_netdev.h
ef100_nic.c
ef100_nic.h
ef100_regs.h
ef100_rep.c
ef100_rep.h
ef100_rx.c
ef100_rx.h
ef100_sriov.c
ef100_sriov.h
ef100_tx.c
ef100_tx.h
efx.c
efx.h
efx_channels.c
efx_channels.h
efx_common.c net: annotate writes on dev->mtu from ndo_change_mtu() 2024-05-07 16:19:14 -07:00
efx_common.h
efx_devlink.c
efx_devlink.h
enum.h
ethtool.c
ethtool_common.c
ethtool_common.h
filter.h
io.h
mae.c
mae.h
mae_counter_format.h
mcdi.c
mcdi.h
mcdi_filters.c
mcdi_filters.h
mcdi_functions.c
mcdi_functions.h
mcdi_mon.c
mcdi_pcol.h
mcdi_pcol_mae.h
mcdi_port.c
mcdi_port.h
mcdi_port_common.c
mcdi_port_common.h
mtd.c
net_driver.h
nic.c
nic.h
nic_common.h
ptp.c
ptp.h
rx.c
rx_common.c
rx_common.h
selftest.c
selftest.h
sriov.c
sriov.h
tc.c
tc.h
tc_bindings.c
tc_bindings.h
tc_conntrack.c
tc_conntrack.h
tc_counters.c
tc_counters.h
tc_encap_actions.c
tc_encap_actions.h
tx.c
tx.h
tx_common.c
tx_common.h
tx_tso.c
workarounds.h