diff options
-rw-r--r-- | drivers/net/tg3.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index 4c4d164a4b44..606703cf9618 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c | |||
@@ -6967,19 +6967,16 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
6967 | tw32(RCVDBDI_STD_BD + TG3_BDINFO_NIC_ADDR, | 6967 | tw32(RCVDBDI_STD_BD + TG3_BDINFO_NIC_ADDR, |
6968 | NIC_SRAM_RX_BUFFER_DESC); | 6968 | NIC_SRAM_RX_BUFFER_DESC); |
6969 | 6969 | ||
6970 | /* Don't even try to program the JUMBO/MINI buffer descriptor | 6970 | /* Disable the mini ring */ |
6971 | * configs on 5705. | 6971 | if (!(tp->tg3_flags2 & TG3_FLG2_5705_PLUS)) |
6972 | */ | ||
6973 | if (tp->tg3_flags2 & TG3_FLG2_5705_PLUS) { | ||
6974 | tw32(RCVDBDI_STD_BD + TG3_BDINFO_MAXLEN_FLAGS, | ||
6975 | RX_STD_MAX_SIZE_5705 << BDINFO_FLAGS_MAXLEN_SHIFT); | ||
6976 | } else { | ||
6977 | tw32(RCVDBDI_STD_BD + TG3_BDINFO_MAXLEN_FLAGS, | ||
6978 | RX_STD_MAX_SIZE << BDINFO_FLAGS_MAXLEN_SHIFT); | ||
6979 | |||
6980 | tw32(RCVDBDI_MINI_BD + TG3_BDINFO_MAXLEN_FLAGS, | 6972 | tw32(RCVDBDI_MINI_BD + TG3_BDINFO_MAXLEN_FLAGS, |
6981 | BDINFO_FLAGS_DISABLED); | 6973 | BDINFO_FLAGS_DISABLED); |
6982 | 6974 | ||
6975 | /* Program the jumbo buffer descriptor ring control | ||
6976 | * blocks on those devices that have them. | ||
6977 | */ | ||
6978 | if ((tp->tg3_flags2 & TG3_FLG2_JUMBO_CAPABLE) && | ||
6979 | !(tp->tg3_flags2 & TG3_FLG2_5780_CLASS)) { | ||
6983 | /* Setup replenish threshold. */ | 6980 | /* Setup replenish threshold. */ |
6984 | tw32(RCVBDI_JUMBO_THRESH, tp->rx_jumbo_pending / 8); | 6981 | tw32(RCVBDI_JUMBO_THRESH, tp->rx_jumbo_pending / 8); |
6985 | 6982 | ||
@@ -6997,7 +6994,11 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
6997 | BDINFO_FLAGS_DISABLED); | 6994 | BDINFO_FLAGS_DISABLED); |
6998 | } | 6995 | } |
6999 | 6996 | ||
7000 | } | 6997 | val = RX_STD_MAX_SIZE << BDINFO_FLAGS_MAXLEN_SHIFT; |
6998 | } else | ||
6999 | val = RX_STD_MAX_SIZE_5705 << BDINFO_FLAGS_MAXLEN_SHIFT; | ||
7000 | |||
7001 | tw32(RCVDBDI_STD_BD + TG3_BDINFO_MAXLEN_FLAGS, val); | ||
7001 | 7002 | ||
7002 | /* There is only one send ring on 5705/5750, no need to explicitly | 7003 | /* There is only one send ring on 5705/5750, no need to explicitly |
7003 | * disable the others. | 7004 | * disable the others. |