summaryrefslogtreecommitdiff
path: root/drivers/net/tg3.h
diff options
context:
space:
mode:
authorMatt Carlson <mcarlson@broadcom.com>2007-12-21 07:08:32 +0300
committerDavid S. Miller <davem@davemloft.net>2008-01-29 01:59:32 +0300
commitc98f6e3be1d1b9bc9299d84da4f0b1ea9a50f392 (patch)
tree6b40c900dad3d38e755f1a5a37acea08f98d3b0d /drivers/net/tg3.h
parentba4d07a8483e6ec0de3194960f8aca862711454c (diff)
downloadlinux-c98f6e3be1d1b9bc9299d84da4f0b1ea9a50f392.tar.xz
[TG3]: Replace some magic 5704S constants
This patch replaces magic values with preprocessor definitions for the sg_dig_ctrl and sg_dig_status registers. This is preparatory work for the next patch. Signed-off-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tg3.h')
-rw-r--r--drivers/net/tg3.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h
index ac47c176fc03..3938eb35ce8c 100644
--- a/drivers/net/tg3.h
+++ b/drivers/net/tg3.h
@@ -545,6 +545,8 @@
#define SG_DIG_FIBER_MODE 0x00008000
#define SG_DIG_REMOTE_FAULT_MASK 0x00006000
#define SG_DIG_PAUSE_MASK 0x00001800
+#define SG_DIG_PAUSE_CAP 0x00000800
+#define SG_DIG_ASYM_PAUSE 0x00001000
#define SG_DIG_GBIC_ENABLE 0x00000400
#define SG_DIG_CHECK_END_ENABLE 0x00000200
#define SG_DIG_SGMII_AUTONEG_TIMER 0x00000100
@@ -556,6 +558,11 @@
#define SG_DIG_AUTONEG_LOW_ENABLE 0x00000004
#define SG_DIG_REMOTE_LOOPBACK 0x00000002
#define SG_DIG_LOOPBACK 0x00000001
+#define SG_DIG_COMMON_SETUP (SG_DIG_CRC16_CLEAR_N | \
+ SG_DIG_LOCAL_DUPLEX_STATUS | \
+ SG_DIG_LOCAL_LINK_STATUS | \
+ (0x2 << SG_DIG_SPEED_STATUS_SHIFT) | \
+ SG_DIG_FIBER_MODE | SG_DIG_GBIC_ENABLE)
#define SG_DIG_STATUS 0x000005b4
#define SG_DIG_CRC16_BUS_MASK 0xffff0000
#define SG_DIG_PARTNER_FAULT_MASK 0x00600000 /* If !MRADV_CRC16_SELECT */