phy: fix issue 78, scan PHY MDIO addr starting at 0

This commit is contained in:
topquark12 2021-07-05 13:25:22 +08:00
parent 03122f810a
commit a42e5a95ff

View File

@ -51,7 +51,7 @@ mod phy_impl {
impl Phy {
/// Probe all addresses on MDIO for a known PHY
pub fn find<PA: PhyAccess>(pa: &mut PA) -> Option<Phy> {
(1..32).find(|addr| {
(0..32).find(|addr| {
match identify_phy(pa, *addr) {
Some(PhyIdentifier {
oui: OUI_MARVELL,