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: <f6c7581d-7e4b-4114-bb57-8b009d66c5d2@lunn.ch>
Date: Mon, 10 Mar 2025 17:32:41 +0100
From: Andrew Lunn <andrew@...n.ch>
To: Chris Packham <Chris.Packham@...iedtelesis.co.nz>
Cc: Daniel Golle <daniel@...rotopia.org>,
	"hkallweit1@...il.com" <hkallweit1@...il.com>,
	"linux@...linux.org.uk" <linux@...linux.org.uk>,
	"davem@...emloft.net" <davem@...emloft.net>,
	"edumazet@...gle.com" <edumazet@...gle.com>,
	"kuba@...nel.org" <kuba@...nel.org>,
	"pabeni@...hat.com" <pabeni@...hat.com>,
	"sander@...nheule.net" <sander@...nheule.net>,
	"markus.stockhausen@....de" <markus.stockhausen@....de>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: [PATCH net-next v9] net: mdio: Add RTL9300 MDIO driver

> So far upstream Linux doesn't have generic paged PHY register functions. 

Yes it does:

phy_write_paged() and phy_read_paged().

These do all the locking to make sure they are atomic with respect to
other phy read/writes while the page is selected. The driver just
needs to provide two methods to read the current page and the set the
current page,

https://elixir.bootlin.com/linux/v6.13.6/source/include/linux/phy.h#L1060

	/** @read_page: Return the current PHY register page number */
	int (*read_page)(struct phy_device *dev);
	/** @write_page: Set the current PHY register page number */
	int (*write_page)(struct phy_device *dev, int page);

Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ