MDIO driver.
Data Fields | |
int32_t(* | isAlive )(uint32_t phyAddr, bool *isAlive, void *arg) |
Check if PHY is alive. More... | |
int32_t(* | isLinked )(uint32_t phyAddr, bool *isLinked, void *arg) |
Check if PHY is linked. More... | |
int32_t(* | readC22 )(uint32_t group, uint32_t phyAddr, uint32_t reg, uint16_t *val, void *arg) |
Read PHY register using Clause-22 frame. More... | |
int32_t(* | writeC22 )(uint32_t group, uint32_t phyAddr, uint32_t reg, uint16_t val, void *arg) |
Write PHY register using Clause-22 frame. More... | |
int32_t(* | readC45 )(uint32_t group, uint32_t phyAddr, uint8_t mmd, uint16_t reg, uint16_t *val, void *arg) |
Read PHY register using Clause-45 frame. More... | |
int32_t(* | writeC45 )(uint32_t group, uint32_t phyAddr, uint8_t mmd, uint16_t reg, uint16_t val, void *arg) |
Write PHY register using Clause-45 frame. More... | |
int32_t(* EnetPhy_Mdio::isAlive) (uint32_t phyAddr, bool *isAlive, void *arg) |
Check if PHY is alive.
Checks if PHY is alive, either using an explicit register read or any other mechanism supported by the MDIO peripheral (i.e. background BMSR reads).
phyAddr | PHY device address |
isAlive | Whether PHY is alive or not |
args | Caller's arguments passed to the PHY driver at open time |
int32_t(* EnetPhy_Mdio::isLinked) (uint32_t phyAddr, bool *isLinked, void *arg) |
Check if PHY is linked.
Checks if PHY is linked, either using an explicit register read or any other mechanism supported by the MDIO peripheral.
phyAddr | PHY device address |
isLinked | Whether PHY is linked or not |
args | Caller's arguments passed to the PHY driver at open time |
int32_t(* EnetPhy_Mdio::readC22) (uint32_t group, uint32_t phyAddr, uint32_t reg, uint16_t *val, void *arg) |
Read PHY register using Clause-22 frame.
Reads a PHY register using a Clause-22 frame.
group | User group (use 0 if single group is supported) |
phyAddr | PHY device address |
reg | Register address |
val | Value read from register |
args | Caller's arguments passed to the PHY driver at open time |
int32_t(* EnetPhy_Mdio::writeC22) (uint32_t group, uint32_t phyAddr, uint32_t reg, uint16_t val, void *arg) |
Write PHY register using Clause-22 frame.
Writes a PHY register using a Clause-22 frame.
group | User group (use 0 if single group is supported) |
phyAddr | PHY device address |
reg | Register address |
val | Value to be written |
args | Caller's arguments passed to the PHY driver at open time |
int32_t(* EnetPhy_Mdio::readC45) (uint32_t group, uint32_t phyAddr, uint8_t mmd, uint16_t reg, uint16_t *val, void *arg) |
Read PHY register using Clause-45 frame.
Reads a PHY register using a Clause-45 frame. Returns ENETPHY_ENOTSUPPORTED if MDIO doesn't support Clause-45 frames.
group | User group (use 0 if single group is supported) |
phyAddr | PHY device address |
reg | Register address |
val | Value read from register |
args | Caller's arguments passed to the PHY driver at open time |
int32_t(* EnetPhy_Mdio::writeC45) (uint32_t group, uint32_t phyAddr, uint8_t mmd, uint16_t reg, uint16_t val, void *arg) |
Write PHY register using Clause-45 frame.
Writes a PHY register using a Clause-45 frame. Returns ENETPHY_ENOTSUPPORTED if MDIO doesn't support Clause-45 frames.
group | User group (use 0 if single group is supported) |
phyAddr | PHY device address |
reg | Register address |
val | Value to be written |
args | Caller's arguments passed to the PHY driver at open time |