lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250319114802.4d470655@fedora.home>
Date: Wed, 19 Mar 2025 11:48:02 +0100
From: Maxime Chevallier <maxime.chevallier@...tlin.com>
To: Oleksij Rempel <o.rempel@...gutronix.de>
Cc: "David S. Miller" <davem@...emloft.net>, Eric Dumazet
 <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>, Paolo Abeni
 <pabeni@...hat.com>, Woojung Huh <woojung.huh@...rochip.com>, Andrew Lunn
 <andrew+netdev@...n.ch>, Russell King <rmk+kernel@...linux.org.uk>,
 Thangaraj Samynathan <Thangaraj.S@...rochip.com>, Rengarajan Sundararajan
 <Rengarajan.S@...rochip.com>, kernel@...gutronix.de,
 linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
 UNGLinuxDriver@...rochip.com, Phil Elwell <phil@...pberrypi.org>, Simon
 Horman <horms@...nel.org>
Subject: Re: [PATCH net-next v5 2/6] net: usb: lan78xx: Convert to PHYlink
 for improved PHY and MAC management

Hi Oleksij,

On Wed, 19 Mar 2025 09:49:48 +0100
Oleksij Rempel <o.rempel@...gutronix.de> wrote:

> Convert the LAN78xx driver to use the PHYlink framework for managing
> PHY and MAC interactions.
> 
> Key changes include:
> - Replace direct PHY operations with phylink equivalents (e.g.,
>   phylink_start, phylink_stop).
> - Introduce lan78xx_phylink_setup for phylink initialization and
>   configuration.
> - Add phylink MAC operations (lan78xx_mac_config,
>   lan78xx_mac_link_down, lan78xx_mac_link_up) for managing link
>   settings and flow control.
> - Remove redundant and now phylink-managed functions like
>   `lan78xx_link_status_change`.
> - update lan78xx_get/set_pause to use phylink helpers
> 
> Signed-off-by: Oleksij Rempel <o.rempel@...gutronix.de>


[...]

> @@ -5158,7 +5137,7 @@ static int lan78xx_reset_resume(struct usb_interface *intf)
>  	if (ret < 0)
>  		return ret;
>  
> -	phy_start(dev->net->phydev);
> +	phylink_start(dev->phylink);

You need RTNL to be held when calling this function.

I'm not familiar with USB but from what I get, this function is part of
the resume path (resume by resetting). I think you also need to
address the suspend path, it still has calls to
netif_carrier_off(dev->net), and you may need to use
phylink_suspend() / phylink_resume() ? (not sure)

Maxime

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ