ixgb: add tx timeout counter
[sfrench/cifs-2.6.git] / drivers / net / ixgb / ixgb.h
index c83271b386215cefef859df73572f34bc535fa17..b9c37fdc84188b7570ba201463c3b73fad259965 100644 (file)
@@ -84,7 +84,12 @@ struct ixgb_adapter;
 #define IXGB_DBG(args...)
 #endif
 
-#define IXGB_ERR(args...) printk(KERN_ERR "ixgb: " args)
+#define PFX "ixgb: "
+#define DPRINTK(nlevel, klevel, fmt, args...) \
+       (void)((NETIF_MSG_##nlevel & adapter->msg_enable) && \
+       printk(KERN_##klevel PFX "%s: %s: " fmt, adapter->netdev->name, \
+               __FUNCTION__ , ## args))
+
 
 /* TX/RX descriptor defines */
 #define DEFAULT_TXD     256
@@ -175,6 +180,7 @@ struct ixgb_adapter {
        uint64_t hw_csum_tx_good;
        uint64_t hw_csum_tx_error;
        uint32_t tx_int_delay;
+       uint32_t tx_timeout_count;
        boolean_t tx_int_delay_enable;
        boolean_t detect_tx_hung;
 
@@ -192,6 +198,7 @@ struct ixgb_adapter {
 
        /* structs defined in ixgb_hw.h */
        struct ixgb_hw hw;
+       u16 msg_enable;
        struct ixgb_hw_stats stats;
 #ifdef CONFIG_PCI_MSI
        boolean_t have_msi;