[PATCH v2 0/3] Add Rust Rockchip PHY driver

Christina Quast
2024-02-01T18:07:13Z

Based on the example shown in drivers/net/phy/ax88796b_rust.rs, I ported
the rockchip phy driver to Rust. The code in drivers/net/phy/rockchip.c
was basically rewritten in Rust. The patchset includes changes to
phy.rs, adding more struct driver functions for the abstraction with
Rust.

The driver was not tested on real hardware, because I do not have a
board with this phy, and I would appreciate it if somebody could try
out the driver on their board.

Signed-off-by: Christina Quast <contact@christina-quast.de>
---
Christina Quast (3):
DONOTMERGE: rust: prelude: add bit function
rust: phy: add some phy_driver and genphy_ functions
net: phy: add Rust Rockchip PHY driver

drivers/net/phy/Kconfig | 8 +++
drivers/net/phy/Makefile | 4 ++
drivers/net/phy/rockchip_rust.rs | 131 +++++++++++++++++++++++++++++++++++++++
rust/kernel/net/phy.rs | 31 +++++++++
rust/kernel/prelude.rs | 16 +++++
5 files changed, 190 insertions(+)
---
base-commit: 6613476e225e090cc9aad49be7fa504e290dd33d
change-id: 20240201-rockchip-rust-phy_depend-681db4707777

Best regards,
--
Christina Quast <contact@christina-quast.de>