From ac5ac789ebcf5b27e9edc231f6d33c92d722c607 Mon Sep 17 00:00:00 2001 From: Jesse Brandeburg Date: Fri, 23 Sep 2011 02:11:29 +0000 Subject: ixgb: eliminate checkstack warnings Really trivial fix, use kmalloc/kfree instead of stack space. use static const instead of const to further reduce stack usage. V2: reflect changes suggested by Joe Perches before: [jbrandeb@jbrandeb-mobl2 linux-2.6]$ make checkstack|grep '\[ixgb\]' 0x00000fc1 ixgb_set_multi [ixgb]: 768 0x00001031 ixgb_set_multi [ixgb]: 768 0x000010f2 ixgb_set_multi [ixgb]: 768 0x061c ixgb_check_options [ixgb]: 448 0x09c3 ixgb_check_options [ixgb]: 448 0x0000649e ixgb_set_ringparam [ixgb]: 192 0x0000130d ixgb_xmit_frame [ixgb]: 184 0x000019e0 ixgb_xmit_frame [ixgb]: 184 0x00002267 ixgb_clean [ixgb]: 152 0x00002673 ixgb_clean [ixgb]: 152 after: 0x000064ee ixgb_set_ringparam [ixgb]: 192 0x0000135d ixgb_xmit_frame [ixgb]: 184 0x00001a30 ixgb_xmit_frame [ixgb]: 184 0x000022b7 ixgb_clean [ixgb]: 152 0x000026c3 ixgb_clean [ixgb]: 152 Signed-off-by: Jesse Brandeburg Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher Signed-off-by: David S. Miller --- drivers/net/ethernet/intel/ixgb/ixgb_hw.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'drivers/net/ethernet/intel/ixgb/ixgb_hw.h') diff --git a/drivers/net/ethernet/intel/ixgb/ixgb_hw.h b/drivers/net/ethernet/intel/ixgb/ixgb_hw.h index 873d32b89fba..2a99a35c33aa 100644 --- a/drivers/net/ethernet/intel/ixgb/ixgb_hw.h +++ b/drivers/net/ethernet/intel/ixgb/ixgb_hw.h @@ -97,8 +97,6 @@ typedef enum { ixgb_bus_width_64 } ixgb_bus_width; -#define IXGB_ETH_LENGTH_OF_ADDRESS 6 - #define IXGB_EEPROM_SIZE 64 /* Size in words */ #define SPEED_10000 10000 @@ -674,7 +672,7 @@ struct ixgb_hw { u32 max_frame_size; /* Maximum frame size supported */ u32 mc_filter_type; /* Multicast filter hash type */ u32 num_mc_addrs; /* Number of current Multicast addrs */ - u8 curr_mac_addr[IXGB_ETH_LENGTH_OF_ADDRESS]; /* Individual address currently programmed in MAC */ + u8 curr_mac_addr[ETH_ALEN]; /* Individual address currently programmed in MAC */ u32 num_tx_desc; /* Number of Transmit descriptors */ u32 num_rx_desc; /* Number of Receive descriptors */ u32 rx_buffer_size; /* Size of Receive buffer */ -- cgit v1.2.3-59-g8ed1b