diff options
author | Matt Carlson <mcarlson@broadcom.com> | 2008-05-26 02:48:31 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-05-29 04:38:33 -0400 |
commit | 57e6983cbde91b4569b4014b933f3a16e12b99fd (patch) | |
tree | d5f06b5b0afcb465ebf60ee3c6b84413f4ded4ad /drivers | |
parent | b02fd9e3ac118037549baeb86fbe0718561db17f (diff) |
tg3: Add 5785 ASIC revision
This patch added the 5785 device ID and ASIC revision to the code.
Signed-off-by: Matt Carlson <mcarlson@broadcom.com>
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Benjamin Li <benli@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/tg3.c | 58 | ||||
-rw-r--r-- | drivers/net/tg3.h | 1 |
2 files changed, 44 insertions, 15 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index 028276edd3bc..69ded90cd96e 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c | |||
@@ -204,6 +204,7 @@ static struct pci_device_id tg3_pci_tbl[] = { | |||
204 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5723)}, | 204 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5723)}, |
205 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5761)}, | 205 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5761)}, |
206 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5761E)}, | 206 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5761E)}, |
207 | {PCI_DEVICE(PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_TIGON3_5785)}, | ||
207 | {PCI_DEVICE(PCI_VENDOR_ID_SYSKONNECT, PCI_DEVICE_ID_SYSKONNECT_9DXX)}, | 208 | {PCI_DEVICE(PCI_VENDOR_ID_SYSKONNECT, PCI_DEVICE_ID_SYSKONNECT_9DXX)}, |
208 | {PCI_DEVICE(PCI_VENDOR_ID_SYSKONNECT, PCI_DEVICE_ID_SYSKONNECT_9MXX)}, | 209 | {PCI_DEVICE(PCI_VENDOR_ID_SYSKONNECT, PCI_DEVICE_ID_SYSKONNECT_9MXX)}, |
209 | {PCI_DEVICE(PCI_VENDOR_ID_ALTIMA, PCI_DEVICE_ID_ALTIMA_AC1000)}, | 210 | {PCI_DEVICE(PCI_VENDOR_ID_ALTIMA, PCI_DEVICE_ID_ALTIMA_AC1000)}, |
@@ -5710,7 +5711,8 @@ static int tg3_chip_reset(struct tg3 *tp) | |||
5710 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || | 5711 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || |
5711 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 5712 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
5712 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 5713 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
5713 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 5714 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
5715 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
5714 | tw32(GRC_FASTBOOT_PC, 0); | 5716 | tw32(GRC_FASTBOOT_PC, 0); |
5715 | 5717 | ||
5716 | /* | 5718 | /* |
@@ -7004,7 +7006,8 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
7004 | return err; | 7006 | return err; |
7005 | 7007 | ||
7006 | if (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5784 && | 7008 | if (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5784 && |
7007 | GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5761) { | 7009 | GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5761 && |
7010 | GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5785) { | ||
7008 | /* This value is determined during the probe time DMA | 7011 | /* This value is determined during the probe time DMA |
7009 | * engine test, tg3_test_dma. | 7012 | * engine test, tg3_test_dma. |
7010 | */ | 7013 | */ |
@@ -7243,7 +7246,8 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
7243 | RDMAC_MODE_FIFOURUN_ENAB | RDMAC_MODE_FIFOOREAD_ENAB | | 7246 | RDMAC_MODE_FIFOURUN_ENAB | RDMAC_MODE_FIFOOREAD_ENAB | |
7244 | RDMAC_MODE_LNGREAD_ENAB); | 7247 | RDMAC_MODE_LNGREAD_ENAB); |
7245 | 7248 | ||
7246 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784) | 7249 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
7250 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
7247 | rdmac_mode |= RDMAC_MODE_BD_SBD_CRPT_ENAB | | 7251 | rdmac_mode |= RDMAC_MODE_BD_SBD_CRPT_ENAB | |
7248 | RDMAC_MODE_MBUF_RBD_CRPT_ENAB | | 7252 | RDMAC_MODE_MBUF_RBD_CRPT_ENAB | |
7249 | RDMAC_MODE_MBUF_SBD_CRPT_ENAB; | 7253 | RDMAC_MODE_MBUF_SBD_CRPT_ENAB; |
@@ -7411,7 +7415,8 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
7411 | if ((GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755) || | 7415 | if ((GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755) || |
7412 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787) || | 7416 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787) || |
7413 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784) || | 7417 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784) || |
7414 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761)) | 7418 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) || |
7419 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785)) | ||
7415 | val |= WDMAC_MODE_STATUS_TAG_FIX; | 7420 | val |= WDMAC_MODE_STATUS_TAG_FIX; |
7416 | 7421 | ||
7417 | tw32_f(WDMAC_MODE, val); | 7422 | tw32_f(WDMAC_MODE, val); |
@@ -7473,7 +7478,9 @@ static int tg3_reset_hw(struct tg3 *tp, int reset_phy) | |||
7473 | 7478 | ||
7474 | tp->rx_mode = RX_MODE_ENABLE; | 7479 | tp->rx_mode = RX_MODE_ENABLE; |
7475 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || | 7480 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || |
7476 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 7481 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
7482 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || | ||
7483 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
7477 | tp->rx_mode |= RX_MODE_IPV6_CSUM_ENABLE; | 7484 | tp->rx_mode |= RX_MODE_IPV6_CSUM_ENABLE; |
7478 | 7485 | ||
7479 | tw32_f(MAC_RX_MODE, tp->rx_mode); | 7486 | tw32_f(MAC_RX_MODE, tp->rx_mode); |
@@ -9028,7 +9035,10 @@ static int tg3_set_tso(struct net_device *dev, u32 value) | |||
9028 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5906)) { | 9035 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5906)) { |
9029 | if (value) { | 9036 | if (value) { |
9030 | dev->features |= NETIF_F_TSO6; | 9037 | dev->features |= NETIF_F_TSO6; |
9031 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 9038 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
9039 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 && | ||
9040 | GET_CHIP_REV(tp->pci_chip_rev_id) != CHIPREV_5784_AX) || | ||
9041 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
9032 | dev->features |= NETIF_F_TSO_ECN; | 9042 | dev->features |= NETIF_F_TSO_ECN; |
9033 | } else | 9043 | } else |
9034 | dev->features &= ~(NETIF_F_TSO6 | NETIF_F_TSO_ECN); | 9044 | dev->features &= ~(NETIF_F_TSO6 | NETIF_F_TSO_ECN); |
@@ -9286,7 +9296,8 @@ static int tg3_set_tx_csum(struct net_device *dev, u32 data) | |||
9286 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || | 9296 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || |
9287 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 9297 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
9288 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 9298 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
9289 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 9299 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
9300 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
9290 | ethtool_op_set_tx_ipv6_csum(dev, data); | 9301 | ethtool_op_set_tx_ipv6_csum(dev, data); |
9291 | else | 9302 | else |
9292 | ethtool_op_set_tx_csum(dev, data); | 9303 | ethtool_op_set_tx_csum(dev, data); |
@@ -9807,7 +9818,8 @@ static int tg3_test_memory(struct tg3 *tp) | |||
9807 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || | 9818 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || |
9808 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 9819 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
9809 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 9820 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
9810 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 9821 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
9822 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
9811 | mem_tbl = mem_tbl_5755; | 9823 | mem_tbl = mem_tbl_5755; |
9812 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) | 9824 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) |
9813 | mem_tbl = mem_tbl_5906; | 9825 | mem_tbl = mem_tbl_5906; |
@@ -10014,7 +10026,8 @@ static int tg3_test_loopback(struct tg3 *tp) | |||
10014 | return TG3_LOOPBACK_FAILED; | 10026 | return TG3_LOOPBACK_FAILED; |
10015 | 10027 | ||
10016 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 10028 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
10017 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) { | 10029 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
10030 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) { | ||
10018 | int i; | 10031 | int i; |
10019 | u32 status; | 10032 | u32 status; |
10020 | 10033 | ||
@@ -10042,7 +10055,8 @@ static int tg3_test_loopback(struct tg3 *tp) | |||
10042 | err |= TG3_MAC_LOOPBACK_FAILED; | 10055 | err |= TG3_MAC_LOOPBACK_FAILED; |
10043 | 10056 | ||
10044 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 10057 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
10045 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) { | 10058 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
10059 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) { | ||
10046 | tw32(TG3_CPMU_CTRL, cpmuctrl); | 10060 | tw32(TG3_CPMU_CTRL, cpmuctrl); |
10047 | 10061 | ||
10048 | /* Release the mutex */ | 10062 | /* Release the mutex */ |
@@ -10690,7 +10704,8 @@ static void __devinit tg3_nvram_init(struct tg3 *tp) | |||
10690 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755) | 10704 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755) |
10691 | tg3_get_5755_nvram_info(tp); | 10705 | tg3_get_5755_nvram_info(tp); |
10692 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 10706 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
10693 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784) | 10707 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
10708 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
10694 | tg3_get_5787_nvram_info(tp); | 10709 | tg3_get_5787_nvram_info(tp); |
10695 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 10710 | else if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) |
10696 | tg3_get_5761_nvram_info(tp); | 10711 | tg3_get_5761_nvram_info(tp); |
@@ -11021,6 +11036,7 @@ static int tg3_nvram_write_block_buffered(struct tg3 *tp, u32 offset, u32 len, | |||
11021 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5787) && | 11036 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5787) && |
11022 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5784) && | 11037 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5784) && |
11023 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5761) && | 11038 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5761) && |
11039 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5785) && | ||
11024 | (tp->nvram_jedecnum == JEDEC_ST) && | 11040 | (tp->nvram_jedecnum == JEDEC_ST) && |
11025 | (nvram_cmd & NVRAM_CMD_FIRST)) { | 11041 | (nvram_cmd & NVRAM_CMD_FIRST)) { |
11026 | 11042 | ||
@@ -11924,6 +11940,7 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
11924 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 11940 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
11925 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 11941 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
11926 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || | 11942 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
11943 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785 || | ||
11927 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906 || | 11944 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906 || |
11928 | (tp->tg3_flags2 & TG3_FLG2_5780_CLASS)) | 11945 | (tp->tg3_flags2 & TG3_FLG2_5780_CLASS)) |
11929 | tp->tg3_flags2 |= TG3_FLG2_5750_PLUS; | 11946 | tp->tg3_flags2 |= TG3_FLG2_5750_PLUS; |
@@ -11945,6 +11962,7 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
11945 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 11962 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
11946 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 11963 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
11947 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || | 11964 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
11965 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785 || | ||
11948 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) { | 11966 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) { |
11949 | tp->tg3_flags2 |= TG3_FLG2_HW_TSO_2; | 11967 | tp->tg3_flags2 |= TG3_FLG2_HW_TSO_2; |
11950 | tp->tg3_flags2 |= TG3_FLG2_1SHOT_MSI; | 11968 | tp->tg3_flags2 |= TG3_FLG2_1SHOT_MSI; |
@@ -12147,7 +12165,8 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
12147 | } | 12165 | } |
12148 | 12166 | ||
12149 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 12167 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
12150 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) { | 12168 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
12169 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) { | ||
12151 | tp->tg3_flags |= TG3_FLAG_CPMU_PRESENT; | 12170 | tp->tg3_flags |= TG3_FLAG_CPMU_PRESENT; |
12152 | 12171 | ||
12153 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0 || | 12172 | if (tp->pci_chip_rev_id == CHIPREV_ID_5784_A0 || |
@@ -12231,7 +12250,8 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
12231 | tp->tg3_flags2 |= TG3_FLG2_PHY_JITTER_BUG; | 12250 | tp->tg3_flags2 |= TG3_FLG2_PHY_JITTER_BUG; |
12232 | if (tp->pdev->device == PCI_DEVICE_ID_TIGON3_5755M) | 12251 | if (tp->pdev->device == PCI_DEVICE_ID_TIGON3_5755M) |
12233 | tp->tg3_flags2 |= TG3_FLG2_PHY_ADJUST_TRIM; | 12252 | tp->tg3_flags2 |= TG3_FLG2_PHY_ADJUST_TRIM; |
12234 | } else if (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5906) | 12253 | } else if (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5906 && |
12254 | GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5785) | ||
12235 | tp->tg3_flags2 |= TG3_FLG2_PHY_BER_BUG; | 12255 | tp->tg3_flags2 |= TG3_FLG2_PHY_BER_BUG; |
12236 | } | 12256 | } |
12237 | 12257 | ||
@@ -12252,6 +12272,9 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
12252 | GET_CHIP_REV(tp->pci_chip_rev_id) != CHIPREV_5700_BX) | 12272 | GET_CHIP_REV(tp->pci_chip_rev_id) != CHIPREV_5700_BX) |
12253 | tp->coalesce_mode |= HOSTCC_MODE_32BYTE; | 12273 | tp->coalesce_mode |= HOSTCC_MODE_32BYTE; |
12254 | 12274 | ||
12275 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
12276 | tp->tg3_flags3 |= TG3_FLG3_USE_PHYLIB; | ||
12277 | |||
12255 | err = tg3_mdio_init(tp); | 12278 | err = tg3_mdio_init(tp); |
12256 | if (err) | 12279 | if (err) |
12257 | return err; | 12280 | return err; |
@@ -12383,6 +12406,7 @@ static int __devinit tg3_get_invariants(struct tg3 *tp) | |||
12383 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 12406 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
12384 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 12407 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
12385 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || | 12408 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
12409 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785 || | ||
12386 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) | 12410 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) |
12387 | tp->dev->hard_start_xmit = tg3_start_xmit; | 12411 | tp->dev->hard_start_xmit = tg3_start_xmit; |
12388 | else | 12412 | else |
@@ -13307,7 +13331,10 @@ static int __devinit tg3_init_one(struct pci_dev *pdev, | |||
13307 | if ((tp->tg3_flags2 & TG3_FLG2_HW_TSO_2) && | 13331 | if ((tp->tg3_flags2 & TG3_FLG2_HW_TSO_2) && |
13308 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5906)) | 13332 | (GET_ASIC_REV(tp->pci_chip_rev_id) != ASIC_REV_5906)) |
13309 | dev->features |= NETIF_F_TSO6; | 13333 | dev->features |= NETIF_F_TSO6; |
13310 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 13334 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
13335 | (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 && | ||
13336 | GET_CHIP_REV(tp->pci_chip_rev_id) != CHIPREV_5784_AX) || | ||
13337 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
13311 | dev->features |= NETIF_F_TSO_ECN; | 13338 | dev->features |= NETIF_F_TSO_ECN; |
13312 | } | 13339 | } |
13313 | 13340 | ||
@@ -13373,7 +13400,8 @@ static int __devinit tg3_init_one(struct pci_dev *pdev, | |||
13373 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || | 13400 | if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5755 || |
13374 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || | 13401 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5787 || |
13375 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || | 13402 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5784 || |
13376 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761) | 13403 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5761 || |
13404 | GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5785) | ||
13377 | dev->features |= NETIF_F_IPV6_CSUM; | 13405 | dev->features |= NETIF_F_IPV6_CSUM; |
13378 | 13406 | ||
13379 | tp->tg3_flags |= TG3_FLAG_RX_CHECKSUMS; | 13407 | tp->tg3_flags |= TG3_FLAG_RX_CHECKSUMS; |
diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h index 48f45c17f60d..95ac4c9590a1 100644 --- a/drivers/net/tg3.h +++ b/drivers/net/tg3.h | |||
@@ -128,6 +128,7 @@ | |||
128 | #define ASIC_REV_USE_PROD_ID_REG 0x0f | 128 | #define ASIC_REV_USE_PROD_ID_REG 0x0f |
129 | #define ASIC_REV_5784 0x5784 | 129 | #define ASIC_REV_5784 0x5784 |
130 | #define ASIC_REV_5761 0x5761 | 130 | #define ASIC_REV_5761 0x5761 |
131 | #define ASIC_REV_5785 0x5785 | ||
131 | #define GET_CHIP_REV(CHIP_REV_ID) ((CHIP_REV_ID) >> 8) | 132 | #define GET_CHIP_REV(CHIP_REV_ID) ((CHIP_REV_ID) >> 8) |
132 | #define CHIPREV_5700_AX 0x70 | 133 | #define CHIPREV_5700_AX 0x70 |
133 | #define CHIPREV_5700_BX 0x71 | 134 | #define CHIPREV_5700_BX 0x71 |