|
13 | 13 |
|
14 | 14 | #include "igc_hw.h"
|
15 | 15 |
|
16 |
| -/* main */ |
| 16 | +/* forward declaration */ |
| 17 | +void igc_set_ethtool_ops(struct net_device *); |
| 18 | + |
| 19 | +struct igc_adapter; |
| 20 | +struct igc_ring; |
| 21 | + |
| 22 | +void igc_up(struct igc_adapter *adapter); |
| 23 | +void igc_down(struct igc_adapter *adapter); |
| 24 | +int igc_setup_tx_resources(struct igc_ring *ring); |
| 25 | +int igc_setup_rx_resources(struct igc_ring *ring); |
| 26 | +void igc_free_tx_resources(struct igc_ring *ring); |
| 27 | +void igc_free_rx_resources(struct igc_ring *ring); |
| 28 | +unsigned int igc_get_max_rss_queues(struct igc_adapter *adapter); |
| 29 | +void igc_set_flag_queue_pairs(struct igc_adapter *adapter, |
| 30 | + const u32 max_rss_queues); |
| 31 | +int igc_reinit_queues(struct igc_adapter *adapter); |
| 32 | +bool igc_has_link(struct igc_adapter *adapter); |
| 33 | +void igc_reset(struct igc_adapter *adapter); |
| 34 | +int igc_set_spd_dplx(struct igc_adapter *adapter, u32 spd, u8 dplx); |
| 35 | + |
17 | 36 | extern char igc_driver_name[];
|
18 | 37 | extern char igc_driver_version[];
|
19 | 38 |
|
| 39 | +#define IGC_REGS_LEN 740 |
| 40 | +#define IGC_RETA_SIZE 128 |
| 41 | + |
20 | 42 | /* Interrupt defines */
|
21 | 43 | #define IGC_START_ITR 648 /* ~6000 ints/sec */
|
22 | 44 | #define IGC_FLAG_HAS_MSI BIT(0)
|
23 |
| -#define IGC_FLAG_QUEUE_PAIRS BIT(4) |
| 45 | +#define IGC_FLAG_QUEUE_PAIRS BIT(3) |
| 46 | +#define IGC_FLAG_DMAC BIT(4) |
24 | 47 | #define IGC_FLAG_NEED_LINK_UPDATE BIT(9)
|
25 | 48 | #define IGC_FLAG_MEDIA_RESET BIT(10)
|
26 | 49 | #define IGC_FLAG_MAS_ENABLE BIT(12)
|
27 | 50 | #define IGC_FLAG_HAS_MSIX BIT(13)
|
28 | 51 | #define IGC_FLAG_VLAN_PROMISC BIT(15)
|
| 52 | +#define IGC_FLAG_RX_LEGACY BIT(16) |
29 | 53 |
|
30 | 54 | #define IGC_START_ITR 648 /* ~6000 ints/sec */
|
31 | 55 | #define IGC_4K_ITR 980
|
@@ -60,6 +84,7 @@ extern char igc_driver_version[];
|
60 | 84 | #define IGC_RXBUFFER_2048 2048
|
61 | 85 | #define IGC_RXBUFFER_3072 3072
|
62 | 86 |
|
| 87 | +#define AUTO_ALL_MODES 0 |
63 | 88 | #define IGC_RX_HDR_LEN IGC_RXBUFFER_256
|
64 | 89 |
|
65 | 90 | /* RX and TX descriptor control thresholds.
|
@@ -340,6 +365,8 @@ struct igc_adapter {
|
340 | 365 |
|
341 | 366 | struct igc_mac_addr *mac_table;
|
342 | 367 |
|
| 368 | + u8 rss_indir_tbl[IGC_RETA_SIZE]; |
| 369 | + |
343 | 370 | unsigned long link_check_timeout;
|
344 | 371 | struct igc_info ei;
|
345 | 372 | };
|
@@ -418,6 +445,9 @@ static inline s32 igc_read_phy_reg(struct igc_hw *hw, u32 offset, u16 *data)
|
418 | 445 | return 0;
|
419 | 446 | }
|
420 | 447 |
|
| 448 | +/* forward declaration */ |
| 449 | +void igc_reinit_locked(struct igc_adapter *); |
| 450 | + |
421 | 451 | #define igc_rx_pg_size(_ring) (PAGE_SIZE << igc_rx_pg_order(_ring))
|
422 | 452 |
|
423 | 453 | #define IGC_TXD_DCMD (IGC_ADVTXD_DCMD_EOP | IGC_ADVTXD_DCMD_RS)
|
|
0 commit comments