netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Gabriel Hojda <ghojda@yo2urs.ro>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Martyn Welch <martyn.welch@collabora.com>,
	netdev@vger.kernel.org, Krzysztof Kozlowski <krzk@kernel.org>,
	Marek Szyprowski <m.szyprowski@samsung.com>,
	Markus Reichl <m.reichl@fivetechno.de>,
	Steve Glendinning <steve.glendinning@shawell.net>,
	UNGLinuxDriver@microchip.com,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	stable@kernel.org
Subject: Re: Issues with smsc95xx driver since a049a30fc27c
Date: Sat, 18 Dec 2021 19:23:02 +0200	[thread overview]
Message-ID: <36f765d8450ba08cb3f8aecab0cadd89@yo2urs.ro> (raw)
In-Reply-To: <Yb4QFDQ0rFfFsT+Y@lunn.ch>

On 2021-12-18 18:45, Andrew Lunn wrote:
> On Fri, Dec 17, 2021 at 03:45:08PM +0000, Martyn Welch wrote:
>> I've had some reports of the smsc95xx driver failing to work for the
>> ODROID-X2 and ODROID-U3 since a049a30fc27c was merged (also backported
>> to 5.15.y stable branch, which I believe is what those affected by 
>> this
>> are using).
>> 
>> Since then we have performed a number of tests, here's what we've 
>> found
>> so far:
>> 
>> ODROID-U3 (built-in LAN9730):
>> 
>>  - No errors reported from smsc95xx driver, however networking broken
>>    (can not perform DHCP via NetworkManager, Fedora user space).
>> 
>>  - Networking starts working if device forced into promiscuous mode
>>    (Gabriel noticed this whilst running tcpdump)
>> 
>> 
>> ODROID-X2 (built in LAN9514):
>> 
>>  - Networking not brought up (Using Debian Buster and Bullseye with
>> traditional `/etc/network/interfaces` approach).
>> 
>>  - As with Odroid-u3, works when running in promiscuous mode.
> 
> Hi Martyn
> 
> Promisc mode is really odd, given what
> 
> commit a049a30fc27c1cb2e12889bbdbd463dbf750103a
> Author: Martyn Welch <martyn.welch@collabora.com>
> Date:   Mon Nov 22 18:44:45 2021 +0000
> 
>     net: usb: Correct PHY handling of smsc95xx
> 
> does. Has it been confirmed this is really the patch which causes
> the problem?
> 
> Does mii-tool -vvv how any difference between the working and broken
> case?
> 
> Can you also confirm the same PHY driver is used before/after this
> patch. There is a chance one is using a specific PHY driver and the
> other genphy.
> 
>     Andrew

hi Andrew,

on my odroid-u3, with all kernel versions since 5.15.6 (where the patch 
was applied) and also with 5.16.y if tcpdump is running the network 
works. when tcpdump process is killed/stopped, networking stops working.

1. as a test that this is the offending patch, i've recompiled the 
fedora kernel 5.15.7 with the patch reverted and everything was working 
normally as it last worked with 5.15.5

2.1. kernel 5.15.5 - "mii-tool -vvv eth0"

Using SIOCGMIIPHY=0x8947
eth0: negotiated 1000baseT-HD flow-control, link ok
   registers for MII PHY 1:
     3100 782d 0007 c101 01e1 45e1 0001 ffff
     ffff ffff ffff ffff ffff 0000 0000 0000
     0040 0002 00e1 ffff 0000 0000 0000 0000
     0b9d 0000 0000 000a 0000 00c8 0000 1058
   product info: vendor 00:01:f0, model 16 rev 1
   basic mode:   autonegotiation enabled
   basic status: autonegotiation complete, link ok
   capabilities: 1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 
10baseT-FD 10baseT-HD
   advertising:  1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 
10baseT-FD 10baseT-HD
   link partner: 1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 
10baseT-FD 10baseT-HD flow-control

2.2. kernel 5.15.8 - "mii-tool -vvv eth0"

Using SIOCGMIIPHY=0x8947
eth0: negotiated 1000baseT-HD flow-control, link ok
   registers for MII PHY 1:
     3100 782d 0007 c101 01e1 45e1 0003 ffff
     ffff ffff ffff ffff ffff 0000 0000 0000
     0040 0002 00e1 ffff 0000 0000 0000 0000
     0b9d 0000 0000 000a 0000 00c8 0000 1058
   product info: vendor 00:01:f0, model 16 rev 1
   basic mode:   autonegotiation enabled
   basic status: autonegotiation complete, link ok
   capabilities: 1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 
10baseT-FD 10baseT-HD
   advertising:  1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 
10baseT-FD 10baseT-HD
   link partner: 1000baseT-HD 1000baseT-FD 100baseTx-FD 100baseTx-HD 
10baseT-FD 10baseT-HD flow-control

3.1 kernel 5.15.5 - "dmesg | grep -i phy"

[    0.000000] Booting Linux on physical CPU 0xa00
[    0.000000] GIC physical location is 0x10490000
[    2.290065] libphy: Fixed MDIO Bus: probed
[    6.763235] samsung-usb2-phy 125b0000.exynos-usbphy: supply vbus not 
found, using dummy regulator
[    8.045968] libphy: smsc95xx-mdiobus: probed
[   23.261816] Generic PHY usb-001:002:01: attached PHY driver 
(mii_bus:phy_addr=usb-001:002:01, irq=POLL)

3.1 kernel 5.15.8 - "dmesg | grep -i phy"

[    0.000000] Booting Linux on physical CPU 0xa00
[    0.000000] GIC physical location is 0x10490000
[    3.291292] libphy: Fixed MDIO Bus: probed
[   10.198145] samsung-usb2-phy 125b0000.exynos-usbphy: supply vbus not 
found, using dummy regulator
[   11.740943] libphy: smsc95xx-mdiobus: probed
[   11.742916] Generic PHY usb-001:002:01: attached PHY driver 
(mii_bus:phy_addr=usb-001:002:01, irq=POLL)


  reply	other threads:[~2021-12-18 17:38 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-17 15:45 Issues with smsc95xx driver since a049a30fc27c Martyn Welch
2021-12-18 16:45 ` Andrew Lunn
2021-12-18 17:23   ` Gabriel Hojda [this message]
2021-12-18 18:22     ` Andrew Lunn
2021-12-18 18:32       ` Andrew Lunn
2021-12-18 20:33         ` Gabriel Hojda
2021-12-20 10:37           ` Markus Reichl
     [not found]         ` <c95954ec12dfcf8877c1bf92047c0268@yo2urs.ro>
2021-12-20  8:53           ` Andrew Lunn
2021-12-20 20:04             ` Gabriel Hojda
2021-12-20 21:28             ` Gabriel Hojda

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=36f765d8450ba08cb3f8aecab0cadd89@yo2urs.ro \
    --to=ghojda@yo2urs.ro \
    --cc=UNGLinuxDriver@microchip.com \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=krzk@kernel.org \
    --cc=kuba@kernel.org \
    --cc=m.reichl@fivetechno.de \
    --cc=m.szyprowski@samsung.com \
    --cc=martyn.welch@collabora.com \
    --cc=netdev@vger.kernel.org \
    --cc=stable@kernel.org \
    --cc=steve.glendinning@shawell.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).