Re: [PATCH net v2] r8152: Use BMSR to detect the link state

From: Andrew Lunn

Date: Wed Oct 14 2026 - 12:40:55 EST


> > For those devices which are broken, double read the BMSR. The danger is,
> > somebody who quickly unplugs and replugs the cable is not going to get the
> > down notification. The dhcp client will not restart, so the old IP address will be
> > used, for the next hour to day, and the network is broken.
>
> Could this actually happen?
> I think it would take several seconds for the link to go down and then come back up.
> Wouldn't this issue occur only if the link transitions from up to down and back up before the driver processes the link-down event?

802.3 thinks this can happen, otherwise why make it latch?

If i'm just going from port 7 to port 8 of my switch, it might happen.

Or i reconfigure my managed switch to change the port from one subnet
to another subnet. The RJ45 is not moved, it is just a configuration
change. The switch should do a down/up on its side to indicate
something has changed, and that needs to be reported to userspace so
dhcpcd gets a new IP address.

Andrew