david/ipxe
david
/
ipxe
Archived
1
0
Fork 0

[mii] Synchronise constants with current Linux include/linux/mii.h

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown 2012-04-18 15:42:55 +01:00
parent 2f3f0ca953
commit d27e6d6efd
2 changed files with 111 additions and 115 deletions

View File

@ -93,7 +93,6 @@ static int falcon_mdio_read ( struct efab_nic *efab, int device, int location );
#define LPA_EF_10000FULL 0x00040000
#define LPA_EF_10000HALF 0x00080000
#define LPA_100 (LPA_100FULL | LPA_100HALF | LPA_100BASE4)
#define LPA_EF_1000 ( LPA_EF_1000FULL | LPA_EF_1000HALF )
#define LPA_EF_10000 ( LPA_EF_10000FULL | LPA_EF_10000HALF )
#define LPA_EF_DUPLEX ( LPA_10FULL | LPA_100FULL | LPA_EF_1000FULL | \

View File

@ -1,22 +1,19 @@
/*
* linux/mii.h: definitions for MII-compatible transceivers
* Originally drivers/net/sunhme.h.
#ifndef _MII_H_
#define _MII_H_
/** @file
*
* Media Independent Interface constants
*
* Extracted from Linux's include/linux/mii.h
*
* Copyright (C) 1996, 1999, 2001 David S. Miller (davem@redhat.com)
*
* Copied Form Linux 2.4.25 an unneeded items removed by:
* Timothy Legge (timlegge at etherboot dot org)
*
* 03/26/2004
*/
FILE_LICENCE ( GPL2_ONLY );
#ifndef _MII_H_
#define _MII_H_
/* Generic MII registers. */
#define MII_BMCR 0x00 /* Basic mode control register */
#define MII_BMSR 0x01 /* Basic mode status register */
#define MII_PHYSID1 0x02 /* PHYS ID 1 */
@ -88,10 +85,10 @@ FILE_LICENCE ( GPL2_ONLY );
#define ADVERTISE_LPACK 0x4000 /* Ack link partners response */
#define ADVERTISE_NPAGE 0x8000 /* Next page bit */
#define ADVERTISE_FULL (ADVERTISE_100FULL | ADVERTISE_10FULL | \
#define ADVERTISE_FULL ( ADVERTISE_100FULL | ADVERTISE_10FULL | \
ADVERTISE_CSMA)
#define ADVERTISE_ALL (ADVERTISE_10HALF | ADVERTISE_10FULL | \
ADVERTISE_100HALF | ADVERTISE_100FULL)
#define ADVERTISE_ALL ( ADVERTISE_10HALF | ADVERTISE_10FULL | \
ADVERTISE_100HALF | ADVERTISE_100FULL )
/* Link partner ability register. */
#define LPA_SLCT 0x001f /* Same as advertise selector */
@ -111,8 +108,8 @@ FILE_LICENCE ( GPL2_ONLY );
#define LPA_LPACK 0x4000 /* Link partner acked us */
#define LPA_NPAGE 0x8000 /* Next page bit */
#define LPA_DUPLEX (LPA_10FULL | LPA_100FULL)
#define LPA_100 (LPA_100FULL | LPA_100HALF | LPA_100BASE4)
#define LPA_DUPLEX ( LPA_10FULL | LPA_100FULL )
#define LPA_100 ( LPA_100FULL | LPA_100HALF | LPA_100BASE4 )
/* Expansion register for auto-negotiation. */
#define EXPANSION_NWAY 0x0001 /* Can do N-way auto-nego */
@ -135,10 +132,10 @@ FILE_LICENCE ( GPL2_ONLY );
#define ADVERTISE_1000HALF 0x0100 /* Advertise 1000BASE-T half duplex */
/* 1000BASE-T Status register */
#define LPA_1000LOCALRXOK 0x2000 /* Link partner local receiver status */
#define LPA_1000REMRXOK 0x1000 /* Link partner remote receiver status */
#define LPA_1000FULL 0x0800 /* Link partner 1000BASE-T full duplex */
#define LPA_1000HALF 0x0400 /* Link partner 1000BASE-T half duplex */
#define LPA_1000LOCALRXOK 0x2000 /* Partner local receiver status */
#define LPA_1000REMRXOK 0x1000 /* Partner remote receiver status */
#define LPA_1000FULL 0x0800 /* Partner 1000BASE-T full duplex */
#define LPA_1000HALF 0x0400 /* Partner 1000BASE-T half duplex */
#include <ipxe/netdevice.h>