diff options
author | Michael Brown | 2012-04-18 16:29:48 +0200 |
---|---|---|
committer | Michael Brown | 2012-04-18 17:32:57 +0200 |
commit | 2f3f0ca9533db60fff932153ab71cfcf2036c5df (patch) | |
tree | 07c055e1016c5cbd5c314c7bbc445648a028990a /src/include/mii.h | |
parent | [util] Add utility to generate list of supported network cards (diff) | |
download | ipxe-2f3f0ca9533db60fff932153ab71cfcf2036c5df.tar.gz ipxe-2f3f0ca9533db60fff932153ab71cfcf2036c5df.tar.xz ipxe-2f3f0ca9533db60fff932153ab71cfcf2036c5df.zip |
[mii] Remove unused functionality
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include/mii.h')
-rw-r--r-- | src/include/mii.h | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/src/include/mii.h b/src/include/mii.h index 2baff2f1..b7dce13a 100644 --- a/src/include/mii.h +++ b/src/include/mii.h @@ -157,63 +157,4 @@ struct mii_if_info { void (*mdio_write) (struct net_device *dev, int phy_id, int location, int val); }; - -extern int mii_link_ok (struct mii_if_info *mii); -extern void mii_check_link (struct mii_if_info *mii); -extern unsigned int mii_check_media (struct mii_if_info *mii, - unsigned int ok_to_print, - unsigned int init_media); - - -/** - * mii_nway_result - * @negotiated: value of MII ANAR and'd with ANLPAR - * - * Given a set of MII abilities, check each bit and returns the - * currently supported media, in the priority order defined by - * IEEE 802.3u. We use LPA_xxx constants but note this is not the - * value of LPA solely, as described above. - * - * The one exception to IEEE 802.3u is that 100baseT4 is placed - * between 100T-full and 100T-half. If your phy does not support - * 100T4 this is fine. If your phy places 100T4 elsewhere in the - * priority order, you will need to roll your own function. - */ -static inline unsigned int mii_nway_result (unsigned int negotiated) -{ - unsigned int ret; - - if (negotiated & LPA_100FULL) - ret = LPA_100FULL; - else if (negotiated & LPA_100BASE4) - ret = LPA_100BASE4; - else if (negotiated & LPA_100HALF) - ret = LPA_100HALF; - else if (negotiated & LPA_10FULL) - ret = LPA_10FULL; - else - ret = LPA_10HALF; - - return ret; -} - -/** - * mii_duplex - * @duplex_lock: Non-zero if duplex is locked at full - * @negotiated: value of MII ANAR and'd with ANLPAR - * - * A small helper function for a common case. Returns one - * if the media is operating or locked at full duplex, and - * returns zero otherwise. - */ -static inline unsigned int mii_duplex (unsigned int duplex_lock, - unsigned int negotiated) -{ - if (duplex_lock) - return 1; - if (mii_nway_result(negotiated) & LPA_DUPLEX) - return 1; - return 0; -} - #endif |