aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/e1000e/e1000.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/e1000e/e1000.h')
-rw-r--r--drivers/net/e1000e/e1000.h37
1 files changed, 19 insertions, 18 deletions
diff --git a/drivers/net/e1000e/e1000.h b/drivers/net/e1000e/e1000.h
index 327c0620da31..5a89dff52264 100644
--- a/drivers/net/e1000e/e1000.h
+++ b/drivers/net/e1000e/e1000.h
@@ -1,7 +1,7 @@
1/******************************************************************************* 1/*******************************************************************************
2 2
3 Intel PRO/1000 Linux driver 3 Intel PRO/1000 Linux driver
4 Copyright(c) 1999 - 2007 Intel Corporation. 4 Copyright(c) 1999 - 2008 Intel Corporation.
5 5
6 This program is free software; you can redistribute it and/or modify it 6 This program is free software; you can redistribute it and/or modify it
7 under the terms and conditions of the GNU General Public License, 7 under the terms and conditions of the GNU General Public License,
@@ -61,7 +61,7 @@ struct e1000_info;
61 ndev_printk(KERN_NOTICE , netdev, format, ## arg) 61 ndev_printk(KERN_NOTICE , netdev, format, ## arg)
62 62
63 63
64/* TX/RX descriptor defines */ 64/* Tx/Rx descriptor defines */
65#define E1000_DEFAULT_TXD 256 65#define E1000_DEFAULT_TXD 256
66#define E1000_MAX_TXD 4096 66#define E1000_MAX_TXD 4096
67#define E1000_MIN_TXD 80 67#define E1000_MIN_TXD 80
@@ -114,13 +114,13 @@ struct e1000_buffer {
114 dma_addr_t dma; 114 dma_addr_t dma;
115 struct sk_buff *skb; 115 struct sk_buff *skb;
116 union { 116 union {
117 /* TX */ 117 /* Tx */
118 struct { 118 struct {
119 unsigned long time_stamp; 119 unsigned long time_stamp;
120 u16 length; 120 u16 length;
121 u16 next_to_watch; 121 u16 next_to_watch;
122 }; 122 };
123 /* RX */ 123 /* Rx */
124 /* arrays of page information for packet split */ 124 /* arrays of page information for packet split */
125 struct e1000_ps_page *ps_pages; 125 struct e1000_ps_page *ps_pages;
126 }; 126 };
@@ -167,9 +167,6 @@ struct e1000_adapter {
167 167
168 spinlock_t tx_queue_lock; /* prevent concurrent tail updates */ 168 spinlock_t tx_queue_lock; /* prevent concurrent tail updates */
169 169
170 /* this is still needed for 82571 and above */
171 atomic_t irq_sem;
172
173 /* track device up/down/testing state */ 170 /* track device up/down/testing state */
174 unsigned long state; 171 unsigned long state;
175 172
@@ -180,7 +177,7 @@ struct e1000_adapter {
180 u16 rx_itr; 177 u16 rx_itr;
181 178
182 /* 179 /*
183 * TX 180 * Tx
184 */ 181 */
185 struct e1000_ring *tx_ring /* One per active queue */ 182 struct e1000_ring *tx_ring /* One per active queue */
186 ____cacheline_aligned_in_smp; 183 ____cacheline_aligned_in_smp;
@@ -202,7 +199,7 @@ struct e1000_adapter {
202 unsigned int total_rx_bytes; 199 unsigned int total_rx_bytes;
203 unsigned int total_rx_packets; 200 unsigned int total_rx_packets;
204 201
205 /* TX stats */ 202 /* Tx stats */
206 u64 tpt_old; 203 u64 tpt_old;
207 u64 colc_old; 204 u64 colc_old;
208 u64 gotcl_old; 205 u64 gotcl_old;
@@ -214,7 +211,7 @@ struct e1000_adapter {
214 u32 tx_dma_failed; 211 u32 tx_dma_failed;
215 212
216 /* 213 /*
217 * RX 214 * Rx
218 */ 215 */
219 bool (*clean_rx) (struct e1000_adapter *adapter, 216 bool (*clean_rx) (struct e1000_adapter *adapter,
220 int *work_done, int work_to_do) 217 int *work_done, int work_to_do)
@@ -226,7 +223,7 @@ struct e1000_adapter {
226 u32 rx_int_delay; 223 u32 rx_int_delay;
227 u32 rx_abs_int_delay; 224 u32 rx_abs_int_delay;
228 225
229 /* RX stats */ 226 /* Rx stats */
230 u64 hw_csum_err; 227 u64 hw_csum_err;
231 u64 hw_csum_good; 228 u64 hw_csum_good;
232 u64 rx_hdr_split; 229 u64 rx_hdr_split;
@@ -237,6 +234,8 @@ struct e1000_adapter {
237 234
238 unsigned int rx_ps_pages; 235 unsigned int rx_ps_pages;
239 u16 rx_ps_bsize0; 236 u16 rx_ps_bsize0;
237 u32 max_frame_size;
238 u32 min_frame_size;
240 239
241 /* OS defined structs */ 240 /* OS defined structs */
242 struct net_device *netdev; 241 struct net_device *netdev;
@@ -261,7 +260,7 @@ struct e1000_adapter {
261 u32 wol; 260 u32 wol;
262 u32 pba; 261 u32 pba;
263 262
264 u8 fc_autoneg; 263 bool fc_autoneg;
265 264
266 unsigned long led_status; 265 unsigned long led_status;
267 266
@@ -272,7 +271,7 @@ struct e1000_info {
272 enum e1000_mac_type mac; 271 enum e1000_mac_type mac;
273 unsigned int flags; 272 unsigned int flags;
274 u32 pba; 273 u32 pba;
275 s32 (*get_invariants)(struct e1000_adapter *); 274 s32 (*get_variants)(struct e1000_adapter *);
276 struct e1000_mac_operations *mac_ops; 275 struct e1000_mac_operations *mac_ops;
277 struct e1000_phy_operations *phy_ops; 276 struct e1000_phy_operations *phy_ops;
278 struct e1000_nvm_operations *nvm_ops; 277 struct e1000_nvm_operations *nvm_ops;
@@ -308,6 +307,7 @@ struct e1000_info {
308#define FLAG_MSI_ENABLED (1 << 27) 307#define FLAG_MSI_ENABLED (1 << 27)
309#define FLAG_RX_CSUM_ENABLED (1 << 28) 308#define FLAG_RX_CSUM_ENABLED (1 << 28)
310#define FLAG_TSO_FORCE (1 << 29) 309#define FLAG_TSO_FORCE (1 << 29)
310#define FLAG_RX_RESTART_NOW (1 << 30)
311 311
312#define E1000_RX_DESC_PS(R, i) \ 312#define E1000_RX_DESC_PS(R, i) \
313 (&(((union e1000_rx_desc_packet_split *)((R).desc))[i])) 313 (&(((union e1000_rx_desc_packet_split *)((R).desc))[i]))
@@ -357,7 +357,7 @@ extern struct e1000_info e1000_ich8_info;
357extern struct e1000_info e1000_ich9_info; 357extern struct e1000_info e1000_ich9_info;
358extern struct e1000_info e1000_es2_info; 358extern struct e1000_info e1000_es2_info;
359 359
360extern s32 e1000e_read_part_num(struct e1000_hw *hw, u32 *part_num); 360extern s32 e1000e_read_pba_num(struct e1000_hw *hw, u32 *pba_num);
361 361
362extern s32 e1000e_commit_phy(struct e1000_hw *hw); 362extern s32 e1000e_commit_phy(struct e1000_hw *hw);
363 363
@@ -390,9 +390,11 @@ extern s32 e1000e_copper_link_setup_igp(struct e1000_hw *hw);
390extern s32 e1000e_setup_link(struct e1000_hw *hw); 390extern s32 e1000e_setup_link(struct e1000_hw *hw);
391extern void e1000e_clear_vfta(struct e1000_hw *hw); 391extern void e1000e_clear_vfta(struct e1000_hw *hw);
392extern void e1000e_init_rx_addrs(struct e1000_hw *hw, u16 rar_count); 392extern void e1000e_init_rx_addrs(struct e1000_hw *hw, u16 rar_count);
393extern void e1000e_mc_addr_list_update_generic(struct e1000_hw *hw, 393extern void e1000e_update_mc_addr_list_generic(struct e1000_hw *hw,
394 u8 *mc_addr_list, u32 mc_addr_count, 394 u8 *mc_addr_list,
395 u32 rar_used_count, u32 rar_count); 395 u32 mc_addr_count,
396 u32 rar_used_count,
397 u32 rar_count);
396extern void e1000e_rar_set(struct e1000_hw *hw, u8 *addr, u32 index); 398extern void e1000e_rar_set(struct e1000_hw *hw, u8 *addr, u32 index);
397extern s32 e1000e_set_fc_watermarks(struct e1000_hw *hw); 399extern s32 e1000e_set_fc_watermarks(struct e1000_hw *hw);
398extern void e1000e_set_pcie_no_snoop(struct e1000_hw *hw, u32 no_snoop); 400extern void e1000e_set_pcie_no_snoop(struct e1000_hw *hw, u32 no_snoop);
@@ -462,7 +464,6 @@ extern s32 e1000e_acquire_nvm(struct e1000_hw *hw);
462extern s32 e1000e_write_nvm_spi(struct e1000_hw *hw, u16 offset, u16 words, u16 *data); 464extern s32 e1000e_write_nvm_spi(struct e1000_hw *hw, u16 offset, u16 words, u16 *data);
463extern s32 e1000e_update_nvm_checksum_generic(struct e1000_hw *hw); 465extern s32 e1000e_update_nvm_checksum_generic(struct e1000_hw *hw);
464extern s32 e1000e_poll_eerd_eewr_done(struct e1000_hw *hw, int ee_reg); 466extern s32 e1000e_poll_eerd_eewr_done(struct e1000_hw *hw, int ee_reg);
465extern s32 e1000e_read_nvm_spi(struct e1000_hw *hw, u16 offset, u16 words, u16 *data);
466extern s32 e1000e_read_nvm_eerd(struct e1000_hw *hw, u16 offset, u16 words, u16 *data); 467extern s32 e1000e_read_nvm_eerd(struct e1000_hw *hw, u16 offset, u16 words, u16 *data);
467extern s32 e1000e_validate_nvm_checksum_generic(struct e1000_hw *hw); 468extern s32 e1000e_validate_nvm_checksum_generic(struct e1000_hw *hw);
468extern void e1000e_release_nvm(struct e1000_hw *hw); 469extern void e1000e_release_nvm(struct e1000_hw *hw);