rust-for-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH v4 0/2] net::phy add unified API for C22 and C45 registers
@ 2024-06-07  5:21 FUJITA Tomonori
  2024-06-07  5:21 ` [RFC PATCH v4 1/2] rust: net::phy unified read/write " FUJITA Tomonori
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: FUJITA Tomonori @ 2024-06-07  5:21 UTC (permalink / raw)
  To: rust-for-linux; +Cc: andrew, tmgross, benno.lossin

add unified API for C22 and C45, reading/writing registers and
genphy_read_status().

We could add methods specifically C45 like read/write_c45 and
genphy_c45_read_status. Instead, this implements the unified API for
C22 and C45 with a new reg module.

v4:
- make reg module sealed
- improve the comments
- add examples
- use error::to_result() to simplify some functions
v3: https://lore.kernel.org/all/20240603.233954.1644803151268035787.fujita.tomonori@gmail.com/T/
- move reg module to a new file (with MAINTAINERS updated)
- rewrite commit log and subjects
- rename Access trait to Register
- add build error message for build_assert!
- define the complete MMD list
- drop new func for Mmd
- remove trait GenPhyOps
v2: https://lore.kernel.org/all/20240601043535.53545-2-fujita.tomonori@gmail.com/T/
- add genphy helper support and split the patch
- create a 'reg' module
- define C22 according to the specs
- handle C22 vendor specific registers
- add const for C45 MMD
v1: https://lore.kernel.org/all/20240530.145258.456915814420167538.fujita.tomonori@gmail.com/T/

FUJITA Tomonori (2):
  rust: net::phy unified read/write API for C22 and C45 registers
  rust: net::phy unified genphy_read_status function for C22 and C45
    registers

 MAINTAINERS                      |   1 +
 drivers/net/phy/ax88796b_rust.rs |   7 +-
 rust/kernel/net/phy.rs           |  44 ++-----
 rust/kernel/net/phy/reg.rs       | 219 +++++++++++++++++++++++++++++++
 rust/uapi/uapi_helper.h          |   1 +
 5 files changed, 234 insertions(+), 38 deletions(-)
 create mode 100644 rust/kernel/net/phy/reg.rs


base-commit: c790275b5edf5d8280ae520bda7c1f37da460c00
-- 
2.34.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-06-15  7:40 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-07  5:21 [RFC PATCH v4 0/2] net::phy add unified API for C22 and C45 registers FUJITA Tomonori
2024-06-07  5:21 ` [RFC PATCH v4 1/2] rust: net::phy unified read/write " FUJITA Tomonori
2024-06-13 17:59   ` Trevor Gross
2024-06-13 23:32     ` FUJITA Tomonori
2024-06-14  8:30       ` Benno Lossin
2024-06-14  9:57         ` FUJITA Tomonori
2024-06-07  5:21 ` [RFC PATCH v4 2/2] rust: net::phy unified genphy_read_status function " FUJITA Tomonori
2024-06-13 18:00   ` Trevor Gross
2024-06-14 12:53 ` [RFC PATCH v4 0/2] net::phy add unified API " Benno Lossin
2024-06-15  7:39   ` FUJITA Tomonori

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).