phy_fixed.h 684 B

1234567891011121314151617181920212223242526272829303132
  1. #ifndef __PHY_FIXED_H
  2. #define __PHY_FIXED_H
  3. struct fixed_phy_status {
  4. int link;
  5. int speed;
  6. int duplex;
  7. int pause;
  8. int asym_pause;
  9. };
  10. #ifdef CONFIG_FIXED_PHY
  11. extern int fixed_phy_add(unsigned int irq, int phy_id,
  12. struct fixed_phy_status *status);
  13. #else
  14. static inline int fixed_phy_add(unsigned int irq, int phy_id,
  15. struct fixed_phy_status *status)
  16. {
  17. return -ENODEV;
  18. }
  19. #endif /* CONFIG_FIXED_PHY */
  20. /*
  21. * This function issued only by fixed_phy-aware drivers, no need
  22. * protect it with #ifdef
  23. */
  24. extern int fixed_phy_set_link_update(struct phy_device *phydev,
  25. int (*link_update)(struct net_device *,
  26. struct fixed_phy_status *));
  27. #endif /* __PHY_FIXED_H */