Cc:Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Luis R. Rodriguez <mcgrof@suse.com>
----
-diff --git a/net/ieee802154/reassembly.c b/net/ieee802154/reassembly.c
-index f4ac957..0bcbef3 100644
---
-1.9.0
-
--- a/net/ieee802154/reassembly.c
+++ b/net/ieee802154/reassembly.c
-@@ -116,6 +116,8 @@ fq_find(struct net *net, const struct ie
+@@ -120,6 +120,8 @@ fq_find(struct net *net, const struct lo
struct inet_frag_queue *q;
struct lowpan_create_arg arg;
unsigned int hash;
arg.tag = frag_info->d_tag;
arg.d_size = frag_info->d_size;
-@@ -125,7 +127,7 @@ fq_find(struct net *net, const struct ie
+@@ -129,7 +131,7 @@ fq_find(struct net *net, const struct lo
read_lock(&lowpan_frags.lock);
hash = lowpan_hash_frag(frag_info->d_tag, frag_info->d_size, src, dst);
&lowpan_frags, &arg, hash);
if (IS_ERR_OR_NULL(q)) {
inet_frag_maybe_warn_overflow(q, pr_fmt());
-@@ -354,16 +356,18 @@ int lowpan_frag_rcv(struct sk_buff *skb,
- struct lowpan_frag_queue *fq;
+@@ -357,6 +359,8 @@ int lowpan_frag_rcv(struct sk_buff *skb,
struct net *net = dev_net(skb->dev);
- struct ieee802154_frag_info *frag_info = &mac_cb(skb)->frag_info;
+ struct lowpan_frag_info *frag_info = lowpan_cb(skb);
+ struct ieee802154_addr source, dest;
+ struct netns_ieee802154_lowpan *ieee802154_lowpan =
+ net_ieee802154_lowpan(net);
int err;
- err = lowpan_get_frag_info(skb, frag_type, frag_info);
+ source = mac_cb(skb)->source;
+@@ -366,10 +370,10 @@ int lowpan_frag_rcv(struct sk_buff *skb,
if (err < 0)
goto err;
- inet_frag_evictor(&net->ieee802154_lowpan.frags, &lowpan_frags, false);
+ inet_frag_evictor(&ieee802154_lowpan->frags, &lowpan_frags, false);
- fq = fq_find(net, frag_info, &mac_cb(skb)->sa, &mac_cb(skb)->da);
+ fq = fq_find(net, frag_info, &source, &dest);
if (fq != NULL) {
-@@ -430,6 +434,8 @@ static int __net_init lowpan_frags_ns_sy
+@@ -436,6 +440,8 @@ static int __net_init lowpan_frags_ns_sy
{
struct ctl_table *table;
struct ctl_table_header *hdr;
table = lowpan_frags_ns_ctl_table;
if (!net_eq(net, &init_net)) {
-@@ -438,10 +444,10 @@ static int __net_init lowpan_frags_ns_sy
+@@ -444,10 +450,10 @@ static int __net_init lowpan_frags_ns_sy
if (table == NULL)
goto err_alloc;
/* Don't export sysctls to unprivileged users */
if (net->user_ns != &init_user_ns)
-@@ -452,7 +458,7 @@ static int __net_init lowpan_frags_ns_sy
+@@ -458,7 +464,7 @@ static int __net_init lowpan_frags_ns_sy
if (hdr == NULL)
goto err_reg;
return 0;
err_reg:
-@@ -465,9 +471,11 @@ err_alloc:
+@@ -471,9 +477,11 @@ err_alloc:
static void __net_exit lowpan_frags_ns_sysctl_unregister(struct net *net)
{
struct ctl_table *table;
if (!net_eq(net, &init_net))
kfree(table);
}
-@@ -508,20 +516,26 @@ static inline void lowpan_frags_sysctl_u
+@@ -514,20 +522,26 @@ static inline void lowpan_frags_sysctl_u
static int __net_init lowpan_frags_init_net(struct net *net)
{
nla_put_u32(skb, TCA_FQ_CODEL_INTERVAL,
codel_time_to_us(q->cparams.interval)) ||
nla_put_u32(skb, TCA_FQ_CODEL_ECN,
-@@ -599,7 +630,9 @@ static struct Qdisc_ops fq_codel_qdisc_o
+@@ -598,7 +629,9 @@ static struct Qdisc_ops fq_codel_qdisc_o
.priv_size = sizeof(struct fq_codel_sched_data),
.enqueue = fq_codel_enqueue,
.dequeue = fq_codel_dequeue,
};
struct video_device *video_devdata(struct file *file)
-@@ -1012,6 +1021,7 @@ static int __init videodev_init(void)
+@@ -1014,6 +1023,7 @@ static int __init videodev_init(void)
return ret;
}
--- a/net/ieee802154/reassembly.c
+++ b/net/ieee802154/reassembly.c
-@@ -104,7 +104,11 @@ static void lowpan_frag_expire(unsigned
+@@ -99,7 +99,11 @@ static void lowpan_frag_expire(unsigned
struct net *net;
fq = container_of((struct inet_frag_queue *)data, struct frag_queue, q);
+ net = &init_net;
+#endif
- lowpan_expire_frag_queue(fq, &lowpan_frags);
- }
-@@ -390,28 +394,44 @@ EXPORT_SYMBOL(lowpan_frag_rcv);
+ spin_lock(&fq->q.lock);
+
+@@ -396,28 +400,44 @@ EXPORT_SYMBOL(lowpan_frag_rcv);
static struct ctl_table lowpan_frags_ns_ctl_table[] = {
{
.procname = "6lowpanfrag_high_thresh",
--- a/net/ieee802154/reassembly.c
+++ b/net/ieee802154/reassembly.c
-@@ -81,6 +81,9 @@ void lowpan_frag_init(struct inet_frag_q
+@@ -91,6 +91,9 @@ static void lowpan_frag_init(struct inet
fq->d_size = arg->d_size;
fq->saddr = *arg->src;
fq->daddr = *arg->dst;
+ spin_lock_init(&fq->lru_lock);
+#endif
}
- EXPORT_SYMBOL(lowpan_frag_init);
+ static void lowpan_frag_expire(unsigned long data)
--- a/net/ieee802154/reassembly.h
+++ b/net/ieee802154/reassembly.h
@@ -2,6 +2,7 @@
+
static inline u32 ieee802154_addr_hash(const struct ieee802154_addr *a)
{
- switch (a->addr_type) {
+ switch (a->mode) {
--- a/net/ieee802154/reassembly.c
+++ b/net/ieee802154/reassembly.c
-@@ -472,9 +472,11 @@ static int __net_init lowpan_frags_ns_sy
+@@ -478,9 +478,11 @@ static int __net_init lowpan_frags_ns_sy
table[2].data = &ieee802154_lowpan->frags.timeout;
table[3].data = &ieee802154_lowpan->max_dsize;
--- a/net/ieee802154/reassembly.c
+++ b/net/ieee802154/reassembly.c
-@@ -374,7 +374,14 @@ int lowpan_frag_rcv(struct sk_buff *skb,
+@@ -380,7 +380,14 @@ int lowpan_frag_rcv(struct sk_buff *skb,
if (frag_info->d_size > ieee802154_lowpan->max_dsize)
goto err;
+ inet_frag_evictor(&ieee802154_lowpan->frags, &lowpan_frags);
+#endif
- fq = fq_find(net, frag_info, &mac_cb(skb)->sa, &mac_cb(skb)->da);
+ fq = fq_find(net, frag_info, &source, &dest);
if (fq != NULL) {
--- a/drivers/net/wireless/p54/p54usb.c
+++ b/drivers/net/wireless/p54/p54usb.c
-@@ -1138,7 +1138,9 @@ static struct usb_driver p54u_driver = {
+@@ -1142,7 +1142,9 @@ static struct usb_driver p54u_driver = {
.resume = p54u_resume,
.reset_resume = p54u_resume,
#endif /* CONFIG_PM */
--- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c
+++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c
-@@ -952,12 +952,21 @@ static void iwl_mvm_recalc_multicast(str
+@@ -1029,12 +1029,21 @@ static void iwl_mvm_recalc_multicast(str
}
static u64 iwl_mvm_prepare_multicast(struct ieee80211_hw *hw,
bool pass_all = false;
int len;
-@@ -976,11 +985,15 @@ static u64 iwl_mvm_prepare_multicast(str
+@@ -1053,11 +1062,15 @@ static u64 iwl_mvm_prepare_multicast(str
return (u64)(unsigned long)cmd;
}
--- a/drivers/net/wireless/rtl818x/rtl8180/dev.c
+++ b/drivers/net/wireless/rtl818x/rtl8180/dev.c
-@@ -867,10 +867,19 @@ static void rtl8180_bss_info_changed(str
+@@ -987,10 +987,19 @@ static void rtl8180_bss_info_changed(str
}
}
--- a/drivers/net/wireless/iwlwifi/mvm/led.c
+++ b/drivers/net/wireless/iwlwifi/mvm/led.c
-@@ -108,7 +108,9 @@ int iwl_mvm_leds_init(struct iwl_mvm *mv
+@@ -110,7 +110,9 @@ int iwl_mvm_leds_init(struct iwl_mvm *mv
mvm->led.name = kasprintf(GFP_KERNEL, "%s-led",
wiphy_name(mvm->hw->wiphy));
mvm->led.brightness_set = iwl_led_brightness_set;
#ifdef CONFIG_NET_POLL_CONTROLLER
.ndo_poll_controller = alx_poll_controller,
#endif
-@@ -1345,7 +1359,11 @@ static int alx_probe(struct pci_dev *pde
+@@ -1339,7 +1353,11 @@ static int alx_probe(struct pci_dev *pde
}
}
--- a/drivers/net/wireless/ath/wil6210/netdev.c
+++ b/drivers/net/wireless/ath/wil6210/netdev.c
-@@ -127,7 +127,9 @@ void *wil_if_alloc(struct device *dev, v
+@@ -127,9 +127,13 @@ void *wil_if_alloc(struct device *dev, v
ndev->netdev_ops = &wil_netdev_ops;
ndev->ieee80211_ptr = wdev;
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39))
- ndev->hw_features = NETIF_F_HW_CSUM | NETIF_F_RXCSUM;
+ ndev->hw_features = NETIF_F_HW_CSUM | NETIF_F_RXCSUM |
+ NETIF_F_SG | NETIF_F_GRO;
+ ndev->features |= ndev->hw_features;
++#else
++ ndev->features |= NETIF_F_HW_CSUM | NETIF_F_RXCSUM | NETIF_F_SG;
+#endif
- ndev->features |= NETIF_F_HW_CSUM | NETIF_F_RXCSUM;
SET_NETDEV_DEV(ndev, wiphy_dev(wdev->wiphy));
wdev->netdev = ndev;
+
{ .name = NFC_GENL_MCAST_EVENT_NAME, },
};
-@@ -1362,7 +1362,7 @@ static int nfc_genl_se_io(struct sk_buff
+@@ -1370,7 +1370,7 @@ static int nfc_genl_se_io(struct sk_buff
return dev->ops->se_io(dev, se_idx, apdu, apdu_len, se_io_cb, ctx);
}
/*
* This function prepares command to set/get RSSI information.
-@@ -1430,9 +1431,10 @@ static int mwifiex_cmd_cfg_data(struct m
+@@ -1444,9 +1445,10 @@ static int mwifiex_cmd_cfg_data(struct m
struct property *prop = data_buf;
u32 len;
u8 *data = (u8 *)cmd + S_DS_GEN;
len = prop->length;
ret = of_property_read_u8_array(adapter->dt_node, prop->name,
data, len);
-@@ -1440,6 +1442,9 @@ static int mwifiex_cmd_cfg_data(struct m
+@@ -1454,6 +1456,9 @@ static int mwifiex_cmd_cfg_data(struct m
return ret;
dev_dbg(adapter->dev,
"download cfg_data from device tree: %s\n", prop->name);
static void igb_restore_vlan(struct igb_adapter *);
static void igb_rar_set_qsel(struct igb_adapter *, u8 *, u32 , u8);
static void igb_ping_all_vfs(struct igb_adapter *);
-@@ -7168,8 +7173,12 @@ static void igb_vlan_mode(struct net_dev
+@@ -7209,8 +7214,12 @@ static void igb_vlan_mode(struct net_dev
igb_rlpml_set(adapter);
}
{
struct igb_adapter *adapter = netdev_priv(netdev);
struct e1000_hw *hw = &adapter->hw;
-@@ -7186,8 +7195,12 @@ static int igb_vlan_rx_add_vid(struct ne
+@@ -7227,8 +7236,12 @@ static int igb_vlan_rx_add_vid(struct ne
return 0;
}
{
struct igb_adapter *adapter = netdev_priv(netdev);
struct e1000_hw *hw = &adapter->hw;
-@@ -7213,7 +7226,11 @@ static void igb_restore_vlan(struct igb_
+@@ -7254,7 +7267,11 @@ static void igb_restore_vlan(struct igb_
igb_vlan_mode(adapter->netdev, adapter->netdev->features);
for_each_set_bit(vid, adapter->active_vlans, VLAN_N_VID)
.err_handler = &igb_err_handler
};
-@@ -7519,6 +7523,7 @@ static int igb_sriov_reinit(struct pci_d
+@@ -7560,6 +7564,7 @@ static int igb_sriov_reinit(struct pci_d
return 0;
}
static int igb_pci_disable_sriov(struct pci_dev *dev)
{
int err = igb_disable_sriov(dev);
-@@ -7528,6 +7533,7 @@ static int igb_pci_disable_sriov(struct
+@@ -7569,6 +7574,7 @@ static int igb_pci_disable_sriov(struct
return err;
}
static int igb_pci_enable_sriov(struct pci_dev *dev, int num_vfs)
{
-@@ -7545,6 +7551,8 @@ out:
+@@ -7586,6 +7592,8 @@ out:
}
#endif
static int igb_pci_sriov_configure(struct pci_dev *dev, int num_vfs)
{
#ifdef CONFIG_PCI_IOV
-@@ -7555,6 +7563,7 @@ static int igb_pci_sriov_configure(struc
+@@ -7596,6 +7604,7 @@ static int igb_pci_sriov_configure(struc
#endif
return 0;
}
static int igb_get_eee(struct net_device *netdev, struct ethtool_eee *edata)
{
struct igb_adapter *adapter = netdev_priv(netdev);
-@@ -2717,6 +2718,7 @@ static int igb_set_eee(struct net_device
+@@ -2730,6 +2731,7 @@ static int igb_set_eee(struct net_device
return 0;
}
static int igb_get_module_info(struct net_device *netdev,
struct ethtool_modinfo *modinfo)
-@@ -3005,8 +3007,10 @@ static const struct ethtool_ops igb_etht
+@@ -3018,8 +3020,10 @@ static const struct ethtool_ops igb_etht
.get_ts_info = igb_get_ts_info,
.get_rxnfc = igb_get_rxnfc,
.set_rxnfc = igb_set_rxnfc,
static int igb_get_rss_hash_opts(struct igb_adapter *adapter,
struct ethtool_rxnfc *cmd)
-@@ -2720,6 +2722,7 @@ static int igb_set_eee(struct net_device
+@@ -2733,6 +2735,7 @@ static int igb_set_eee(struct net_device
}
#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3,6,0) */
static int igb_get_module_info(struct net_device *netdev,
struct ethtool_modinfo *modinfo)
{
-@@ -2798,6 +2801,7 @@ static int igb_get_module_eeprom(struct
+@@ -2811,6 +2814,7 @@ static int igb_get_module_eeprom(struct
return 0;
}
static int igb_ethtool_begin(struct net_device *netdev)
{
-@@ -3004,15 +3008,19 @@ static const struct ethtool_ops igb_etht
+@@ -3017,15 +3021,19 @@ static const struct ethtool_ops igb_etht
.get_ethtool_stats = igb_get_ethtool_stats,
.get_coalesce = igb_get_coalesce,
.set_coalesce = igb_set_coalesce,
index fd6a103..a919cfa 100644
--- a/drivers/net/ethernet/intel/igb/igb_main.c
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
-@@ -4691,9 +4691,10 @@ static u32 igb_tx_cmd_type(struct sk_buf
+@@ -4730,9 +4730,10 @@ static u32 igb_tx_cmd_type(struct sk_buf
cmd_type |= IGB_SET_FLAG(tx_flags, IGB_TX_FLAGS_TSTAMP,
(E1000_ADVTXD_MAC_TSTAMP));
static void igb_restore_vlan(struct igb_adapter *);
static void igb_rar_set_qsel(struct igb_adapter *, u8 *, u32 , u8);
static void igb_ping_all_vfs(struct igb_adapter *);
-@@ -7185,8 +7188,10 @@ static void igb_vlan_mode(struct net_dev
+@@ -7226,8 +7229,10 @@ static void igb_vlan_mode(struct net_dev
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,10,0)
static int igb_vlan_rx_add_vid(struct net_device *netdev,
__be16 proto, u16 vid)
#endif
{
struct igb_adapter *adapter = netdev_priv(netdev);
-@@ -7201,15 +7206,19 @@ static int igb_vlan_rx_add_vid(struct ne
+@@ -7242,15 +7247,19 @@ static int igb_vlan_rx_add_vid(struct ne
set_bit(vid, adapter->active_vlans);
{
struct igb_adapter *adapter = netdev_priv(netdev);
struct e1000_hw *hw = &adapter->hw;
-@@ -7225,7 +7234,9 @@ static int igb_vlan_rx_kill_vid(struct n
+@@ -7266,7 +7275,9 @@ static int igb_vlan_rx_kill_vid(struct n
clear_bit(vid, adapter->active_vlans);
index 3cf9600..5e519ce 100644
--- a/drivers/net/ethernet/intel/igb/igb_ethtool.c
+++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c
-@@ -2816,6 +2816,7 @@ static void igb_ethtool_complete(struct
+@@ -2829,6 +2829,7 @@ static void igb_ethtool_complete(struct
pm_runtime_put(&adapter->pdev->dev);
}
static u32 igb_get_rxfh_indir_size(struct net_device *netdev)
{
return IGB_RETA_SIZE;
-@@ -2831,6 +2832,7 @@ static int igb_get_rxfh_indir(struct net
+@@ -2844,6 +2845,7 @@ static int igb_get_rxfh_indir(struct net
return 0;
}
void igb_write_rss_indir_tbl(struct igb_adapter *adapter)
{
-@@ -2867,6 +2869,7 @@ void igb_write_rss_indir_tbl(struct igb_
+@@ -2880,6 +2882,7 @@ void igb_write_rss_indir_tbl(struct igb_
}
}
static int igb_set_rxfh_indir(struct net_device *netdev, const u32 *indir)
{
struct igb_adapter *adapter = netdev_priv(netdev);
-@@ -2899,6 +2902,7 @@ static int igb_set_rxfh_indir(struct net
+@@ -2912,6 +2915,7 @@ static int igb_set_rxfh_indir(struct net
return 0;
}
static unsigned int igb_max_channels(struct igb_adapter *adapter)
{
-@@ -3021,9 +3025,11 @@ static const struct ethtool_ops igb_etht
+@@ -3034,9 +3038,11 @@ static const struct ethtool_ops igb_etht
.get_module_info = igb_get_module_info,
.get_module_eeprom = igb_get_module_eeprom,
#endif
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,6,0)
static int igb_get_eee(struct net_device *netdev, struct ethtool_eee *edata)
-@@ -3015,8 +3017,10 @@ static const struct ethtool_ops igb_etht
+@@ -3028,8 +3030,10 @@ static const struct ethtool_ops igb_etht
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,5,0)
.get_ts_info = igb_get_ts_info,
#endif
static int igb_ndo_get_vf_config(struct net_device *netdev, int vf,
struct ifla_vf_info *ivi);
static void igb_check_vf_rate_limit(struct igb_adapter *);
-@@ -2056,7 +2058,9 @@ static const struct net_device_ops igb_n
+@@ -2075,7 +2077,9 @@ static const struct net_device_ops igb_n
.ndo_set_vf_mac = igb_ndo_set_vf_mac,
.ndo_set_vf_vlan = igb_ndo_set_vf_vlan,
.ndo_set_vf_tx_rate = igb_ndo_set_vf_bw,
.ndo_get_vf_config = igb_ndo_get_vf_config,
#ifdef CONFIG_NET_POLL_CONTROLLER
.ndo_poll_controller = igb_netpoll,
-@@ -7854,6 +7858,7 @@ static int igb_ndo_set_vf_bw(struct net_
+@@ -7895,6 +7899,7 @@ static int igb_ndo_set_vf_bw(struct net_
return 0;
}
static int igb_ndo_set_vf_spoofchk(struct net_device *netdev, int vf,
bool setting)
{
-@@ -7880,6 +7885,7 @@ static int igb_ndo_set_vf_spoofchk(struc
+@@ -7921,6 +7926,7 @@ static int igb_ndo_set_vf_spoofchk(struc
adapter->vf_data[vf].spoofchk_enabled = setting;
return E1000_SUCCESS;
}
static int igb_ndo_get_vf_config(struct net_device *netdev,
int vf, struct ifla_vf_info *ivi)
-@@ -7892,7 +7898,9 @@ static int igb_ndo_get_vf_config(struct
+@@ -7933,7 +7939,9 @@ static int igb_ndo_get_vf_config(struct
ivi->tx_rate = adapter->vf_data[vf].tx_rate;
ivi->vlan = adapter->vf_data[vf].pf_vlan;
ivi->qos = adapter->vf_data[vf].pf_qos;
static int hidp_set_raw_report(struct hid_device *hid, unsigned char reportnum,
unsigned char *data, size_t count,
-@@ -394,6 +396,7 @@ static int hidp_output_raw_report(struct
- return hidp_set_raw_report(hid, data[0], data, count, report_type);
+@@ -382,6 +384,7 @@ static int hidp_output_report(struct hid
+ data, count);
}
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,15,0)
static int hidp_raw_request(struct hid_device *hid, unsigned char reportnum,
__u8 *buf, size_t len, unsigned char rtype,
int reqtype)
-@@ -407,6 +410,7 @@ static int hidp_raw_request(struct hid_d
+@@ -395,6 +398,7 @@ static int hidp_raw_request(struct hid_d
return -EIO;
}
}
static void hidp_idle_timeout(unsigned long arg)
{
-@@ -736,8 +740,10 @@ static struct hid_ll_driver hidp_hid_dri
+@@ -724,8 +728,10 @@ static struct hid_ll_driver hidp_hid_dri
.stop = hidp_stop,
.open = hidp_open,
.close = hidp_close,
--- a/net/ieee802154/6lowpan_rtnl.c
+++ b/net/ieee802154/6lowpan_rtnl.c
-@@ -374,7 +374,9 @@ static struct header_ops lowpan_header_o
+@@ -384,7 +384,9 @@ static struct header_ops lowpan_header_o
.create = lowpan_header_create,
};
static struct lock_class_key lowpan_netdev_xmit_lock_key;
static void lowpan_set_lockdep_class_one(struct net_device *dev,
-@@ -389,7 +391,9 @@ static void lowpan_set_lockdep_class_one
+@@ -399,7 +401,9 @@ static void lowpan_set_lockdep_class_one
static int lowpan_dev_init(struct net_device *dev)
{
netdev_for_each_tx_queue(dev, lowpan_set_lockdep_class_one, NULL);