am35x-phy-control.h 543 B

123456789101112131415161718192021
  1. #ifndef _AM335x_PHY_CONTROL_H_
  2. #define _AM335x_PHY_CONTROL_H_
  3. struct phy_control {
  4. void (*phy_power)(struct phy_control *phy_ctrl, u32 id, bool on);
  5. void (*phy_wkup)(struct phy_control *phy_ctrl, u32 id, bool on);
  6. };
  7. static inline void phy_ctrl_power(struct phy_control *phy_ctrl, u32 id, bool on)
  8. {
  9. phy_ctrl->phy_power(phy_ctrl, id, on);
  10. }
  11. static inline void phy_ctrl_wkup(struct phy_control *phy_ctrl, u32 id, bool on)
  12. {
  13. phy_ctrl->phy_wkup(phy_ctrl, id, on);
  14. }
  15. struct phy_control *am335x_get_phy_control(struct device *dev);
  16. #endif