From 38cc04b3220e93601d66ddc6cc7fd77150bfda35 Mon Sep 17 00:00:00 2001 From: Jin Song Date: Wed, 28 May 2014 11:48:47 -0700 Subject: [PATCH] kmod: Make kmod compatible with kernel 3.14 or later Since linux kernel 3.14, compare_ether_addr() is deprecated and ether_addr_equal() is used instead. And function definition of igb_select_queue is also modified. Bug-Tizen: TIVI-3209 Change-Id: Ie54c6ba20eb1f6418a935e01b0dd508067642324 Signed-off-by: Jin Song --- kmod/igb/igb_main.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/kmod/igb/igb_main.c b/kmod/igb/igb_main.c index 3eddde5..407046f 100644 --- a/kmod/igb/igb_main.c +++ b/kmod/igb/igb_main.c @@ -129,7 +129,9 @@ static void igb_watchdog(unsigned long); static void igb_watchdog_task(struct work_struct *); static void igb_dma_err_task(struct work_struct *); static void igb_dma_err_timer(unsigned long data); -static u16 igb_select_queue(struct net_device *dev, struct sk_buff *skb); +static u16 igb_select_queue(struct net_device *dev, struct sk_buff *skb, + void *accel_priv, + select_queue_fallback_t fallback); static netdev_tx_t igb_xmit_frame(struct sk_buff *skb, struct net_device *); static struct net_device_stats *igb_get_stats(struct net_device *); static int igb_change_mtu(struct net_device *, int); @@ -5202,7 +5204,8 @@ static inline struct igb_ring *igb_tx_queue_mapping(struct igb_adapter *adapter, #error This driver must have multi-queue transmit support enabled (CONFIG_NETDEVICES_MULTIQUEUE)! #endif -static u16 igb_select_queue(struct net_device *dev, struct sk_buff *skb) +static u16 igb_select_queue(struct net_device *dev, struct sk_buff *skb, + void *accel_priv, select_queue_fallback_t fallback) { /* remap normal LAN to best effort queue[3] */ @@ -9048,7 +9051,7 @@ int igb_del_mac_filter(struct igb_adapter *adapter, u8* addr, u16 queue) if (is_zero_ether_addr(addr)) return 0; for (i = 0; i < hw->mac.rar_entry_count; i++) { - if (!compare_ether_addr(addr, adapter->mac_table[i].addr) && + if (ether_addr_equal(addr, adapter->mac_table[i].addr) && adapter->mac_table[i].queue == queue) { adapter->mac_table[i].state = IGB_MAC_STATE_MODIFIED; memset(adapter->mac_table[i].addr, 0, ETH_ALEN); -- 2.7.4