forked from M-Labs/zynq-rs
phy: fix issue 78, scan PHY MDIO addr starting at 0
This commit is contained in:
parent
03122f810a
commit
a42e5a95ff
|
@ -51,7 +51,7 @@ mod phy_impl {
|
||||||
impl Phy {
|
impl Phy {
|
||||||
/// Probe all addresses on MDIO for a known PHY
|
/// Probe all addresses on MDIO for a known PHY
|
||||||
pub fn find<PA: PhyAccess>(pa: &mut PA) -> Option<Phy> {
|
pub fn find<PA: PhyAccess>(pa: &mut PA) -> Option<Phy> {
|
||||||
(1..32).find(|addr| {
|
(0..32).find(|addr| {
|
||||||
match identify_phy(pa, *addr) {
|
match identify_phy(pa, *addr) {
|
||||||
Some(PhyIdentifier {
|
Some(PhyIdentifier {
|
||||||
oui: OUI_MARVELL,
|
oui: OUI_MARVELL,
|
||||||
|
|
Loading…
Reference in New Issue