Re: [PATCH] net: usb: asix: avoid to call phylink_stop() a second time

From: Xu Yang
Date: Mon Aug 18 2025 - 02:50:18 EST


On Fri, Aug 15, 2025 at 02:59:12PM +0200, Andrew Lunn wrote:
> > > > Looking at ax88172a.c, lan78xx.c and smsc95xx.c, they don't have
> > > > anything like this. Is asix special, or are all the others broken as
> > > > well?
> > >
> > > I have limited USB net devices. So I can't test others now.
> > >

[...]

> > >
> > > Should I change usbnet common code like below?
> > >
> > > diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
> > > index c39dfa17813a..44a8d325dfb1 100644
> > > --- a/drivers/net/usb/usbnet.c
> > > +++ b/drivers/net/usb/usbnet.c
> > > @@ -839,7 +839,7 @@ int usbnet_stop (struct net_device *net)
> > > pm = usb_autopm_get_interface(dev->intf);
> > > /* allow minidriver to stop correctly (wireless devices to turn off
> > > * radio etc) */
> > > - if (info->stop) {
> > > + if (info->stop && !dev->suspend_count) {
> > > retval = info->stop(dev);
> > > if (retval < 0)
> > > netif_info(dev, ifdown, dev->net,
> >
> > Do you mind sharing some suggestions on this? Thanks in advance!
>
> It does look to be a common problem, so solving it in usbnet would be
> best.

Okay. Thank you!

Thanks,
Xu Yang

>
> Andrew