diff options
Diffstat (limited to 'drivers/net/tg3.h')
-rw-r--r-- | drivers/net/tg3.h | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/drivers/net/tg3.h b/drivers/net/tg3.h index 574a1cc4d353..ce9c4918c318 100644 --- a/drivers/net/tg3.h +++ b/drivers/net/tg3.h | |||
@@ -23,11 +23,8 @@ | |||
23 | #define TG3_BDINFO_NIC_ADDR 0xcUL /* 32-bit */ | 23 | #define TG3_BDINFO_NIC_ADDR 0xcUL /* 32-bit */ |
24 | #define TG3_BDINFO_SIZE 0x10UL | 24 | #define TG3_BDINFO_SIZE 0x10UL |
25 | 25 | ||
26 | #define RX_COPY_THRESHOLD 256 | ||
27 | |||
28 | #define TG3_RX_INTERNAL_RING_SZ_5906 32 | 26 | #define TG3_RX_INTERNAL_RING_SZ_5906 32 |
29 | 27 | ||
30 | #define RX_STD_MAX_SIZE 1536 | ||
31 | #define RX_STD_MAX_SIZE_5705 512 | 28 | #define RX_STD_MAX_SIZE_5705 512 |
32 | #define RX_JUMBO_MAX_SIZE 0xdeadbeef /* XXX */ | 29 | #define RX_JUMBO_MAX_SIZE 0xdeadbeef /* XXX */ |
33 | 30 | ||
@@ -183,6 +180,7 @@ | |||
183 | #define METAL_REV_B2 0x02 | 180 | #define METAL_REV_B2 0x02 |
184 | #define TG3PCI_DMA_RW_CTRL 0x0000006c | 181 | #define TG3PCI_DMA_RW_CTRL 0x0000006c |
185 | #define DMA_RWCTRL_DIS_CACHE_ALIGNMENT 0x00000001 | 182 | #define DMA_RWCTRL_DIS_CACHE_ALIGNMENT 0x00000001 |
183 | #define DMA_RWCTRL_CRDRDR_RDMA_MRRS_MSK 0x00000380 | ||
186 | #define DMA_RWCTRL_READ_BNDRY_MASK 0x00000700 | 184 | #define DMA_RWCTRL_READ_BNDRY_MASK 0x00000700 |
187 | #define DMA_RWCTRL_READ_BNDRY_DISAB 0x00000000 | 185 | #define DMA_RWCTRL_READ_BNDRY_DISAB 0x00000000 |
188 | #define DMA_RWCTRL_READ_BNDRY_16 0x00000100 | 186 | #define DMA_RWCTRL_READ_BNDRY_16 0x00000100 |
@@ -252,7 +250,7 @@ | |||
252 | /* 0x94 --> 0x98 unused */ | 250 | /* 0x94 --> 0x98 unused */ |
253 | #define TG3PCI_STD_RING_PROD_IDX 0x00000098 /* 64-bit */ | 251 | #define TG3PCI_STD_RING_PROD_IDX 0x00000098 /* 64-bit */ |
254 | #define TG3PCI_RCV_RET_RING_CON_IDX 0x000000a0 /* 64-bit */ | 252 | #define TG3PCI_RCV_RET_RING_CON_IDX 0x000000a0 /* 64-bit */ |
255 | /* 0xa0 --> 0xb8 unused */ | 253 | /* 0xa8 --> 0xb8 unused */ |
256 | #define TG3PCI_DUAL_MAC_CTRL 0x000000b8 | 254 | #define TG3PCI_DUAL_MAC_CTRL 0x000000b8 |
257 | #define DUAL_MAC_CTRL_CH_MASK 0x00000003 | 255 | #define DUAL_MAC_CTRL_CH_MASK 0x00000003 |
258 | #define DUAL_MAC_CTRL_ID 0x00000004 | 256 | #define DUAL_MAC_CTRL_ID 0x00000004 |
@@ -1854,6 +1852,8 @@ | |||
1854 | #define TG3_PCIE_TLDLPL_PORT 0x00007c00 | 1852 | #define TG3_PCIE_TLDLPL_PORT 0x00007c00 |
1855 | #define TG3_PCIE_PL_LO_PHYCTL1 0x00000004 | 1853 | #define TG3_PCIE_PL_LO_PHYCTL1 0x00000004 |
1856 | #define TG3_PCIE_PL_LO_PHYCTL1_L1PLLPD_EN 0x00001000 | 1854 | #define TG3_PCIE_PL_LO_PHYCTL1_L1PLLPD_EN 0x00001000 |
1855 | #define TG3_PCIE_PL_LO_PHYCTL5 0x00000014 | ||
1856 | #define TG3_PCIE_PL_LO_PHYCTL5_DIS_L2CLKREQ 0x80000000 | ||
1857 | 1857 | ||
1858 | /* OTP bit definitions */ | 1858 | /* OTP bit definitions */ |
1859 | #define TG3_OTP_AGCTGT_MASK 0x000000e0 | 1859 | #define TG3_OTP_AGCTGT_MASK 0x000000e0 |
@@ -2082,7 +2082,7 @@ | |||
2082 | #define MII_TG3_DSP_AADJ1CH0 0x001f | 2082 | #define MII_TG3_DSP_AADJ1CH0 0x001f |
2083 | #define MII_TG3_DSP_AADJ1CH3 0x601f | 2083 | #define MII_TG3_DSP_AADJ1CH3 0x601f |
2084 | #define MII_TG3_DSP_AADJ1CH3_ADCCKADJ 0x0002 | 2084 | #define MII_TG3_DSP_AADJ1CH3_ADCCKADJ 0x0002 |
2085 | #define MII_TG3_DSP_EXP8 0x0708 | 2085 | #define MII_TG3_DSP_EXP8 0x0f08 |
2086 | #define MII_TG3_DSP_EXP8_REJ2MHz 0x0001 | 2086 | #define MII_TG3_DSP_EXP8_REJ2MHz 0x0001 |
2087 | #define MII_TG3_DSP_EXP8_AEDW 0x0200 | 2087 | #define MII_TG3_DSP_EXP8_AEDW 0x0200 |
2088 | #define MII_TG3_DSP_EXP75 0x0f75 | 2088 | #define MII_TG3_DSP_EXP75 0x0f75 |
@@ -2512,7 +2512,7 @@ struct tg3_hw_stats { | |||
2512 | */ | 2512 | */ |
2513 | struct ring_info { | 2513 | struct ring_info { |
2514 | struct sk_buff *skb; | 2514 | struct sk_buff *skb; |
2515 | DECLARE_PCI_UNMAP_ADDR(mapping) | 2515 | DEFINE_DMA_UNMAP_ADDR(mapping); |
2516 | }; | 2516 | }; |
2517 | 2517 | ||
2518 | struct tg3_config_info { | 2518 | struct tg3_config_info { |
@@ -2561,7 +2561,7 @@ struct tg3_bufmgr_config { | |||
2561 | 2561 | ||
2562 | struct tg3_ethtool_stats { | 2562 | struct tg3_ethtool_stats { |
2563 | /* Statistics maintained by Receive MAC. */ | 2563 | /* Statistics maintained by Receive MAC. */ |
2564 | u64 rx_octets; | 2564 | u64 rx_octets; |
2565 | u64 rx_fragments; | 2565 | u64 rx_fragments; |
2566 | u64 rx_ucast_packets; | 2566 | u64 rx_ucast_packets; |
2567 | u64 rx_mcast_packets; | 2567 | u64 rx_mcast_packets; |
@@ -2751,9 +2751,11 @@ struct tg3 { | |||
2751 | struct tg3_napi napi[TG3_IRQ_MAX_VECS]; | 2751 | struct tg3_napi napi[TG3_IRQ_MAX_VECS]; |
2752 | void (*write32_rx_mbox) (struct tg3 *, u32, | 2752 | void (*write32_rx_mbox) (struct tg3 *, u32, |
2753 | u32); | 2753 | u32); |
2754 | u32 rx_copy_thresh; | ||
2754 | u32 rx_pending; | 2755 | u32 rx_pending; |
2755 | u32 rx_jumbo_pending; | 2756 | u32 rx_jumbo_pending; |
2756 | u32 rx_std_max_post; | 2757 | u32 rx_std_max_post; |
2758 | u32 rx_offset; | ||
2757 | u32 rx_pkt_map_sz; | 2759 | u32 rx_pkt_map_sz; |
2758 | #if TG3_VLAN_TAG_USED | 2760 | #if TG3_VLAN_TAG_USED |
2759 | struct vlan_group *vlgrp; | 2761 | struct vlan_group *vlgrp; |
@@ -2773,7 +2775,6 @@ struct tg3 { | |||
2773 | unsigned long last_event_jiffies; | 2775 | unsigned long last_event_jiffies; |
2774 | }; | 2776 | }; |
2775 | 2777 | ||
2776 | u32 rx_offset; | ||
2777 | u32 tg3_flags; | 2778 | u32 tg3_flags; |
2778 | #define TG3_FLAG_TAGGED_STATUS 0x00000001 | 2779 | #define TG3_FLAG_TAGGED_STATUS 0x00000001 |
2779 | #define TG3_FLAG_TXD_MBOX_HWBUG 0x00000002 | 2780 | #define TG3_FLAG_TXD_MBOX_HWBUG 0x00000002 |