OSDN Git Service

net: phy: motorcomm: Add pad drive strength cfg support
authorSamin Guo <samin.guo@starfivetech.com>
Thu, 20 Jul 2023 11:15:09 +0000 (19:15 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 24 Jul 2023 09:36:45 +0000 (10:36 +0100)
commit7a561e9351ae7e3fb1f08584d40b49c1e55dde60
tree13f64e5910a106d579b51cc74888a9e711499d8c
parent79e71d9569959b15ec7b150d0c43f993c2f6e32e
net: phy: motorcomm: Add pad drive strength cfg support

The motorcomm phy (YT8531) supports the ability to adjust the drive
strength of the rx_clk/rx_data, and the default strength may not be
suitable for all boards. So add configurable options to better match
the boards.(e.g. StarFive VisionFive 2)

When we configure the drive strength, we need to read the current
LDO voltage value to ensure that it is a legal value at that LDO
voltage.

Reviewed-by: Hal Feng <hal.feng@starfivetech.com>
Signed-off-by: Samin Guo <samin.guo@starfivetech.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/motorcomm.c