* BUG: "13d0ab6750b2 net: phy: check return code when requesting PHY driver module" breaks NFS-Root
@ 2019-03-11 12:23 Marc Kleine-Budde
2019-03-11 18:04 ` Marc Kleine-Budde
0 siblings, 1 reply; 4+ messages in thread
From: Marc Kleine-Budde @ 2019-03-11 12:23 UTC (permalink / raw)
To: netdev, ptx kernel, Heiner Kallweit, Andrew Lunn
[-- Attachment #1.1: Type: text/plain, Size: 1565 bytes --]
Hello,
I'm on next-next/master and noticed that the following patch:
| 13d0ab6750b2 net: phy: check return code when requesting PHY
| driver module
breaks NFS Root for my embedded device (riotboard). The kernel dhcp
fails to get an address and thus no NFS Root.
> [ 1.869897] mdio_bus 2188000.ethernet-1:04: error -2 loading PHY driver module for ID 0x004dd072
The PHY driver is not compiled as a module, but compiled into the kernel:
> git grep 0x004dd072 drivers/net/phy/
> drivers/net/phy/at803x.c:#define ATH8035_PHY_ID 0x004dd072
> grep AT803 .config
> CONFIG_AT803X_PHY=y
After hacking the return value check away, the system boots again.
> diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c
> index ddb12f420940..49c8aa7c7c03 100644
> --- a/drivers/net/phy/phy_device.c
> +++ b/drivers/net/phy/phy_device.c
> @@ -558,7 +558,7 @@ static int phy_request_driver_module(struct phy_device *dev, int phy_id)
> if (IS_ENABLED(CONFIG_MODULES) && ret < 0) {
> phydev_err(dev, "error %d loading PHY driver module for ID 0x%08x\n",
> ret, phy_id);
> - return ret;
> + return 0;
> }
>
> return 0;
regards,
Marc
--
Pengutronix e.K. | Marc Kleine-Budde |
Industrial Linux Solutions | Phone: +49-231-2826-924 |
Vertretung West/Dortmund | Fax: +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de |
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: BUG: "13d0ab6750b2 net: phy: check return code when requesting PHY driver module" breaks NFS-Root
2019-03-11 12:23 BUG: "13d0ab6750b2 net: phy: check return code when requesting PHY driver module" breaks NFS-Root Marc Kleine-Budde
@ 2019-03-11 18:04 ` Marc Kleine-Budde
2019-03-11 18:11 ` Florian Fainelli
0 siblings, 1 reply; 4+ messages in thread
From: Marc Kleine-Budde @ 2019-03-11 18:04 UTC (permalink / raw)
To: netdev, ptx kernel, Heiner Kallweit, Andrew Lunn
[-- Attachment #1.1: Type: text/plain, Size: 969 bytes --]
On 3/11/19 1:23 PM, Marc Kleine-Budde wrote:
> Hello,
>
> I'm on next-next/master and noticed that the following patch:
>
> | 13d0ab6750b2 net: phy: check return code when requesting PHY
> | driver module
>
> breaks NFS Root for my embedded device (riotboard). The kernel dhcp
> fails to get an address and thus no NFS Root.
Just noticed that problem was fixed by commit:
| 21e194425abd net: phy: fix issue with loading PHY driver w/o initramfs
I continued bisecting and found a bad commit in the riotboard's phy
driver. I'll send a separate mail for this.
| cd28d1d6e52e net: phy: at803x: Disable phy delay for RGMII mode
Sorry for the noise,
Marc
--
Pengutronix e.K. | Marc Kleine-Budde |
Industrial Linux Solutions | Phone: +49-231-2826-924 |
Vertretung West/Dortmund | Fax: +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de |
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: BUG: "13d0ab6750b2 net: phy: check return code when requesting PHY driver module" breaks NFS-Root
2019-03-11 18:04 ` Marc Kleine-Budde
@ 2019-03-11 18:11 ` Florian Fainelli
2019-03-12 8:02 ` Marc Kleine-Budde
0 siblings, 1 reply; 4+ messages in thread
From: Florian Fainelli @ 2019-03-11 18:11 UTC (permalink / raw)
To: Marc Kleine-Budde, netdev, ptx kernel, Heiner Kallweit, Andrew Lunn
On 3/11/19 11:04 AM, Marc Kleine-Budde wrote:
> On 3/11/19 1:23 PM, Marc Kleine-Budde wrote:
>> Hello,
>>
>> I'm on next-next/master and noticed that the following patch:
>>
>> | 13d0ab6750b2 net: phy: check return code when requesting PHY
>> | driver module
>>
>> breaks NFS Root for my embedded device (riotboard). The kernel dhcp
>> fails to get an address and thus no NFS Root.
>
> Just noticed that problem was fixed by commit:
>
> | 21e194425abd net: phy: fix issue with loading PHY driver w/o initramfs
>
> I continued bisecting and found a bad commit in the riotboard's phy
> driver. I'll send a separate mail for this.
>
> | cd28d1d6e52e net: phy: at803x: Disable phy delay for RGMII mode
If your problem is with this driver, keep in mind that the at803x PHY
driver incorrectly acted on the 'phy-mode'/phy_interface_t type and you
may need DTS changes to be conforming. Of course, there is no way to
programmatically detect any of that, which adds to the fun.
--
Florian
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: BUG: "13d0ab6750b2 net: phy: check return code when requesting PHY driver module" breaks NFS-Root
2019-03-11 18:11 ` Florian Fainelli
@ 2019-03-12 8:02 ` Marc Kleine-Budde
0 siblings, 0 replies; 4+ messages in thread
From: Marc Kleine-Budde @ 2019-03-12 8:02 UTC (permalink / raw)
To: Florian Fainelli, netdev, ptx kernel, Heiner Kallweit, Andrew Lunn
[-- Attachment #1.1: Type: text/plain, Size: 981 bytes --]
On 3/11/19 7:11 PM, Florian Fainelli wrote:
>> I continued bisecting and found a bad commit in the riotboard's phy
>> driver. I'll send a separate mail for this.
>>
>> | cd28d1d6e52e net: phy: at803x: Disable phy delay for RGMII mode
>
> If your problem is with this driver, keep in mind that the at803x PHY
> driver incorrectly acted on the 'phy-mode'/phy_interface_t type and you
> may need DTS changes to be conforming. Of course, there is no way to
> programmatically detect any of that, which adds to the fun.
Thanks for the tip, that was the problem. Changing the phy-mode to
rgmii-id restores the old behaviour in the driver and the board boots again.
I'll send a patch.
Marc
--
Pengutronix e.K. | Marc Kleine-Budde |
Industrial Linux Solutions | Phone: +49-231-2826-924 |
Vertretung West/Dortmund | Fax: +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de |
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-03-12 8:21 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-11 12:23 BUG: "13d0ab6750b2 net: phy: check return code when requesting PHY driver module" breaks NFS-Root Marc Kleine-Budde
2019-03-11 18:04 ` Marc Kleine-Budde
2019-03-11 18:11 ` Florian Fainelli
2019-03-12 8:02 ` Marc Kleine-Budde
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).