aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ixgbe/ixgbe_common.h9
-rw-r--r--drivers/net/ixgbe/ixgbe_main.c12
2 files changed, 15 insertions, 6 deletions
diff --git a/drivers/net/ixgbe/ixgbe_common.h b/drivers/net/ixgbe/ixgbe_common.h
index 7e94d6d399a..24f73e719c3 100644
--- a/drivers/net/ixgbe/ixgbe_common.h
+++ b/drivers/net/ixgbe/ixgbe_common.h
@@ -96,14 +96,11 @@ s32 ixgbe_write_analog_reg8_generic(struct ixgbe_hw *hw, u32 reg, u8 val);
96#define IXGBE_WRITE_FLUSH(a) IXGBE_READ_REG(a, IXGBE_STATUS) 96#define IXGBE_WRITE_FLUSH(a) IXGBE_READ_REG(a, IXGBE_STATUS)
97 97
98#ifdef DEBUG 98#ifdef DEBUG
99extern char *ixgbe_get_hw_dev_name(struct ixgbe_hw *hw);
99#define hw_dbg(hw, format, arg...) \ 100#define hw_dbg(hw, format, arg...) \
100printk(KERN_DEBUG, "%s: " format, ixgbe_get_hw_dev_name(hw), ##arg); 101 printk(KERN_DEBUG "%s: " format, ixgbe_get_hw_dev_name(hw), ##arg)
101#else 102#else
102static inline int __attribute__ ((format (printf, 2, 3))) 103#define hw_dbg(hw, format, arg...) do {} while (0)
103hw_dbg(struct ixgbe_hw *hw, const char *format, ...)
104{
105 return 0;
106}
107#endif 104#endif
108 105
109#endif /* IXGBE_COMMON */ 106#endif /* IXGBE_COMMON */
diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c
index 79aa811c403..fd27513a92f 100644
--- a/drivers/net/ixgbe/ixgbe_main.c
+++ b/drivers/net/ixgbe/ixgbe_main.c
@@ -4987,8 +4987,20 @@ static int ixgbe_notify_dca(struct notifier_block *nb, unsigned long event,
4987 4987
4988 return ret_val ? NOTIFY_BAD : NOTIFY_DONE; 4988 return ret_val ? NOTIFY_BAD : NOTIFY_DONE;
4989} 4989}
4990
4990#endif /* CONFIG_IXGBE_DCA */ 4991#endif /* CONFIG_IXGBE_DCA */
4992#ifdef DEBUG
4993/**
4994 * ixgbe_get_hw_dev_name - return device name string
4995 * used by hardware layer to print debugging information
4996 **/
4997char *ixgbe_get_hw_dev_name(struct ixgbe_hw *hw)
4998{
4999 struct ixgbe_adapter *adapter = hw->back;
5000 return adapter->netdev->name;
5001}
4991 5002
5003#endif
4992module_exit(ixgbe_exit_module); 5004module_exit(ixgbe_exit_module);
4993 5005
4994/* ixgbe_main.c */ 5006/* ixgbe_main.c */