diff options
author | Daniel Verkamp | 2008-12-10 08:11:50 +0100 |
---|---|---|
committer | Michael Brown | 2009-05-26 12:27:55 +0200 |
commit | 005fce0258b318b8b95a5891b4aedf437d843dec (patch) | |
tree | 130c3437706899553ad63d1e524d2df04e17a998 /src/include | |
parent | [settings] Allow for arbitrarily-named settings (diff) | |
download | ipxe-005fce0258b318b8b95a5891b4aedf437d843dec.tar.gz ipxe-005fce0258b318b8b95a5891b4aedf437d843dec.tar.xz ipxe-005fce0258b318b8b95a5891b4aedf437d843dec.zip |
[ethernet] Move struct mii_if_info to mii.h
Signed-off-by: Michael Brown <mcb30@etherboot.org>
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/mii.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/include/mii.h b/src/include/mii.h index e17ec63b..27a0b639 100644 --- a/src/include/mii.h +++ b/src/include/mii.h @@ -12,6 +12,9 @@ FILE_LICENCE ( GPL2_ONLY ); +#ifndef _MII_H_ +#define _MII_H_ + /* Generic MII registers. */ #define MII_BMCR 0x00 /* Basic mode control register */ @@ -105,3 +108,21 @@ FILE_LICENCE ( GPL2_ONLY ); #define NWAYTEST_LOOPBACK 0x0100 /* Enable loopback for N-way */ #define NWAYTEST_RESV2 0xfe00 /* Unused... */ +#include <gpxe/netdevice.h> + +struct mii_if_info { + int phy_id; + int advertising; + int phy_id_mask; + int reg_num_mask; + + unsigned int full_duplex : 1; /* is full duplex? */ + unsigned int force_media : 1; /* is autoneg. disabled? */ + unsigned int supports_gmii : 1; /* are GMII registers supported? */ + + struct net_device *dev; + int (*mdio_read) (struct net_device *dev, int phy_id, int location); + void (*mdio_write) (struct net_device *dev, int phy_id, int location, int val); +}; + +#endif |