From 23c1627fc544efdd5182c2deb870a7038fc2e4c8 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Mon, 30 Aug 2004 01:42:09 -0700 Subject: [PATCH] [TG3]: Add 5750 A3 workaround. Signed-off-by: David S. Miller --- drivers/net/tg3.c | 7 +++++++ drivers/net/tg3.h | 1 + 2 files changed, 8 insertions(+) diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index bae37902fde97..69d19d2165092 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c @@ -3723,6 +3723,8 @@ static void tg3_write_sig_legacy(struct tg3 *tp, int kind) } } +static void tg3_stop_fw(struct tg3 *); + /* tp->lock is held. */ static int tg3_chip_reset(struct tg3 *tp) { @@ -3825,6 +3827,11 @@ static int tg3_chip_reset(struct tg3 *tp) tw32(MEMARB_MODE, MEMARB_MODE_ENABLE); + if (tp->pci_chip_rev_id == CHIPREV_ID_5750_A3) { + tg3_stop_fw(tp); + tw32(0x5000, 0x400); + } + tw32(GRC_MODE, tp->grc_mode); if (tp->pci_chip_rev_id == CHIPREV_ID_5705_A0) { diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h index 63ab0a62a6c4a..d46d04dc8f55a 100644 --- a/drivers/net/tg3.h +++ b/drivers/net/tg3.h @@ -124,6 +124,7 @@ #define CHIPREV_ID_5705_A3 0x3003 #define CHIPREV_ID_5750_A0 0x4000 #define CHIPREV_ID_5750_A1 0x4001 +#define CHIPREV_ID_5750_A3 0x4003 #define GET_ASIC_REV(CHIP_REV_ID) ((CHIP_REV_ID) >> 12) #define ASIC_REV_5700 0x07 #define ASIC_REV_5701 0x00 -- 2.53.0