[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f7fdecaf-c3c4-4770-9e03-d1f15fd093fa@redhat.com>
Date: Thu, 15 Aug 2024 12:15:34 +0200
From: Paolo Abeni <pabeni@...hat.com>
To: Mengyuan Lou <mengyuanlou@...-swift.com>, netdev@...r.kernel.org
Cc: przemyslaw.kitszel@...el.com, andrew@...n.ch, jiawenwu@...stnetic.com,
duanqiangwen@...-swift.com
Subject: Re: [PATCH net] net: ngbe: Fix phy mode set to external phy
On 8/12/24 12:30, Mengyuan Lou wrote:
> The MAC only has add the TX delay and it can not be modified.
> MAC and PHY are both set the TX delay cause transmission problems.
> So just disable TX delay in PHY, when use rgmii to attach to
> external phy, set PHY_INTERFACE_MODE_RGMII_RXID to phy drivers.
> And it is does not matter to internal phy.
>
> Fixes: a1cf597b99a7 ("net: ngbe: Add ngbe mdio bus driver.")
> Signed-off-by: Mengyuan Lou <mengyuanlou@...-swift.com>
> ---
> v2:
> -Add a comment for the code modification.
> -Add the problem in commit messages.
> v1:
> https://lore.kernel.org/netdev/C1587837D62D1BC0+20240806082520.29193-1-mengyuanlou@net-swift.com/
>
> drivers/net/ethernet/wangxun/ngbe/ngbe_mdio.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/wangxun/ngbe/ngbe_mdio.c b/drivers/net/ethernet/wangxun/ngbe/ngbe_mdio.c
> index ba33a57b42c2..0876b2e810c0 100644
> --- a/drivers/net/ethernet/wangxun/ngbe/ngbe_mdio.c
> +++ b/drivers/net/ethernet/wangxun/ngbe/ngbe_mdio.c
> @@ -215,10 +215,14 @@ int ngbe_phy_connect(struct wx *wx)
> {
> int ret;
>
> + /* The MAC only has add the Tx delay and it can not be modified.
> + * So just disable TX delay in PHY, and it is does not matter to
> + * internal phy.
> + */
> ret = phy_connect_direct(wx->netdev,
> wx->phydev,
> ngbe_handle_link_change,
> - PHY_INTERFACE_MODE_RGMII_ID);
> + PHY_INTERFACE_MODE_RGMII_RXID);
> if (ret) {
> wx_err(wx, "PHY connect failed.\n");
> return ret;
Does not apply cleanly to net since:
commit bc2426d74aa35cd8ec9c97a253ef57c2c5cd730c
Author: Jiawen Wu <jiawenwu@...stnetic.com>
Date: Wed Jan 3 10:08:49 2024 +0800
net: ngbe: convert phylib to phylink
Please rebase
Thanks,
Paolo
Powered by blists - more mailing lists