vserver 1.9.3
[linux-2.6.git] / drivers / net / e1000 / e1000.h
index 067bb09..108e331 100644 (file)
@@ -49,6 +49,7 @@
 #include <linux/delay.h>
 #include <linux/timer.h>
 #include <linux/slab.h>
+#include <linux/vmalloc.h>
 #include <linux/interrupt.h>
 #include <linux/string.h>
 #include <linux/pagemap.h>
@@ -63,6 +64,7 @@
 #include <linux/udp.h>
 #include <net/pkt_sched.h>
 #include <linux/list.h>
+#include <linux/rtnetlink.h>
 #include <linux/reboot.h>
 #ifdef NETIF_F_TSO
 #include <net/checksum.h>
@@ -77,6 +79,8 @@
 #define BAR_1          1
 #define BAR_5          5
 
+#define INTEL_E1000_ETHERNET_DEVICE(device_id) {\
+       PCI_DEVICE(PCI_VENDOR_ID_INTEL, device_id)}
 
 struct e1000_adapter;
 
@@ -98,11 +102,12 @@ struct e1000_adapter;
 
 #define E1000_MAX_INTR 10
 
-/* How many descriptors for TX and RX ? */
+/* TX/RX descriptor defines */
 #define E1000_DEFAULT_TXD                  256
 #define E1000_MAX_TXD                      256
 #define E1000_MIN_TXD                       80
 #define E1000_MAX_82544_TXD               4096
+
 #define E1000_DEFAULT_RXD                  256
 #define E1000_MAX_RXD                      256
 #define E1000_MIN_RXD                       80
@@ -123,14 +128,11 @@ struct e1000_adapter;
 #define E1000_TX_HEAD_ADDR_SHIFT 7
 #define E1000_PBA_TX_MASK 0xFFFF0000
 
-/* Flow Control High-Watermark: 5688 bytes below Rx FIFO size */
-#define E1000_FC_HIGH_DIFF 0x1638
-
-/* Flow Control Low-Watermark: 5696 bytes below Rx FIFO size */
-#define E1000_FC_LOW_DIFF 0x1640
+/* Flow Control Watermarks */
+#define E1000_FC_HIGH_DIFF 0x1638  /* High: 5688 bytes below Rx FIFO size */
+#define E1000_FC_LOW_DIFF 0x1640   /* Low:  5696 bytes below Rx FIFO size */
 
-/* Flow Control Pause Time: 858 usec */
-#define E1000_FC_PAUSE_TIME 0x0680
+#define E1000_FC_PAUSE_TIME 0x0680 /* 858 usec */
 
 /* How many Tx Descriptors do we need to call netif_wake_queue ? */
 #define E1000_TX_QUEUE_WAKE    16
@@ -153,9 +155,9 @@ struct e1000_adapter;
 struct e1000_buffer {
        struct sk_buff *skb;
        uint64_t dma;
-       unsigned long length;
        unsigned long time_stamp;
-       unsigned int next_to_watch;
+       uint16_t length;
+       uint16_t next_to_watch;
 };
 
 struct e1000_desc_ring {
@@ -202,7 +204,7 @@ struct e1000_adapter {
        spinlock_t stats_lock;
        atomic_t irq_sem;
        struct work_struct tx_timeout_task;
-       uint8_t fc_autoneg;
+       uint8_t fc_autoneg;
 
        struct timer_list blink_timer;
        unsigned long led_status;