mbox series

[net,0/4] net-sysfs: check device is present when showing paths

Message ID cover.1721784184.git.jamie.bainbridge@gmail.com (mailing list archive)
Headers show
Series net-sysfs: check device is present when showing paths | expand

Message

Jamie Bainbridge July 24, 2024, 1:46 a.m. UTC
A sysfs reader can race with a device reset or removal.

This was fixed for speed_show with commit 4224cfd7fb65 ("net-sysfs: add
check for netdevice being present to speed_show") so add the same check
to carrier, duplex, testing, and dormant paths.

Submitting as separate patches to make Fixes reporting accurate.

Signed-off-by: Jamie Bainbridge <jamie.bainbridge@gmail.com>

Jamie Bainbridge (4):
  net-sysfs: check device is present when showing carrier
  net-sysfs: check device is present when showing duplex
  net-sysfs: check device is present when showing testing
  net-sysfs: check device is present when showing dormant

 net/core/net-sysfs.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

--
2.39.2