/* Operations supported by any kind of PHY */ struct mii_phy_ops
{ int (*init)(struct mii_phy *phy); int (*suspend)(struct mii_phy *phy); int (*setup_aneg)(struct mii_phy *phy, u32 advertise); int (*setup_forced)(struct mii_phy *phy, int speed, int fd); int (*poll_link)(struct mii_phy *phy); int (*read_link)(struct mii_phy *phy); int (*enable_fiber)(struct mii_phy *phy, int autoneg);
};
/* Structure used to statically define an mii/gii based PHY */ struct mii_phy_def
{
u32 phy_id; /* Concatenated ID1 << 16 | ID2 */
u32 phy_id_mask; /* Significant bits */
u32 features; /* Ethtool SUPPORTED_* defines */ int magic_aneg; /* Autoneg does all speed test for us */ constchar* name; conststruct mii_phy_ops* ops;
};
/* An instance of a PHY, partially borrowed from mii_if_info */ struct mii_phy
{ conststruct mii_phy_def *def;
u32 advertising; int mii_id;
/* 1: autoneg enabled, 0: disabled */ int autoneg;
/* forced speed & duplex (no autoneg) * partner speed & duplex & pause (autoneg)
*/ int speed; int duplex; int pause;
/* Provided by host chip */ struct net_device *dev; int (*mdio_read) (struct net_device *dev, int mii_id, int reg); void (*mdio_write) (struct net_device *dev, int mii_id, int reg, int val); void *platform_data;
};
/* Pass in a struct mii_phy with dev, mdio_read and mdio_write * filled, the remaining fields will be filled on return
*/ externint sungem_phy_probe(struct mii_phy *phy, int mii_id);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.