Commit 1ac12fc6 authored by Christopher Goldfarb's avatar Christopher Goldfarb Committed by Jeff Garzik

e1000 net drvr update 4/13:

Updated transmit path.  Breaks the transmit path up to make it 
more understandable.  Aggressively reclaim resources by checking
for completed transmits before queuing each new frame to avoid 
stalling the driver by delaying interrupts to long.
parent 28318676
......@@ -161,10 +161,6 @@ struct e1000_desc_ring {
unsigned int size;
/* number of descriptors in the ring */
unsigned int count;
/* (atomic) number of desc with no buffer */
atomic_t unused;
/* number of desc with no buffer */
unsigned int unused_count;
/* next descriptor to associate a buffer with */
unsigned int next_to_use;
/* next descriptor to check for DD status bit */
......@@ -173,14 +169,13 @@ struct e1000_desc_ring {
struct e1000_buffer *buffer_info;
};
#define E1000_RX_DESC(ring, i) \
(&(((struct e1000_rx_desc *)((ring).desc))[i]))
#define E1000_DESC_UNUSED(R) \
((((R)->next_to_clean + (R)->count) - ((R)->next_to_use + 1)) % ((R)->count))
#define E1000_TX_DESC(ring, i) \
(&(((struct e1000_tx_desc *)((ring).desc))[i]))
#define E1000_CONTEXT_DESC(ring, i) \
(&(((struct e1000_context_desc *)((ring).desc))[i]))
#define E1000_GET_DESC(R, i, type) (&(((struct type *)((R).desc))[i]))
#define E1000_RX_DESC(R, i) E1000_GET_DESC(R, i, e1000_rx_desc)
#define E1000_TX_DESC(R, i) E1000_GET_DESC(R, i, e1000_tx_desc)
#define E1000_CONTEXT_DESC(R, i) E1000_GET_DESC(R, i, e1000_context_desc)
/* board specific private data structure */
......@@ -204,8 +199,9 @@ struct e1000_adapter {
/* TX */
struct e1000_desc_ring tx_ring;
unsigned long trans_finish;
uint32_t tx_int_delay;
spinlock_t tx_lock;
uint32_t txd_cmd;
int max_data_per_txd;
/* RX */
struct e1000_desc_ring rx_ring;
......
This diff is collapsed.
......@@ -192,15 +192,6 @@ E1000_PARAM(FlowControl, "Flow Control setting");
E1000_PARAM(XsumRX, "Disable or enable Receive Checksum offload");
/* Transmit Interrupt Delay in units of 1.024 microseconds
*
* Valid Range: 0-65535
*
* Default Value: 64
*/
E1000_PARAM(TxIntDelay, "Transmit Interrupt Delay");
/* Receive Interrupt Delay in units of 1.024 microseconds
*
* Valid Range: 0-65535
......@@ -251,10 +242,6 @@ E1000_PARAM(DisablePolarityCorrection,
#define MIN_RXD 80
#define MAX_82544_RXD 4096
#define DEFAULT_TIDV 64
#define MAX_TIDV 0xFFFF
#define MIN_TIDV 0
#define DEFAULT_RDTR 64
#define DEFAULT_RADV 128
#define MAX_RXDELAY 0xFFFF
......@@ -423,18 +410,6 @@ e1000_check_options(struct e1000_adapter *adapter)
e1000_validate_option(&fc, &opt);
adapter->hw.fc = adapter->hw.original_fc = fc;
}
{ /* Transmit Interrupt Delay */
struct e1000_option opt = {
type: range_option,
name: "Transmit Interrupt Delay",
err: "using default of " __MODULE_STRING(DEFAULT_TIDV),
def: DEFAULT_TIDV,
arg: { r: { min: MIN_TIDV, max: MAX_TIDV }}
};
adapter->tx_int_delay = TxIntDelay[bd];
e1000_validate_option(&adapter->tx_int_delay, &opt);
}
{ /* Receive Interrupt Delay */
char *rdtr = "using default of " __MODULE_STRING(DEFAULT_RDTR);
char *radv = "using default of " __MODULE_STRING(DEFAULT_RADV);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment