backports.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/47] backports: Update to kernel 5.15-rc6
@ 2021-10-19 21:42 Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 01/47] patches: Refresh on kernel 5.11.22 Hauke Mehrtens
                   ` (47 more replies)
  0 siblings, 48 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This updates backports to kernel 5.15-rc6.

This is done in multiple steps, I plan to make a release based on the 
latest stable version for each major kernel version between 5.10 and 
5.15-rc6. This was compile tested against kernel 4.4 till 5.10 and 
runtime tested in AP mode with ath9k. We want to use this in OpenWrt and 
are testing this in OpenWrt now.

These patches are also available here:
https://github.com/hauke/backports/tree/devel-5.15-2


Hauke Mehrtens (47):
  patches: Refresh on kernel 5.11.22
  backports: Add dev_get_tstats64() and bp_dev_get_tstats64()
  backports: Add empty implementation for skb_get_kcov_handle()
  backports: Add linux/math.h
  backports: Add dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add()
  headers: Add linux/kcov.h
  patches: Do not use rx_list in mt76 on older kernel versions.
  dependencies: Build mt7915 only on kernel >= 4.6
  patches: Remove const from struct rchan_callbacks
  patches: Refresh patches on top of kernel 5.12.19
  patches: include linux/modules.h in mt76/mt76_connac_mcu.c
  patches: Do not use rx_list in mt76/mt7921 driver on older kernel
    versions.
  patches: Do not use rx_list in mt7601u driver on older kernel
    versions.
  dependencies: Build mt7921 only on kernel >= 4.6
  dependencies: Build NL80211_TESTMODE only on kernel >= 4.18
  headers: Add DECLARE_STATIC_KEY_FALSE
  headers: Add ETH_P_MAP
  patches: Refresh on top of kernel 5.13.19
  headers: Add tasklet_disable_in_atomic()
  headers: Add lockdep_assert_not_held()
  headers: Adapt signature of of_get_mac_address()
  headers: Add rfkill_set_hw_state_reason()
  patches: Remove usage of threaded NAPI from mt76
  headers: Adapt signature of thermal_zone_device_update()
  headers: Add time_after32()
  patches: Refresh on top of kernel 5.14.13
  headers: Add FW_ACTION_NOUEVENT and FW_ACTION_UEVENT
  headers: Add linux/wwan.h file
  headers: Add DEVICE_ATTR_ADMIN_RW
  headers: Add get_unaligned_be24
  headers: Add rbtree cached
  headers: Adapt signature of hrtimer_forward_now()
  dependencies: Build RTL8723BS only on kernel >= 5.4
  backports: Remove rtl8188eu driver
  backports: Remove prism54 driver
  patches: Refresh on top of kernel 5.15-rc6
  backports: Remove old CISCO airo driver
  backports: Remove intersil hostap driver
  patches: Adapt signature of bus_type->remove callback
  patches: Adapt signature of ethtool_ops->set_coalesce callback
  patches: Do not set mhi_controller->reg_len on older kernel versions
  backports: Update wifi defconfig
  backports: Add new r8188eu driver
  headers: Add new include/linux/bits.h
  headers: Add function devm_clk_get_optional()
  patches: Remove usage of DMI_PRODUCT_SKU
  headers: Check for NULL in dev_put() and dev_hold()

 backport/backport-include/asm/unaligned.h     |  17 ++
 backport/backport-include/linux/bits.h        |  14 ++
 backport/backport-include/linux/clk.h         |  20 +++
 backport/backport-include/linux/device.h      |  10 ++
 backport/backport-include/linux/firmware.h    |   8 +
 backport/backport-include/linux/if_ether.h    |   6 +
 backport/backport-include/linux/interrupt.h   |  32 ++++
 backport/backport-include/linux/jump_label.h  |  10 ++
 backport/backport-include/linux/kcov.h        |  16 ++
 backport/backport-include/linux/lockdep.h     |  11 ++
 backport/backport-include/linux/math.h        |  12 ++
 backport/backport-include/linux/netdevice.h   |  54 +++++++
 backport/backport-include/linux/of_net.h      |  14 +-
 backport/backport-include/linux/rbtree.h      |  59 +++++++
 backport/backport-include/linux/rfkill.h      |  24 +++
 backport/backport-include/linux/sched.h       |   5 +
 backport/backport-include/linux/skbuff.h      |   8 +
 backport/backport-include/linux/sysfs.h       |   9 ++
 backport/backport-include/linux/thermal.h     |  23 +++
 backport/backport-include/linux/time.h        |  17 ++
 backport/backport-include/linux/wwan.h        |  35 ++++
 backport/compat/Makefile                      |   3 +
 backport/compat/backport-4.11.c               |  12 ++
 backport/compat/backport-5.11.c               |  19 +++
 backport/compat/backport-5.13.c               |  30 ++++
 backport/defconfigs/wifi                      |  26 +--
 copy-list                                     |   8 +-
 dependencies                                  |  10 ++
 .../include_net_cfg80211.patch                |   4 +-
 .../net_wireless_core.patch                   |   2 +-
 .../net_wireless_core.patch                   |   4 +-
 .../0013-fix-makefile-includes/cfg80211.patch |  16 +-
 patches/0013-fix-makefile-includes/mt76.patch |  10 ++
 .../0013-fix-makefile-includes/r8188eu.patch  |  12 ++
 .../0013-fix-makefile-includes/rtw88.patch    |  10 +-
 .../0013-fix-makefile-includes/wilc1000.patch |   4 +-
 patches/0028-select_queue/mac80211.patch      |   4 +-
 patches/0028-select_queue/mwifiex.patch       |   2 +-
 .../{rtl8188eu.patch => r8188eu.patch}        |  17 +-
 patches/0028-select_queue/rtl8723bs.patch     |   2 +-
 patches/0075-ndo-stats-64/usbnet.patch        |  24 ---
 patches/0077-genl-ro-after-init/hwsim.patch   |   2 +-
 patches/0077-genl-ro-after-init/nl80211.patch |   2 +-
 patches/0079-netdev-destructor/brcmfmac.patch |   6 +-
 patches/0084-disable-some-staging-dirs.patch  |   8 +-
 patches/0089-unknown-dmi/mwifiex.patch        |  22 +++
 patches/0092-listified-rx/iwlwifi.patch       |  19 ---
 patches/0094-ndo-tx-timeout/prism54.patch     |  23 ---
 patches/0094-ndo-tx-timeout/usbnet.patch      |   2 +-
 patches/0095-spi-delay/wilc1000.patch         |   6 +-
 patches/0097-skb-list/mac80211-rx.patch       |  28 +++-
 patches/0097-skb-list/mac80211-status.patch   |   6 +-
 patches/0097-skb-list/mt76.patch              | 150 ++++++++++++++++++
 patches/0097-skb-list/mt7601u.patch           |  30 ++++
 patches/0098-netdev_nested_priv/qtnfmac.patch |   6 +-
 patches/0099-netlink-range/mac80211.patch     |  13 +-
 patches/0100-revert-small_ops/mac80211.patch  |   8 +-
 .../mac80211_hwsim.patch                      |   4 +-
 patches/0101-net_device-threaded/mt76.patch   |  41 +++++
 patches/0102-remove-callback.patch            |  63 ++++++++
 patches/0103-ethtool-coalesce.patch           |  36 +++++
 patches/0104-mhi-reg-len.patch                |  12 ++
 ...05-remove-const-from-rchan_callbacks.patch |  42 +++++
 patches/verify.patch                          |  14 +-
 64 files changed, 1002 insertions(+), 164 deletions(-)
 create mode 100644 backport/backport-include/asm/unaligned.h
 create mode 100644 backport/backport-include/linux/bits.h
 create mode 100644 backport/backport-include/linux/clk.h
 create mode 100644 backport/backport-include/linux/device.h
 create mode 100644 backport/backport-include/linux/jump_label.h
 create mode 100644 backport/backport-include/linux/kcov.h
 create mode 100644 backport/backport-include/linux/math.h
 create mode 100644 backport/backport-include/linux/rbtree.h
 create mode 100644 backport/backport-include/linux/rfkill.h
 create mode 100644 backport/backport-include/linux/wwan.h
 create mode 100644 backport/compat/backport-4.11.c
 create mode 100644 backport/compat/backport-5.11.c
 create mode 100644 backport/compat/backport-5.13.c
 create mode 100644 patches/0013-fix-makefile-includes/r8188eu.patch
 rename patches/0028-select_queue/{rtl8188eu.patch => r8188eu.patch} (56%)
 delete mode 100644 patches/0075-ndo-stats-64/usbnet.patch
 create mode 100644 patches/0089-unknown-dmi/mwifiex.patch
 delete mode 100644 patches/0092-listified-rx/iwlwifi.patch
 delete mode 100644 patches/0094-ndo-tx-timeout/prism54.patch
 create mode 100644 patches/0097-skb-list/mt76.patch
 create mode 100644 patches/0097-skb-list/mt7601u.patch
 create mode 100644 patches/0101-net_device-threaded/mt76.patch
 create mode 100644 patches/0102-remove-callback.patch
 create mode 100644 patches/0103-ethtool-coalesce.patch
 create mode 100644 patches/0104-mhi-reg-len.patch
 create mode 100644 patches/0105-remove-const-from-rchan_callbacks.patch

-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 51+ messages in thread

* [PATCH 01/47] patches: Refresh on kernel 5.11.22
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 02/47] backports: Add dev_get_tstats64() and bp_dev_get_tstats64() Hauke Mehrtens
                   ` (46 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The usbnet_get_stats64() function was removed and replaced with the
generic function dev_get_tstats64() which will be added later.
The patch adding bp_usbnet_get_stats64() can be removed.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 .../include_net_cfg80211.patch                |  2 +-
 .../net_wireless_core.patch                   |  2 +-
 .../0013-fix-makefile-includes/cfg80211.patch |  2 +-
 .../0013-fix-makefile-includes/rtw88.patch    |  4 ++--
 patches/0028-select_queue/mac80211.patch      |  4 ++--
 patches/0075-ndo-stats-64/usbnet.patch        | 24 -------------------
 patches/0077-genl-ro-after-init/hwsim.patch   |  2 +-
 patches/0077-genl-ro-after-init/nl80211.patch |  2 +-
 patches/0084-disable-some-staging-dirs.patch  |  4 ++--
 patches/0092-listified-rx/iwlwifi.patch       |  2 +-
 patches/0094-ndo-tx-timeout/usbnet.patch      |  2 +-
 patches/0095-spi-delay/wilc1000.patch         |  6 ++---
 patches/0097-skb-list/mac80211-rx.patch       | 16 ++++++-------
 patches/0097-skb-list/mac80211-status.patch   |  2 +-
 patches/0098-netdev_nested_priv/qtnfmac.patch |  6 ++---
 patches/0099-netlink-range/mac80211.patch     |  4 ++--
 patches/0100-revert-small_ops/mac80211.patch  |  4 ++--
 .../mac80211_hwsim.patch                      |  4 ++--
 18 files changed, 34 insertions(+), 58 deletions(-)
 delete mode 100644 patches/0075-ndo-stats-64/usbnet.patch

diff --git a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
index 9d90ea82..fd465b15 100644
--- a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
+++ b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
@@ -1,6 +1,6 @@
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -4883,6 +4883,9 @@ struct wiphy_iftype_akm_suites {
+@@ -4936,6 +4936,9 @@ struct wiphy_iftype_akm_suites {
  struct wiphy {
  	/* assign these fields before you register the wiphy */
  
diff --git a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
index 040225b0..42a11a09 100644
--- a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
+++ b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
@@ -11,7 +11,7 @@
  	device_initialize(&rdev->wiphy.dev);
  	rdev->wiphy.dev.class = &ieee80211_class;
  	rdev->wiphy.dev.platform_data = rdev;
-@@ -1273,6 +1269,10 @@ void cfg80211_init_wdev(struct wireless_
+@@ -1267,6 +1263,10 @@ void cfg80211_init_wdev(struct wireless_
  	INIT_WORK(&wdev->pmsr_free_wk, cfg80211_pmsr_free_wk);
  
  #ifdef CONFIG_CFG80211_WEXT
diff --git a/patches/0013-fix-makefile-includes/cfg80211.patch b/patches/0013-fix-makefile-includes/cfg80211.patch
index ba4f0825..0e079911 100644
--- a/patches/0013-fix-makefile-includes/cfg80211.patch
+++ b/patches/0013-fix-makefile-includes/cfg80211.patch
@@ -6,7 +6,7 @@ the type is renamed.
 
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -21,6 +21,7 @@
+@@ -22,6 +22,7 @@
  #include <linux/ieee80211.h>
  #include <linux/net.h>
  #include <net/regulatory.h>
diff --git a/patches/0013-fix-makefile-includes/rtw88.patch b/patches/0013-fix-makefile-includes/rtw88.patch
index 961ef25c..a81a0542 100644
--- a/patches/0013-fix-makefile-includes/rtw88.patch
+++ b/patches/0013-fix-makefile-includes/rtw88.patch
@@ -8,8 +8,8 @@ linux/module.h include needed for kernel 3.18
  #include "bf.h"
 +#include <linux/module.h>
  
- unsigned int rtw_fw_lps_deep_mode;
- EXPORT_SYMBOL(rtw_fw_lps_deep_mode);
+ bool rtw_disable_lps_deep_mode;
+ EXPORT_SYMBOL(rtw_disable_lps_deep_mode);
 --- a/drivers/net/wireless/realtek/rtw88/rtw8821c.c
 +++ b/drivers/net/wireless/realtek/rtw88/rtw8821c.c
 @@ -14,6 +14,7 @@
diff --git a/patches/0028-select_queue/mac80211.patch b/patches/0028-select_queue/mac80211.patch
index 36738162..d4e39d5d 100644
--- a/patches/0028-select_queue/mac80211.patch
+++ b/patches/0028-select_queue/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/mac80211/iface.c
 +++ b/net/mac80211/iface.c
-@@ -695,9 +695,21 @@ static void ieee80211_uninit(struct net_
+@@ -691,9 +691,21 @@ static void ieee80211_uninit(struct net_
  	ieee80211_teardown_sdata(IEEE80211_DEV_TO_SUB_IF(dev));
  }
  
@@ -22,7 +22,7 @@
  {
  	return ieee80211_select_queue(IEEE80211_DEV_TO_SUB_IF(dev), skb);
  }
-@@ -719,9 +731,21 @@ static const struct net_device_ops ieee8
+@@ -715,9 +727,21 @@ static const struct net_device_ops ieee8
  	.ndo_get_stats64	= ieee80211_get_stats64,
  };
  
diff --git a/patches/0075-ndo-stats-64/usbnet.patch b/patches/0075-ndo-stats-64/usbnet.patch
deleted file mode 100644
index 8d60d3a9..00000000
--- a/patches/0075-ndo-stats-64/usbnet.patch
+++ /dev/null
@@ -1,24 +0,0 @@
---- a/drivers/net/usb/usbnet.c
-+++ b/drivers/net/usb/usbnet.c
-@@ -988,6 +988,9 @@ void usbnet_get_stats64(struct net_devic
- 	dev_fetch_sw_netstats(stats, dev->stats64);
- }
- EXPORT_SYMBOL_GPL(usbnet_get_stats64);
-+#if LINUX_VERSION_IS_LESS(4,11,0)
-+EXPORT_SYMBOL_GPL(bp_usbnet_get_stats64);
-+#endif
- 
- u32 usbnet_get_link (struct net_device *net)
- {
---- a/include/linux/usb/usbnet.h
-+++ b/include/linux/usb/usbnet.h
-@@ -289,5 +289,9 @@ extern void usbnet_status_stop(struct us
- extern void usbnet_update_max_qlen(struct usbnet *dev);
- extern void usbnet_get_stats64(struct net_device *dev,
- 			       struct rtnl_link_stats64 *stats);
-+#if LINUX_VERSION_IS_LESS(4,11,0)
-+struct rtnl_link_stats64 *
-+bp_usbnet_get_stats64(struct net_device *dev, struct rtnl_link_stats64 *stats);
-+#endif
- 
- #endif /* __LINUX_USB_USBNET_H */
diff --git a/patches/0077-genl-ro-after-init/hwsim.patch b/patches/0077-genl-ro-after-init/hwsim.patch
index e9ef9c92..a877f147 100644
--- a/patches/0077-genl-ro-after-init/hwsim.patch
+++ b/patches/0077-genl-ro-after-init/hwsim.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mac80211_hwsim.c
 +++ b/drivers/net/wireless/mac80211_hwsim.c
-@@ -4034,7 +4034,7 @@ static const struct genl_small_ops hwsim
+@@ -4001,7 +4001,7 @@ static const struct genl_small_ops hwsim
  	},
  };
  
diff --git a/patches/0077-genl-ro-after-init/nl80211.patch b/patches/0077-genl-ro-after-init/nl80211.patch
index 743d14e1..686f29a2 100644
--- a/patches/0077-genl-ro-after-init/nl80211.patch
+++ b/patches/0077-genl-ro-after-init/nl80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15525,7 +15525,7 @@ static const struct genl_small_ops nl802
+@@ -15710,7 +15710,7 @@ static const struct genl_small_ops nl802
  	},
  };
  
diff --git a/patches/0084-disable-some-staging-dirs.patch b/patches/0084-disable-some-staging-dirs.patch
index 9e550b3b..3852bc9b 100644
--- a/patches/0084-disable-some-staging-dirs.patch
+++ b/patches/0084-disable-some-staging-dirs.patch
@@ -9,9 +9,9 @@
  obj-$(CONFIG_PRISM2_USB)	+= wlan-ng/
  obj-$(CONFIG_COMEDI)		+= comedi/
  obj-$(CONFIG_FB_OLPC_DCON)	+= olpc_dcon/
-@@ -48,4 +48,4 @@ obj-$(CONFIG_FIELDBUS_DEV)     += fieldb
- obj-$(CONFIG_KPC2000)		+= kpc2000/
+@@ -46,4 +46,4 @@ obj-$(CONFIG_KPC2000)		+= kpc2000/
  obj-$(CONFIG_QLGE)		+= qlge/
+ obj-$(CONFIG_WIMAX)		+= wimax/
  obj-$(CONFIG_WFX)		+= wfx/
 -obj-y				+= hikey9xx/
 +#obj-y				+= hikey9xx/
diff --git a/patches/0092-listified-rx/iwlwifi.patch b/patches/0092-listified-rx/iwlwifi.patch
index 44ab1d64..8d7c216f 100644
--- a/patches/0092-listified-rx/iwlwifi.patch
+++ b/patches/0092-listified-rx/iwlwifi.patch
@@ -3,7 +3,7 @@ commit 323ebb61e32b ("net: use listified RX for handling GRO_NORMAL skbs")
 
 --- a/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
 +++ b/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
-@@ -1606,11 +1606,13 @@ out:
+@@ -1549,11 +1549,13 @@ out:
  	if (napi->poll) {
  		napi_gro_flush(napi, false);
  
diff --git a/patches/0094-ndo-tx-timeout/usbnet.patch b/patches/0094-ndo-tx-timeout/usbnet.patch
index 42b8fac5..2d0ef695 100644
--- a/patches/0094-ndo-tx-timeout/usbnet.patch
+++ b/patches/0094-ndo-tx-timeout/usbnet.patch
@@ -1,6 +1,6 @@
 --- a/include/linux/usb/usbnet.h
 +++ b/include/linux/usb/usbnet.h
-@@ -257,6 +257,7 @@ extern int usbnet_stop(struct net_device
+@@ -255,6 +255,7 @@ extern int usbnet_stop(struct net_device
  extern netdev_tx_t usbnet_start_xmit(struct sk_buff *skb,
  				     struct net_device *net);
  extern void usbnet_tx_timeout(struct net_device *net, unsigned int txqueue);
diff --git a/patches/0095-spi-delay/wilc1000.patch b/patches/0095-spi-delay/wilc1000.patch
index 6565c432..d4876f4b 100644
--- a/patches/0095-spi-delay/wilc1000.patch
+++ b/patches/0095-spi-delay/wilc1000.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/microchip/wilc1000/spi.c
 +++ b/drivers/net/wireless/microchip/wilc1000/spi.c
-@@ -160,10 +160,14 @@ static int wilc_spi_tx(struct wilc *wilc
+@@ -161,10 +161,14 @@ static int wilc_spi_tx(struct wilc *wilc
  		struct spi_transfer tr = {
  			.tx_buf = b,
  			.len = len,
@@ -15,7 +15,7 @@
  		};
  		char *r_buffer = kzalloc(len, GFP_KERNEL);
  
-@@ -204,10 +208,14 @@ static int wilc_spi_rx(struct wilc *wilc
+@@ -205,10 +209,14 @@ static int wilc_spi_rx(struct wilc *wilc
  		struct spi_transfer tr = {
  			.rx_buf = rb,
  			.len = rlen,
@@ -30,7 +30,7 @@
  
  		};
  		char *t_buffer = kzalloc(rlen, GFP_KERNEL);
-@@ -249,10 +257,14 @@ static int wilc_spi_tx_rx(struct wilc *w
+@@ -250,10 +258,14 @@ static int wilc_spi_tx_rx(struct wilc *w
  			.tx_buf = wb,
  			.len = rlen,
  			.bits_per_word = 8,
diff --git a/patches/0097-skb-list/mac80211-rx.patch b/patches/0097-skb-list/mac80211-rx.patch
index 53b8f0bf..88e66a95 100644
--- a/patches/0097-skb-list/mac80211-rx.patch
+++ b/patches/0097-skb-list/mac80211-rx.patch
@@ -9,7 +9,7 @@ the older kernel instead. The list attributes where also backported to
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -4450,7 +4450,11 @@ void ieee80211_restart_hw(struct ieee802
+@@ -4456,7 +4456,11 @@ void ieee80211_restart_hw(struct ieee802
   * @list: the destination list
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *sta,
@@ -23,7 +23,7 @@ the older kernel instead. The list attributes where also backported to
   * ieee80211_rx_napi - receive frame from NAPI context
 --- a/net/mac80211/ieee80211_i.h
 +++ b/net/mac80211/ieee80211_i.h
-@@ -199,7 +199,11 @@ enum ieee80211_rx_flags {
+@@ -217,7 +217,11 @@ enum ieee80211_rx_flags {
  };
  
  struct ieee80211_rx_data {
@@ -37,7 +37,7 @@ the older kernel instead. The list attributes where also backported to
  	struct ieee80211_sub_if_data *sdata;
 --- a/net/mac80211/rx.c
 +++ b/net/mac80211/rx.c
-@@ -2602,7 +2602,11 @@ static void ieee80211_deliver_skb_to_loc
+@@ -2528,7 +2528,11 @@ static void ieee80211_deliver_skb_to_loc
  
  		/* deliver to local stack */
  		if (rx->list)
@@ -49,7 +49,7 @@ the older kernel instead. The list attributes where also backported to
  		else
  			netif_receive_skb(skb);
  	}
-@@ -4542,7 +4546,11 @@ static bool ieee80211_invoke_fast_rx(str
+@@ -4446,7 +4450,11 @@ static bool ieee80211_invoke_fast_rx(str
  	skb->protocol = eth_type_trans(skb, fast_rx->dev);
  	memset(skb->cb, 0, sizeof(skb->cb));
  	if (rx->list)
@@ -61,7 +61,7 @@ the older kernel instead. The list attributes where also backported to
  	else
  		netif_receive_skb(skb);
  
-@@ -4609,7 +4617,11 @@ static bool ieee80211_prepare_and_rx_han
+@@ -4513,7 +4521,11 @@ static bool ieee80211_prepare_and_rx_han
  static void __ieee80211_rx_handle_packet(struct ieee80211_hw *hw,
  					 struct ieee80211_sta *pubsta,
  					 struct sk_buff *skb,
@@ -73,7 +73,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_sub_if_data *sdata;
-@@ -4734,7 +4746,11 @@ static void __ieee80211_rx_handle_packet
+@@ -4638,7 +4650,11 @@ static void __ieee80211_rx_handle_packet
   * 802.11 MPDU is received from the hardware.
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *pubsta,
@@ -85,7 +85,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_rate *rate = NULL;
-@@ -4851,7 +4867,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4757,7 +4773,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		       struct sk_buff *skb, struct napi_struct *napi)
  {
  	struct sk_buff *tmp;
@@ -99,7 +99,7 @@ the older kernel instead. The list attributes where also backported to
  
  
  	/*
-@@ -4868,8 +4890,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4774,8 +4796,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		return;
  	}
  
diff --git a/patches/0097-skb-list/mac80211-status.patch b/patches/0097-skb-list/mac80211-status.patch
index ab968445..ee90303c 100644
--- a/patches/0097-skb-list/mac80211-status.patch
+++ b/patches/0097-skb-list/mac80211-status.patch
@@ -7,7 +7,7 @@ kernel versions.
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -1132,7 +1132,11 @@ struct ieee80211_tx_status {
+@@ -1135,7 +1135,11 @@ struct ieee80211_tx_status {
  	struct ieee80211_tx_info *info;
  	struct sk_buff *skb;
  	struct rate_info *rate;
diff --git a/patches/0098-netdev_nested_priv/qtnfmac.patch b/patches/0098-netdev_nested_priv/qtnfmac.patch
index 7ff920c3..a177bed8 100644
--- a/patches/0098-netdev_nested_priv/qtnfmac.patch
+++ b/patches/0098-netdev_nested_priv/qtnfmac.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/quantenna/qtnfmac/core.c
 +++ b/drivers/net/wireless/quantenna/qtnfmac/core.c
-@@ -649,10 +649,16 @@ bool qtnf_netdev_is_qtn(const struct net
+@@ -643,10 +643,16 @@ bool qtnf_netdev_is_qtn(const struct net
  	return ndev->netdev_ops == &qtnf_netdev_ops;
  }
  
@@ -17,7 +17,7 @@
  
  	if (dev != ndev && netdev_port_same_parent_id(dev, ndev))
  		return -ENOTSUPP;
-@@ -665,9 +671,11 @@ static int qtnf_core_netdevice_event(str
+@@ -659,9 +665,11 @@ static int qtnf_core_netdevice_event(str
  {
  	struct net_device *ndev = netdev_notifier_info_to_dev(ptr);
  	const struct netdev_notifier_changeupper_info *info;
@@ -29,7 +29,7 @@
  	struct net_device *brdev;
  	struct qtnf_vif *vif;
  	struct qtnf_bus *bus;
-@@ -707,7 +715,11 @@ static int qtnf_core_netdevice_event(str
+@@ -701,7 +709,11 @@ static int qtnf_core_netdevice_event(str
  		} else {
  			ret = netdev_walk_all_lower_dev(brdev,
  							qtnf_check_br_ports,
diff --git a/patches/0099-netlink-range/mac80211.patch b/patches/0099-netlink-range/mac80211.patch
index 1490baf0..180b6082 100644
--- a/patches/0099-netlink-range/mac80211.patch
+++ b/patches/0099-netlink-range/mac80211.patch
@@ -12,7 +12,7 @@
  };
  
  static const struct nla_policy
-@@ -621,16 +623,26 @@ static const struct nla_policy nl80211_p
+@@ -633,16 +635,26 @@ static const struct nla_policy nl80211_p
  	 * The value of the Length field of the Supported Operating
  	 * Classes element is between 2 and 253.
  	 */
@@ -39,7 +39,7 @@
  	[NL80211_ATTR_MAC_HINT] = NLA_POLICY_EXACT_LEN_WARN(ETH_ALEN),
  	[NL80211_ATTR_WIPHY_FREQ_HINT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TDLS_PEER_CAPABILITY] = { .type = NLA_U32 },
-@@ -685,10 +697,15 @@ static const struct nla_policy nl80211_p
+@@ -697,10 +709,15 @@ static const struct nla_policy nl80211_p
  	[NL80211_ATTR_TXQ_LIMIT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TXQ_MEMORY_LIMIT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TXQ_QUANTUM] = { .type = NLA_U32 },
diff --git a/patches/0100-revert-small_ops/mac80211.patch b/patches/0100-revert-small_ops/mac80211.patch
index 37c2fcff..fe89977b 100644
--- a/patches/0100-revert-small_ops/mac80211.patch
+++ b/patches/0100-revert-small_ops/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -14690,9 +14690,11 @@ static const struct genl_ops nl80211_ops
+@@ -14875,9 +14875,11 @@ static const struct genl_ops nl80211_ops
  		.internal_flags = NL80211_FLAG_NEED_WIPHY |
  				  NL80211_FLAG_NEED_RTNL,
  	},
@@ -12,7 +12,7 @@
  	{
  		.cmd = NL80211_CMD_SET_WIPHY,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -15554,8 +15556,10 @@ static struct genl_family nl80211_fam __
+@@ -15739,8 +15741,10 @@ static struct genl_family nl80211_fam __
  	.module = THIS_MODULE,
  	.ops = nl80211_ops,
  	.n_ops = ARRAY_SIZE(nl80211_ops),
diff --git a/patches/0100-revert-small_ops/mac80211_hwsim.patch b/patches/0100-revert-small_ops/mac80211_hwsim.patch
index 42e52308..1a764336 100644
--- a/patches/0100-revert-small_ops/mac80211_hwsim.patch
+++ b/patches/0100-revert-small_ops/mac80211_hwsim.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mac80211_hwsim.c
 +++ b/drivers/net/wireless/mac80211_hwsim.c
-@@ -3997,7 +3997,11 @@ done:
+@@ -3964,7 +3964,11 @@ done:
  }
  
  /* Generic Netlink operations array */
@@ -12,7 +12,7 @@
  	{
  		.cmd = HWSIM_CMD_REGISTER,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -4041,8 +4045,13 @@ static struct genl_family hwsim_genl_fam
+@@ -4008,8 +4012,13 @@ static struct genl_family hwsim_genl_fam
  	.policy = hwsim_genl_policy,
  	.netnsok = true,
  	.module = THIS_MODULE,
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 02/47] backports: Add dev_get_tstats64() and bp_dev_get_tstats64()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 01/47] patches: Refresh on kernel 5.11.22 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 03/47] backports: Add empty implementation for skb_get_kcov_handle() Hauke Mehrtens
                   ` (45 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

dev_get_tstats64() was added as a generic function for .ndo_get_stats64.
The signature of this callback function changed with kernel 4.11, add
the bp_dev_get_tstats64() function on such older kernel version.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/netdevice.h | 10 ++++++++++
 backport/compat/Makefile                    |  2 ++
 backport/compat/backport-4.11.c             | 12 ++++++++++++
 backport/compat/backport-5.11.c             | 19 +++++++++++++++++++
 4 files changed, 43 insertions(+)
 create mode 100644 backport/compat/backport-4.11.c
 create mode 100644 backport/compat/backport-5.11.c

diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h
index e9c07a91..d854faef 100644
--- a/backport/backport-include/linux/netdevice.h
+++ b/backport/backport-include/linux/netdevice.h
@@ -113,4 +113,14 @@ void dev_fetch_sw_netstats(struct rtnl_link_stats64 *s,
 int netif_rx_any_context(struct sk_buff *skb);
 #endif /* < 5.10 */
 
+#if LINUX_VERSION_IS_LESS(5,11,0)
+#define dev_get_tstats64 LINUX_BACKPORT(dev_get_tstats64)
+void dev_get_tstats64(struct net_device *dev, struct rtnl_link_stats64 *s);
+#endif /* < 5.11 */
+
+#if LINUX_VERSION_IS_LESS(4,11,0)
+struct rtnl_link_stats64 *
+bp_dev_get_tstats64(struct net_device *dev, struct rtnl_link_stats64 *s);
+#endif /* < 4.11 */
+
 #endif /* __BACKPORT_NETDEVICE_H */
diff --git a/backport/compat/Makefile b/backport/compat/Makefile
index bbedd49c..e927a0c8 100644
--- a/backport/compat/Makefile
+++ b/backport/compat/Makefile
@@ -12,11 +12,13 @@ compat-$(CPTCFG_KERNEL_4_6) += backport-4.6.o
 compat-$(CPTCFG_KERNEL_4_7) += backport-4.7.o
 compat-$(CPTCFG_KERNEL_4_8) += backport-4.8.o
 compat-$(CPTCFG_KERNEL_4_10) += backport-4.10.o
+compat-$(CPTCFG_KERNEL_4_11) += backport-4.11.o
 compat-$(CPTCFG_KERNEL_4_18) += backport-4.18.o
 compat-$(CPTCFG_KERNEL_5_2) += backport-5.2.o backport-genetlink.o
 compat-$(CPTCFG_KERNEL_5_3) += backport-5.3.o
 compat-$(CPTCFG_KERNEL_5_5) += backport-5.5.o
 compat-$(CPTCFG_KERNEL_5_10) += backport-5.10.o
+compat-$(CPTCFG_KERNEL_5_11) += backport-5.11.o
 
 compat-$(CPTCFG_BPAUTO_BUILD_SYSTEM_DATA_VERIFICATION) += verification/verify.o
 compat-$(CPTCFG_BPAUTO_BUILD_SYSTEM_DATA_VERIFICATION) += verification/pkcs7.asn1.o
diff --git a/backport/compat/backport-4.11.c b/backport/compat/backport-4.11.c
new file mode 100644
index 00000000..83445856
--- /dev/null
+++ b/backport/compat/backport-4.11.c
@@ -0,0 +1,12 @@
+// SPDX-License-Identifier: GPL-2.0
+
+#include <linux/export.h>
+#include <linux/netdevice.h>
+
+struct rtnl_link_stats64 *
+bp_dev_get_tstats64(struct net_device *dev, struct rtnl_link_stats64 *s)
+{
+	dev_get_tstats64(dev, s);
+	return s;
+}
+EXPORT_SYMBOL_GPL(bp_dev_get_tstats64);
diff --git a/backport/compat/backport-5.11.c b/backport/compat/backport-5.11.c
new file mode 100644
index 00000000..e60f35cf
--- /dev/null
+++ b/backport/compat/backport-5.11.c
@@ -0,0 +1,19 @@
+// SPDX-License-Identifier: GPL-2.0
+
+#include <linux/export.h>
+#include <linux/netdevice.h>
+
+/**
+ *	dev_get_tstats64 - ndo_get_stats64 implementation
+ *	@dev: device to get statistics from
+ *	@s: place to store stats
+ *
+ *	Populate @s from dev->stats and dev->tstats. Can be used as
+ *	ndo_get_stats64() callback.
+ */
+void dev_get_tstats64(struct net_device *dev, struct rtnl_link_stats64 *s)
+{
+	netdev_stats_to_stats64(s, &dev->stats);
+	dev_fetch_sw_netstats(s, dev->tstats);
+}
+EXPORT_SYMBOL_GPL(dev_get_tstats64);
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 03/47] backports: Add empty implementation for skb_get_kcov_handle()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 01/47] patches: Refresh on kernel 5.11.22 Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 02/47] backports: Add dev_get_tstats64() and bp_dev_get_tstats64() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 04/47] backports: Add linux/math.h Hauke Mehrtens
                   ` (44 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

In kernel >= 5.11 skb_get_kcov_handle() returns skb->kcov_handle when
CONFIG_KCOV is set and otherwise 0. It should even be fine when
CONFIG_KCOV is set on older kernels to return 0 here, kcov will not work
as good as on recent kernels, but it should work ok.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/skbuff.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/backport/backport-include/linux/skbuff.h b/backport/backport-include/linux/skbuff.h
index 6b02c857..1fd25fcd 100644
--- a/backport/backport-include/linux/skbuff.h
+++ b/backport/backport-include/linux/skbuff.h
@@ -122,4 +122,12 @@ static inline __u32 skb_queue_len_lockless(const struct sk_buff_head *list_)
 }
 #endif /* < 5.6.0 */
 
+#if LINUX_VERSION_IS_LESS(5,11,0)
+#define skb_get_kcov_handle LINUX_BACKPORT(skb_get_kcov_handle)
+static inline u64 skb_get_kcov_handle(struct sk_buff *skb)
+{
+	return 0;
+}
+#endif
+
 #endif /* __BACKPORT_SKBUFF_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 04/47] backports: Add linux/math.h
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (2 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 03/47] backports: Add empty implementation for skb_get_kcov_handle() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 05/47] backports: Add dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add() Hauke Mehrtens
                   ` (43 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This header file was added to the kernel, by extracting some functions
from linux/kernel.h. Add an empty version which itself includes
linux/kernel.h This way it will provide the same data also on older
kernel versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/math.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 backport/backport-include/linux/math.h

diff --git a/backport/backport-include/linux/math.h b/backport/backport-include/linux/math.h
new file mode 100644
index 00000000..10225a9d
--- /dev/null
+++ b/backport/backport-include/linux/math.h
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef __BACKPORTS_LINUX_MATH_H
+#define __BACKPORTS_LINUX_MATH_H
+#include <linux/version.h>
+
+#if LINUX_VERSION_IS_GEQ(5,11,0)
+#include_next <linux/math.h>
+#else
+#include <linux/kernel.h>
+#endif
+
+#endif /* __BACKPORTS_LINUX_MATH_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 05/47] backports: Add dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (3 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 04/47] backports: Add linux/math.h Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 06/47] headers: Add linux/kcov.h Hauke Mehrtens
                   ` (42 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Copy dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add() from the
upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/netdevice.h | 28 +++++++++++++++++++++
 1 file changed, 28 insertions(+)

diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h
index d854faef..5c30426d 100644
--- a/backport/backport-include/linux/netdevice.h
+++ b/backport/backport-include/linux/netdevice.h
@@ -113,6 +113,34 @@ void dev_fetch_sw_netstats(struct rtnl_link_stats64 *s,
 int netif_rx_any_context(struct sk_buff *skb);
 #endif /* < 5.10 */
 
+#if LINUX_VERSION_IS_LESS(5,10,0)
+#define dev_sw_netstats_rx_add LINUX_BACKPORT(dev_sw_netstats_rx_add)
+static inline void dev_sw_netstats_rx_add(struct net_device *dev, unsigned int len)
+{
+	struct pcpu_sw_netstats *tstats = this_cpu_ptr(dev->tstats);
+
+	u64_stats_update_begin(&tstats->syncp);
+	tstats->rx_bytes += len;
+	tstats->rx_packets++;
+	u64_stats_update_end(&tstats->syncp);
+}
+#endif /* < 5.10 */
+
+#if LINUX_VERSION_IS_LESS(5,11,0)
+#define dev_sw_netstats_tx_add LINUX_BACKPORT(dev_sw_netstats_tx_add)
+static inline void dev_sw_netstats_tx_add(struct net_device *dev,
+					  unsigned int packets,
+					  unsigned int len)
+{
+	struct pcpu_sw_netstats *tstats = this_cpu_ptr(dev->tstats);
+
+	u64_stats_update_begin(&tstats->syncp);
+	tstats->tx_bytes += len;
+	tstats->tx_packets += packets;
+	u64_stats_update_end(&tstats->syncp);
+}
+#endif /* < 5.11 */
+
 #if LINUX_VERSION_IS_LESS(5,11,0)
 #define dev_get_tstats64 LINUX_BACKPORT(dev_get_tstats64)
 void dev_get_tstats64(struct net_device *dev, struct rtnl_link_stats64 *s);
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 06/47] headers: Add linux/kcov.h
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (4 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 05/47] backports: Add dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 07/47] patches: Do not use rx_list in mt76 on older kernel versions Hauke Mehrtens
                   ` (41 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This adds empty implementation for kcov_remote_start_common() and
kcov_remote_stop() on older kernel versions. kcov will probably not work
properly when used with backports and older kernel versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/kcov.h  | 16 ++++++++++++++++
 backport/backport-include/linux/sched.h |  5 +++++
 2 files changed, 21 insertions(+)
 create mode 100644 backport/backport-include/linux/kcov.h

diff --git a/backport/backport-include/linux/kcov.h b/backport/backport-include/linux/kcov.h
new file mode 100644
index 00000000..92095e63
--- /dev/null
+++ b/backport/backport-include/linux/kcov.h
@@ -0,0 +1,16 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef __BACKPORTS_LINUX_KCOV_H
+#define __BACKPORTS_LINUX_KCOV_H
+#include <linux/version.h>
+#if LINUX_VERSION_IS_GEQ(4,6,0)
+#include_next <linux/kcov.h>
+#endif
+
+#if LINUX_VERSION_IS_LESS(5,5,0)
+#define kcov_remote_stop LINUX_BACKPORT(kcov_remote_stop)
+static inline void kcov_remote_stop(void) {}
+#define kcov_remote_start_common LINUX_BACKPORT(kcov_remote_start_common)
+static inline void kcov_remote_start_common(u64 id) {}
+#endif
+
+#endif /* __BACKPORTS_LINUX_KCOV_H */
diff --git a/backport/backport-include/linux/sched.h b/backport/backport-include/linux/sched.h
index 36263857..6a5cf8db 100644
--- a/backport/backport-include/linux/sched.h
+++ b/backport/backport-include/linux/sched.h
@@ -4,6 +4,11 @@
 #include_next <linux/sched.h>
 #include <linux/version.h>
 
+/* kcov was added in 4.6 and is included since then */
+#if LINUX_VERSION_IS_LESS(4,6,0)
+#include <linux/kcov.h>
+#endif
+
 #if LINUX_VERSION_IS_LESS(5,9,0)
 #if LINUX_VERSION_IS_GEQ(4,11,0)
 #include <uapi/linux/sched/types.h>
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 07/47] patches: Do not use rx_list in mt76 on older kernel versions.
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (5 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 06/47] headers: Add linux/kcov.h Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 08/47] dependencies: Build mt7915 only on kernel >= 4.6 Hauke Mehrtens
                   ` (40 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Use the sk_buff_head instead of the skb->rx_list on older kernel in mt76
too.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0097-skb-list/mt76.patch | 76 ++++++++++++++++++++++++++++++++
 1 file changed, 76 insertions(+)
 create mode 100644 patches/0097-skb-list/mt76.patch

diff --git a/patches/0097-skb-list/mt76.patch b/patches/0097-skb-list/mt76.patch
new file mode 100644
index 00000000..c63b151d
--- /dev/null
+++ b/patches/0097-skb-list/mt76.patch
@@ -0,0 +1,76 @@
+--- a/drivers/net/wireless/mediatek/mt76/mac80211.c
++++ b/drivers/net/wireless/mediatek/mt76/mac80211.c
+@@ -922,7 +922,13 @@ void mt76_rx_complete(struct mt76_dev *d
+ 	struct ieee80211_sta *sta;
+ 	struct ieee80211_hw *hw;
+ 	struct sk_buff *skb, *tmp;
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 	LIST_HEAD(list);
++#else
++	struct sk_buff_head list;
++
++	__skb_queue_head_init(&list);
++#endif
+ 
+ 	spin_lock(&dev->rx_lock);
+ 	while ((skb = __skb_dequeue(frames)) != NULL) {
+@@ -941,8 +947,13 @@ void mt76_rx_complete(struct mt76_dev *d
+ 		return;
+ 	}
+ 
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 	list_for_each_entry_safe(skb, tmp, &list, list) {
+ 		skb_list_del_init(skb);
++#else
++	skb_queue_walk_safe(&list, skb, tmp) {
++		__skb_unlink(skb, &list);
++#endif
+ 		napi_gro_receive(napi, skb);
+ 	}
+ }
+--- a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
++++ b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
+@@ -1030,7 +1030,11 @@ mt7915_tx_check_aggr(struct ieee80211_st
+ static void
+ mt7915_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
+ 			  struct ieee80211_sta *sta, u8 stat,
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 			  struct list_head *free_list)
++#else
++			  struct sk_buff_head *free_list)
++#endif
+ {
+ 	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
+ 	struct ieee80211_tx_status status = {
+@@ -1094,10 +1098,16 @@ void mt7915_mac_tx_free(struct mt7915_de
+ 	struct mt76_phy *mphy_ext = mdev->phy2;
+ 	struct mt76_txwi_cache *txwi;
+ 	struct ieee80211_sta *sta = NULL;
+-	LIST_HEAD(free_list);
+ 	struct sk_buff *tmp;
+ 	u8 i, count;
+ 	bool wake = false;
++#if LINUX_VERSION_IS_GEQ(4,19,0)
++	LIST_HEAD(free_list);
++#else
++	struct sk_buff_head free_list;
++
++	__skb_queue_head_init(&free_list);
++#endif
+ 
+ 	/* clean DMA queues and unmap buffers first */
+ 	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
+@@ -1196,8 +1206,13 @@ void mt7915_mac_tx_free(struct mt7915_de
+ 
+ 	napi_consume_skb(skb, 1);
+ 
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 	list_for_each_entry_safe(skb, tmp, &free_list, list) {
+ 		skb_list_del_init(skb);
++#else
++	skb_queue_walk_safe(&free_list, skb, tmp) {
++		__skb_unlink(skb, &free_list);
++#endif
+ 		napi_consume_skb(skb, 1);
+ 	}
+ }
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 08/47] dependencies: Build mt7915 only on kernel >= 4.6
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (6 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 07/47] patches: Do not use rx_list in mt76 on older kernel versions Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 09/47] patches: Remove const from struct rchan_callbacks Hauke Mehrtens
                   ` (39 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

mt7915 uses napi_consume_skb() which is not available on older kernel
versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 dependencies | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dependencies b/dependencies
index fed4a3b8..39076904 100644
--- a/dependencies
+++ b/dependencies
@@ -24,6 +24,9 @@ USB_NET_RNDIS_WLAN 4.6
 # For Coexsitence the BT driver has to export rsi_bt_ops
 RSI_COEX 4.17
 
+# needs napi_consume_skb()
+MT7915E 4.6
+
 # depends on crypto_sync_skcipher()
 AIRO 4.20
 AIRO_CS 4.20
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 09/47] patches: Remove const from struct rchan_callbacks
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (7 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 08/47] dependencies: Build mt7915 only on kernel >= 4.6 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 10/47] patches: Refresh patches on top of kernel 5.12.19 Hauke Mehrtens
                   ` (38 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The struct rchan_callbacks parameter to the relay_open function was
changed to const in kernel 5.11 and the drivers were adapted. On older
kernel versions the struct rchan_callbacks should not be costs.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 ...05-remove-const-from-rchan_callbacks.patch | 42 +++++++++++++++++++
 1 file changed, 42 insertions(+)
 create mode 100644 patches/0105-remove-const-from-rchan_callbacks.patch

diff --git a/patches/0105-remove-const-from-rchan_callbacks.patch b/patches/0105-remove-const-from-rchan_callbacks.patch
new file mode 100644
index 00000000..16c14707
--- /dev/null
+++ b/patches/0105-remove-const-from-rchan_callbacks.patch
@@ -0,0 +1,42 @@
+--- a/drivers/net/wireless/ath/ath10k/spectral.c
++++ b/drivers/net/wireless/ath/ath10k/spectral.c
+@@ -497,7 +497,11 @@ static int remove_buf_file_handler(struc
+ 	return 0;
+ }
+ 
++#if LINUX_VERSION_IS_GEQ(5,11,0)
+ static const struct rchan_callbacks rfs_spec_scan_cb = {
++#else
++static struct rchan_callbacks rfs_spec_scan_cb = {
++#endif
+ 	.create_buf_file = create_buf_file_handler,
+ 	.remove_buf_file = remove_buf_file_handler,
+ };
+--- a/drivers/net/wireless/ath/ath11k/spectral.c
++++ b/drivers/net/wireless/ath/ath11k/spectral.c
+@@ -148,7 +148,11 @@ static int remove_buf_file_handler(struc
+ 	return 0;
+ }
+ 
++#if LINUX_VERSION_IS_GEQ(5,11,0)
+ static const struct rchan_callbacks rfs_scan_cb = {
++#else
++static struct rchan_callbacks rfs_scan_cb = {
++#endif
+ 	.create_buf_file = create_buf_file_handler,
+ 	.remove_buf_file = remove_buf_file_handler,
+ };
+--- a/drivers/net/wireless/ath/ath9k/common-spectral.c
++++ b/drivers/net/wireless/ath/ath9k/common-spectral.c
+@@ -1053,7 +1053,11 @@ static int remove_buf_file_handler(struc
+ 	return 0;
+ }
+ 
++#if LINUX_VERSION_IS_GEQ(5,11,0)
+ static const struct rchan_callbacks rfs_spec_scan_cb = {
++#else
++static struct rchan_callbacks rfs_spec_scan_cb = {
++#endif
+ 	.create_buf_file = create_buf_file_handler,
+ 	.remove_buf_file = remove_buf_file_handler,
+ };
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 10/47] patches: Refresh patches on top of kernel 5.12.19
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (8 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 09/47] patches: Remove const from struct rchan_callbacks Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 11/47] patches: include linux/modules.h in mt76/mt76_connac_mcu.c Hauke Mehrtens
                   ` (37 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

* iwlwifi does not use napi->rx_list any more, not need to remove this
  in a patch.
* __ieee80211_rx_handle_8023() was added and gets a skb list, extend the
  existing patch
* The crypto/akcipher.h include was already removed in the upstream
  kernel from include/crypto/backport-public_key.h

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 .../include_net_cfg80211.patch                |  4 +--
 .../net_wireless_core.patch                   |  2 +-
 .../net_wireless_core.patch                   |  4 +--
 .../0013-fix-makefile-includes/rtw88.patch    |  4 +--
 patches/0028-select_queue/mac80211.patch      |  4 +--
 patches/0028-select_queue/mwifiex.patch       |  2 +-
 patches/0077-genl-ro-after-init/hwsim.patch   |  2 +-
 patches/0077-genl-ro-after-init/nl80211.patch |  2 +-
 patches/0079-netdev-destructor/brcmfmac.patch |  2 +-
 patches/0092-listified-rx/iwlwifi.patch       | 19 -------------
 patches/0097-skb-list/mac80211-rx.patch       | 28 +++++++++++++------
 patches/0097-skb-list/mac80211-status.patch   |  4 +--
 patches/0097-skb-list/mt76.patch              |  6 ++--
 patches/0098-netdev_nested_priv/qtnfmac.patch |  6 ++--
 patches/0099-netlink-range/mac80211.patch     |  6 ++--
 patches/0100-revert-small_ops/mac80211.patch  |  8 +++---
 .../mac80211_hwsim.patch                      |  4 +--
 patches/verify.patch                          | 10 +------
 18 files changed, 51 insertions(+), 66 deletions(-)
 delete mode 100644 patches/0092-listified-rx/iwlwifi.patch

diff --git a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
index fd465b15..580ab9b9 100644
--- a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
+++ b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
@@ -1,7 +1,7 @@
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -4936,6 +4936,9 @@ struct wiphy_iftype_akm_suites {
- struct wiphy {
+@@ -4947,6 +4947,9 @@ struct wiphy {
+ 
  	/* assign these fields before you register the wiphy */
  
 +#define WIPHY_COMPAT_PAD_SIZE	2048
diff --git a/patches/0003-cfg80211-wext-padding/net_wireless_core.patch b/patches/0003-cfg80211-wext-padding/net_wireless_core.patch
index 3d73e463..f175b1bc 100644
--- a/patches/0003-cfg80211-wext-padding/net_wireless_core.patch
+++ b/patches/0003-cfg80211-wext-padding/net_wireless_core.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/core.c
 +++ b/net/wireless/core.c
-@@ -405,6 +405,17 @@ struct wiphy *wiphy_new_nm(const struct
+@@ -427,6 +427,17 @@ struct wiphy *wiphy_new_nm(const struct
  	struct cfg80211_registered_device *rdev;
  	int alloc_size;
  
diff --git a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
index 42a11a09..8bd7c4f5 100644
--- a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
+++ b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/core.c
 +++ b/net/wireless/core.c
-@@ -495,10 +495,6 @@ use_default_name:
+@@ -518,10 +518,6 @@ use_default_name:
  	INIT_WORK(&rdev->scan_done_wk, __cfg80211_scan_done);
  	INIT_DELAYED_WORK(&rdev->dfs_update_channels_wk,
  			  cfg80211_dfs_channels_update_work);
@@ -11,7 +11,7 @@
  	device_initialize(&rdev->wiphy.dev);
  	rdev->wiphy.dev.class = &ieee80211_class;
  	rdev->wiphy.dev.platform_data = rdev;
-@@ -1267,6 +1263,10 @@ void cfg80211_init_wdev(struct wireless_
+@@ -1311,6 +1307,10 @@ void cfg80211_init_wdev(struct wireless_
  	INIT_WORK(&wdev->pmsr_free_wk, cfg80211_pmsr_free_wk);
  
  #ifdef CONFIG_CFG80211_WEXT
diff --git a/patches/0013-fix-makefile-includes/rtw88.patch b/patches/0013-fix-makefile-includes/rtw88.patch
index a81a0542..e66439d9 100644
--- a/patches/0013-fix-makefile-includes/rtw88.patch
+++ b/patches/0013-fix-makefile-includes/rtw88.patch
@@ -18,5 +18,5 @@ linux/module.h include needed for kernel 3.18
  #include "bf.h"
 +#include <linux/module.h>
  
- static void rtw8821ce_efuse_parsing(struct rtw_efuse *efuse,
- 				    struct rtw8821c_efuse *map)
+ static const s8 lna_gain_table_0[8] = {22, 8, -6, -22, -31, -40, -46, -52};
+ static const s8 lna_gain_table_1[16] = {10, 6, 2, -2, -6, -10, -14, -17,
diff --git a/patches/0028-select_queue/mac80211.patch b/patches/0028-select_queue/mac80211.patch
index d4e39d5d..c92dc0e0 100644
--- a/patches/0028-select_queue/mac80211.patch
+++ b/patches/0028-select_queue/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/mac80211/iface.c
 +++ b/net/mac80211/iface.c
-@@ -691,9 +691,21 @@ static void ieee80211_uninit(struct net_
+@@ -694,9 +694,21 @@ static void ieee80211_uninit(struct net_
  	ieee80211_teardown_sdata(IEEE80211_DEV_TO_SUB_IF(dev));
  }
  
@@ -22,7 +22,7 @@
  {
  	return ieee80211_select_queue(IEEE80211_DEV_TO_SUB_IF(dev), skb);
  }
-@@ -715,9 +727,21 @@ static const struct net_device_ops ieee8
+@@ -718,9 +730,21 @@ static const struct net_device_ops ieee8
  	.ndo_get_stats64	= ieee80211_get_stats64,
  };
  
diff --git a/patches/0028-select_queue/mwifiex.patch b/patches/0028-select_queue/mwifiex.patch
index 24d146ed..464332a9 100644
--- a/patches/0028-select_queue/mwifiex.patch
+++ b/patches/0028-select_queue/mwifiex.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/marvell/mwifiex/main.c
 +++ b/drivers/net/wireless/marvell/mwifiex/main.c
-@@ -1279,9 +1279,20 @@ static struct net_device_stats *mwifiex_
+@@ -1284,9 +1284,20 @@ static struct net_device_stats *mwifiex_
  	return &priv->stats;
  }
  
diff --git a/patches/0077-genl-ro-after-init/hwsim.patch b/patches/0077-genl-ro-after-init/hwsim.patch
index a877f147..189b1822 100644
--- a/patches/0077-genl-ro-after-init/hwsim.patch
+++ b/patches/0077-genl-ro-after-init/hwsim.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mac80211_hwsim.c
 +++ b/drivers/net/wireless/mac80211_hwsim.c
-@@ -4001,7 +4001,7 @@ static const struct genl_small_ops hwsim
+@@ -4106,7 +4106,7 @@ static const struct genl_small_ops hwsim
  	},
  };
  
diff --git a/patches/0077-genl-ro-after-init/nl80211.patch b/patches/0077-genl-ro-after-init/nl80211.patch
index 686f29a2..69f9b075 100644
--- a/patches/0077-genl-ro-after-init/nl80211.patch
+++ b/patches/0077-genl-ro-after-init/nl80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15710,7 +15710,7 @@ static const struct genl_small_ops nl802
+@@ -15793,7 +15793,7 @@ static const struct genl_small_ops nl802
  	},
  };
  
diff --git a/patches/0079-netdev-destructor/brcmfmac.patch b/patches/0079-netdev-destructor/brcmfmac.patch
index 830f16cf..33e12792 100644
--- a/patches/0079-netdev-destructor/brcmfmac.patch
+++ b/patches/0079-netdev-destructor/brcmfmac.patch
@@ -21,7 +21,7 @@
 +}
 +#endif
 +
- int brcmf_net_attach(struct brcmf_if *ifp, bool rtnl_locked)
+ int brcmf_net_attach(struct brcmf_if *ifp, bool locked)
  {
  	struct brcmf_pub *drvr = ifp->drvr;
 @@ -883,7 +900,11 @@ struct brcmf_if *brcmf_add_if(struct brc
diff --git a/patches/0092-listified-rx/iwlwifi.patch b/patches/0092-listified-rx/iwlwifi.patch
deleted file mode 100644
index 8d7c216f..00000000
--- a/patches/0092-listified-rx/iwlwifi.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-The rx_count and rx_list attributes were only added in kernel 5.4 in
-commit 323ebb61e32b ("net: use listified RX for handling GRO_NORMAL skbs")
-
---- a/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
-+++ b/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
-@@ -1549,11 +1549,13 @@ out:
- 	if (napi->poll) {
- 		napi_gro_flush(napi, false);
- 
-+#if LINUX_VERSION_IS_GEQ(5,4,0)
- 		if (napi->rx_count) {
- 			netif_receive_skb_list(&napi->rx_list);
- 			INIT_LIST_HEAD(&napi->rx_list);
- 			napi->rx_count = 0;
- 		}
-+#endif
- 	}
- 
- 	iwl_pcie_rxq_restock(trans, rxq);
diff --git a/patches/0097-skb-list/mac80211-rx.patch b/patches/0097-skb-list/mac80211-rx.patch
index 88e66a95..e2be9ddd 100644
--- a/patches/0097-skb-list/mac80211-rx.patch
+++ b/patches/0097-skb-list/mac80211-rx.patch
@@ -9,7 +9,7 @@ the older kernel instead. The list attributes where also backported to
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -4456,7 +4456,11 @@ void ieee80211_restart_hw(struct ieee802
+@@ -4472,7 +4472,11 @@ void ieee80211_restart_hw(struct ieee802
   * @list: the destination list
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *sta,
@@ -23,7 +23,7 @@ the older kernel instead. The list attributes where also backported to
   * ieee80211_rx_napi - receive frame from NAPI context
 --- a/net/mac80211/ieee80211_i.h
 +++ b/net/mac80211/ieee80211_i.h
-@@ -217,7 +217,11 @@ enum ieee80211_rx_flags {
+@@ -199,7 +199,11 @@ enum ieee80211_rx_flags {
  };
  
  struct ieee80211_rx_data {
@@ -37,7 +37,7 @@ the older kernel instead. The list attributes where also backported to
  	struct ieee80211_sub_if_data *sdata;
 --- a/net/mac80211/rx.c
 +++ b/net/mac80211/rx.c
-@@ -2528,7 +2528,11 @@ static void ieee80211_deliver_skb_to_loc
+@@ -2591,7 +2591,11 @@ static void ieee80211_deliver_skb_to_loc
  
  		/* deliver to local stack */
  		if (rx->list)
@@ -49,7 +49,7 @@ the older kernel instead. The list attributes where also backported to
  		else
  			netif_receive_skb(skb);
  	}
-@@ -4446,7 +4450,11 @@ static bool ieee80211_invoke_fast_rx(str
+@@ -4440,7 +4444,11 @@ static void ieee80211_rx_8023(struct iee
  	skb->protocol = eth_type_trans(skb, fast_rx->dev);
  	memset(skb->cb, 0, sizeof(skb->cb));
  	if (rx->list)
@@ -61,7 +61,19 @@ the older kernel instead. The list attributes where also backported to
  	else
  		netif_receive_skb(skb);
  
-@@ -4513,7 +4521,11 @@ static bool ieee80211_prepare_and_rx_han
+@@ -4622,7 +4630,11 @@ static bool ieee80211_prepare_and_rx_han
+ static void __ieee80211_rx_handle_8023(struct ieee80211_hw *hw,
+ 				       struct ieee80211_sta *pubsta,
+ 				       struct sk_buff *skb,
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 				       struct list_head *list)
++#else
++				       struct sk_buff_head *list)
++#endif
+ {
+ 	struct ieee80211_local *local = hw_to_local(hw);
+ 	struct ieee80211_fast_rx *fast_rx;
+@@ -4663,7 +4675,11 @@ drop:
  static void __ieee80211_rx_handle_packet(struct ieee80211_hw *hw,
  					 struct ieee80211_sta *pubsta,
  					 struct sk_buff *skb,
@@ -73,7 +85,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_sub_if_data *sdata;
-@@ -4638,7 +4650,11 @@ static void __ieee80211_rx_handle_packet
+@@ -4788,7 +4804,11 @@ static void __ieee80211_rx_handle_packet
   * 802.11 MPDU is received from the hardware.
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *pubsta,
@@ -85,7 +97,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_rate *rate = NULL;
-@@ -4757,7 +4773,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4911,7 +4931,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		       struct sk_buff *skb, struct napi_struct *napi)
  {
  	struct sk_buff *tmp;
@@ -99,7 +111,7 @@ the older kernel instead. The list attributes where also backported to
  
  
  	/*
-@@ -4774,8 +4796,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4928,8 +4954,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		return;
  	}
  
diff --git a/patches/0097-skb-list/mac80211-status.patch b/patches/0097-skb-list/mac80211-status.patch
index ee90303c..8f5ac983 100644
--- a/patches/0097-skb-list/mac80211-status.patch
+++ b/patches/0097-skb-list/mac80211-status.patch
@@ -21,7 +21,7 @@ kernel versions.
  /**
 --- a/net/mac80211/status.c
 +++ b/net/mac80211/status.c
-@@ -1033,7 +1033,11 @@ static void __ieee80211_tx_status(struct
+@@ -1029,7 +1029,11 @@ static void __ieee80211_tx_status(struct
  	 */
  	if (!local->monitors && (!send_to_cooked || !local->cooked_mntrs)) {
  		if (status->free_list)
@@ -33,7 +33,7 @@ kernel versions.
  		else
  			dev_kfree_skb(skb);
  		return;
-@@ -1183,7 +1187,11 @@ free:
+@@ -1179,7 +1183,11 @@ free:
  
  	ieee80211_report_used_skb(local, skb, false);
  	if (status->free_list)
diff --git a/patches/0097-skb-list/mt76.patch b/patches/0097-skb-list/mt76.patch
index c63b151d..d6d41fc0 100644
--- a/patches/0097-skb-list/mt76.patch
+++ b/patches/0097-skb-list/mt76.patch
@@ -30,7 +30,7 @@
  }
 --- a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
 +++ b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
-@@ -1030,7 +1030,11 @@ mt7915_tx_check_aggr(struct ieee80211_st
+@@ -1053,7 +1053,11 @@ mt7915_tx_check_aggr(struct ieee80211_st
  static void
  mt7915_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
  			  struct ieee80211_sta *sta, u8 stat,
@@ -42,7 +42,7 @@
  {
  	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
  	struct ieee80211_tx_status status = {
-@@ -1094,10 +1098,16 @@ void mt7915_mac_tx_free(struct mt7915_de
+@@ -1116,10 +1120,16 @@ void mt7915_mac_tx_free(struct mt7915_de
  	struct mt76_phy *mphy_ext = mdev->phy2;
  	struct mt76_txwi_cache *txwi;
  	struct ieee80211_sta *sta = NULL;
@@ -60,7 +60,7 @@
  
  	/* clean DMA queues and unmap buffers first */
  	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
-@@ -1196,8 +1206,13 @@ void mt7915_mac_tx_free(struct mt7915_de
+@@ -1218,8 +1228,13 @@ void mt7915_mac_tx_free(struct mt7915_de
  
  	napi_consume_skb(skb, 1);
  
diff --git a/patches/0098-netdev_nested_priv/qtnfmac.patch b/patches/0098-netdev_nested_priv/qtnfmac.patch
index a177bed8..d525edfc 100644
--- a/patches/0098-netdev_nested_priv/qtnfmac.patch
+++ b/patches/0098-netdev_nested_priv/qtnfmac.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/quantenna/qtnfmac/core.c
 +++ b/drivers/net/wireless/quantenna/qtnfmac/core.c
-@@ -643,10 +643,16 @@ bool qtnf_netdev_is_qtn(const struct net
+@@ -644,10 +644,16 @@ bool qtnf_netdev_is_qtn(const struct net
  	return ndev->netdev_ops == &qtnf_netdev_ops;
  }
  
@@ -17,7 +17,7 @@
  
  	if (dev != ndev && netdev_port_same_parent_id(dev, ndev))
  		return -ENOTSUPP;
-@@ -659,9 +665,11 @@ static int qtnf_core_netdevice_event(str
+@@ -660,9 +666,11 @@ static int qtnf_core_netdevice_event(str
  {
  	struct net_device *ndev = netdev_notifier_info_to_dev(ptr);
  	const struct netdev_notifier_changeupper_info *info;
@@ -29,7 +29,7 @@
  	struct net_device *brdev;
  	struct qtnf_vif *vif;
  	struct qtnf_bus *bus;
-@@ -701,7 +709,11 @@ static int qtnf_core_netdevice_event(str
+@@ -702,7 +710,11 @@ static int qtnf_core_netdevice_event(str
  		} else {
  			ret = netdev_walk_all_lower_dev(brdev,
  							qtnf_check_br_ports,
diff --git a/patches/0099-netlink-range/mac80211.patch b/patches/0099-netlink-range/mac80211.patch
index 180b6082..d541e3e1 100644
--- a/patches/0099-netlink-range/mac80211.patch
+++ b/patches/0099-netlink-range/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -391,9 +391,11 @@ static const struct nla_policy
+@@ -411,9 +411,11 @@ static const struct nla_policy
  nl80211_fils_discovery_policy[NL80211_FILS_DISCOVERY_ATTR_MAX + 1] = {
  	[NL80211_FILS_DISCOVERY_ATTR_INT_MIN] = NLA_POLICY_MAX(NLA_U32, 10000),
  	[NL80211_FILS_DISCOVERY_ATTR_INT_MAX] = NLA_POLICY_MAX(NLA_U32, 10000),
@@ -12,7 +12,7 @@
  };
  
  static const struct nla_policy
-@@ -633,16 +635,26 @@ static const struct nla_policy nl80211_p
+@@ -653,16 +655,26 @@ static const struct nla_policy nl80211_p
  	 * The value of the Length field of the Supported Operating
  	 * Classes element is between 2 and 253.
  	 */
@@ -39,7 +39,7 @@
  	[NL80211_ATTR_MAC_HINT] = NLA_POLICY_EXACT_LEN_WARN(ETH_ALEN),
  	[NL80211_ATTR_WIPHY_FREQ_HINT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TDLS_PEER_CAPABILITY] = { .type = NLA_U32 },
-@@ -697,10 +709,15 @@ static const struct nla_policy nl80211_p
+@@ -717,10 +729,15 @@ static const struct nla_policy nl80211_p
  	[NL80211_ATTR_TXQ_LIMIT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TXQ_MEMORY_LIMIT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TXQ_QUANTUM] = { .type = NLA_U32 },
diff --git a/patches/0100-revert-small_ops/mac80211.patch b/patches/0100-revert-small_ops/mac80211.patch
index fe89977b..9c1359fd 100644
--- a/patches/0100-revert-small_ops/mac80211.patch
+++ b/patches/0100-revert-small_ops/mac80211.patch
@@ -1,8 +1,8 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -14875,9 +14875,11 @@ static const struct genl_ops nl80211_ops
- 		.internal_flags = NL80211_FLAG_NEED_WIPHY |
- 				  NL80211_FLAG_NEED_RTNL,
+@@ -15037,9 +15037,11 @@ static const struct genl_ops nl80211_ops
+ 		/* can be retrieved by unprivileged users */
+ 		.internal_flags = NL80211_FLAG_NEED_WIPHY,
  	},
 +#if LINUX_VERSION_IS_GEQ(5,10,0)
  };
@@ -12,7 +12,7 @@
  	{
  		.cmd = NL80211_CMD_SET_WIPHY,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -15739,8 +15741,10 @@ static struct genl_family nl80211_fam __
+@@ -15822,8 +15824,10 @@ static struct genl_family nl80211_fam __
  	.module = THIS_MODULE,
  	.ops = nl80211_ops,
  	.n_ops = ARRAY_SIZE(nl80211_ops),
diff --git a/patches/0100-revert-small_ops/mac80211_hwsim.patch b/patches/0100-revert-small_ops/mac80211_hwsim.patch
index 1a764336..6e8dff8c 100644
--- a/patches/0100-revert-small_ops/mac80211_hwsim.patch
+++ b/patches/0100-revert-small_ops/mac80211_hwsim.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mac80211_hwsim.c
 +++ b/drivers/net/wireless/mac80211_hwsim.c
-@@ -3964,7 +3964,11 @@ done:
+@@ -4069,7 +4069,11 @@ done:
  }
  
  /* Generic Netlink operations array */
@@ -12,7 +12,7 @@
  	{
  		.cmd = HWSIM_CMD_REGISTER,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -4008,8 +4012,13 @@ static struct genl_family hwsim_genl_fam
+@@ -4113,8 +4117,13 @@ static struct genl_family hwsim_genl_fam
  	.policy = hwsim_genl_policy,
  	.netnsok = true,
  	.module = THIS_MODULE,
diff --git a/patches/verify.patch b/patches/verify.patch
index f1faff55..2d858b34 100644
--- a/patches/verify.patch
+++ b/patches/verify.patch
@@ -64,15 +64,7 @@
  	struct x509_certificate *signer;	/* Certificate that signed this one */
 --- a/include/crypto/backport-public_key.h
 +++ b/include/crypto/backport-public_key.h
-@@ -12,7 +12,6 @@
- 
- #include <linux/keyctl.h>
- #include <linux/oid_registry.h>
--#include <crypto/akcipher.h>
- 
- /*
-  * Cryptographic data for the public-key subtype of the asymmetric key type.
-@@ -53,34 +52,6 @@ extern void public_key_signature_free(st
+@@ -52,34 +52,6 @@ extern void public_key_signature_free(st
  
  extern struct asymmetric_key_subtype public_key_subtype;
  
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 11/47] patches: include linux/modules.h in mt76/mt76_connac_mcu.c
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (9 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 10/47] patches: Refresh patches on top of kernel 5.12.19 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 12/47] patches: Do not use rx_list in mt76/mt7921 driver on older kernel versions Hauke Mehrtens
                   ` (36 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The mt76/mt76_connac_mcu.c file uses MODULE_AUTHOR and MODULE_LICENSE,
include linux/modules.h explicitly for older kernel versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0013-fix-makefile-includes/mt76.patch | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/patches/0013-fix-makefile-includes/mt76.patch b/patches/0013-fix-makefile-includes/mt76.patch
index 81ee4944..7c5f0d45 100644
--- a/patches/0013-fix-makefile-includes/mt76.patch
+++ b/patches/0013-fix-makefile-includes/mt76.patch
@@ -12,6 +12,16 @@ linux/kthread.h include needed against kernel 4.19.
  #include "mt7615.h"
  #include "mcu.h"
  #include "mac.h"
+--- a/drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c
++++ b/drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c
+@@ -2,6 +2,7 @@
+ /* Copyright (C) 2020 MediaTek Inc. */
+ 
+ #include "mt76_connac_mcu.h"
++#include <linux/module.h>
+ 
+ int mt76_connac_mcu_start_firmware(struct mt76_dev *dev, u32 addr, u32 option)
+ {
 --- a/drivers/net/wireless/mediatek/mt76/mt7615/sdio.c
 +++ b/drivers/net/wireless/mediatek/mt76/mt7615/sdio.c
 @@ -9,6 +9,7 @@
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 12/47] patches: Do not use rx_list in mt76/mt7921 driver on older kernel versions.
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (10 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 11/47] patches: include linux/modules.h in mt76/mt76_connac_mcu.c Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 13/47] patches: Do not use rx_list in mt7601u " Hauke Mehrtens
                   ` (35 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Use the sk_buff_head instead of the skb->rx_list on older kernel in
mt76/mt7921 driver too. This change is very similar to the change for
mt7915.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0097-skb-list/mt76.patch | 46 ++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/patches/0097-skb-list/mt76.patch b/patches/0097-skb-list/mt76.patch
index d6d41fc0..e67d4db9 100644
--- a/patches/0097-skb-list/mt76.patch
+++ b/patches/0097-skb-list/mt76.patch
@@ -74,3 +74,49 @@
  		napi_consume_skb(skb, 1);
  	}
  }
+--- a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
++++ b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
+@@ -866,7 +866,11 @@ mt7921_tx_check_aggr(struct ieee80211_st
+ static void
+ mt7921_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
+ 			  struct ieee80211_sta *sta, u8 stat,
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 			  struct list_head *free_list)
++#else
++			  struct sk_buff_head *free_list)
++#endif
+ {
+ 	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
+ 	struct ieee80211_tx_status status = {
+@@ -936,10 +940,16 @@ void mt7921_mac_tx_free(struct mt7921_de
+ 	struct mt76_dev *mdev = &dev->mt76;
+ 	struct mt76_txwi_cache *txwi;
+ 	struct ieee80211_sta *sta = NULL;
+-	LIST_HEAD(free_list);
+ 	struct sk_buff *tmp;
+ 	bool wake = false;
+ 	u8 i, count;
++#if LINUX_VERSION_IS_GEQ(4,19,0)
++	LIST_HEAD(free_list);
++#else
++	struct sk_buff_head free_list;
++
++	__skb_queue_head_init(&free_list);
++#endif
+ 
+ 	/* clean DMA queues and unmap buffers first */
+ 	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
+@@ -1028,8 +1038,13 @@ void mt7921_mac_tx_free(struct mt7921_de
+ 
+ 	napi_consume_skb(skb, 1);
+ 
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 	list_for_each_entry_safe(skb, tmp, &free_list, list) {
+ 		skb_list_del_init(skb);
++#else
++	skb_queue_walk_safe(&free_list, skb, tmp) {
++		__skb_unlink(skb, &free_list);
++#endif
+ 		napi_consume_skb(skb, 1);
+ 	}
+ 
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 13/47] patches: Do not use rx_list in mt7601u driver on older kernel versions.
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (11 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 12/47] patches: Do not use rx_list in mt76/mt7921 driver on older kernel versions Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 14/47] dependencies: Build mt7921 only on kernel >= 4.6 Hauke Mehrtens
                   ` (34 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Use the sk_buff_head instead of the skb->rx_list on older kernel in
mt7601u driver too.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0097-skb-list/mt7601u.patch | 30 +++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)
 create mode 100644 patches/0097-skb-list/mt7601u.patch

diff --git a/patches/0097-skb-list/mt7601u.patch b/patches/0097-skb-list/mt7601u.patch
new file mode 100644
index 00000000..97d78aff
--- /dev/null
+++ b/patches/0097-skb-list/mt7601u.patch
@@ -0,0 +1,30 @@
+--- a/drivers/net/wireless/mediatek/mt7601u/dma.c
++++ b/drivers/net/wireless/mediatek/mt7601u/dma.c
+@@ -75,7 +75,11 @@ bad_frame:
+ 
+ static void mt7601u_rx_process_seg(struct mt7601u_dev *dev, u8 *data,
+ 				   u32 seg_len, struct page *p,
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 				   struct list_head *list)
++#else
++				   struct sk_buff_head *list)
++#endif
+ {
+ 	struct sk_buff *skb;
+ 	struct mt7601u_rxwi *rxwi;
+@@ -135,8 +139,14 @@ mt7601u_rx_process_entry(struct mt7601u_
+ 	u32 seg_len, data_len = e->urb->actual_length;
+ 	u8 *data = page_address(e->p);
+ 	struct page *new_p = NULL;
+-	LIST_HEAD(list);
+ 	int cnt = 0;
++#if LINUX_VERSION_IS_GEQ(4,19,0)
++	LIST_HEAD(list);
++#else
++	struct sk_buff_head list;
++
++	__skb_queue_head_init(&list);
++#endif
+ 
+ 	if (!test_bit(MT7601U_STATE_INITIALIZED, &dev->state))
+ 		return;
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 14/47] dependencies: Build mt7921 only on kernel >= 4.6
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (12 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 13/47] patches: Do not use rx_list in mt7601u " Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 15/47] dependencies: Build NL80211_TESTMODE only on kernel >= 4.18 Hauke Mehrtens
                   ` (33 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

mt7921 uses napi_consume_skb() which is not available on older kernel
versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 dependencies | 1 +
 1 file changed, 1 insertion(+)

diff --git a/dependencies b/dependencies
index 39076904..3546a42a 100644
--- a/dependencies
+++ b/dependencies
@@ -26,6 +26,7 @@ RSI_COEX 4.17
 
 # needs napi_consume_skb()
 MT7915E 4.6
+MT7921E 4.6
 
 # depends on crypto_sync_skcipher()
 AIRO 4.20
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 15/47] dependencies: Build NL80211_TESTMODE only on kernel >= 4.18
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (13 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 14/47] dependencies: Build mt7921 only on kernel >= 4.6 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 16/47] headers: Add DECLARE_STATIC_KEY_FALSE Hauke Mehrtens
                   ` (32 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

mt7915 uses skb_copy_header() when CONFIG_NL80211_TESTMODE is set which
is not available on older kernel versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 dependencies | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dependencies b/dependencies
index 3546a42a..8f0ca5ef 100644
--- a/dependencies
+++ b/dependencies
@@ -31,3 +31,6 @@ MT7921E 4.6
 # depends on crypto_sync_skcipher()
 AIRO 4.20
 AIRO_CS 4.20
+
+# mt7915 testmode uses skb_copy_header()
+NL80211_TESTMODE 4.18
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 16/47] headers: Add DECLARE_STATIC_KEY_FALSE
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (14 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 15/47] dependencies: Build NL80211_TESTMODE only on kernel >= 4.18 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 17/47] headers: Add ETH_P_MAP Hauke Mehrtens
                   ` (31 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This define was added in kernel 4.9 and is used by mac80211 now.
The code was copied from the upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/jump_label.h | 10 ++++++++++
 1 file changed, 10 insertions(+)
 create mode 100644 backport/backport-include/linux/jump_label.h

diff --git a/backport/backport-include/linux/jump_label.h b/backport/backport-include/linux/jump_label.h
new file mode 100644
index 00000000..43608fa0
--- /dev/null
+++ b/backport/backport-include/linux/jump_label.h
@@ -0,0 +1,10 @@
+#ifndef __BACKPORT_LINUX_JUMP_LABEL_H
+#define __BACKPORT_LINUX_JUMP_LABEL_H
+#include_next <linux/jump_label.h>
+
+#ifndef DECLARE_STATIC_KEY_FALSE
+#define DECLARE_STATIC_KEY_FALSE(name)	\
+	extern struct static_key_false name
+#endif
+
+#endif /* __BACKPORT_LINUX_JUMP_LABEL_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 17/47] headers: Add ETH_P_MAP
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (15 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 16/47] headers: Add DECLARE_STATIC_KEY_FALSE Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 18/47] patches: Refresh on top of kernel 5.13.19 Hauke Mehrtens
                   ` (30 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This define was added in kernel 4.14 and is used by qmi_wwan now.
The code was copied from the upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/if_ether.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/backport/backport-include/linux/if_ether.h b/backport/backport-include/linux/if_ether.h
index ac071993..ff2e7513 100644
--- a/backport/backport-include/linux/if_ether.h
+++ b/backport/backport-include/linux/if_ether.h
@@ -47,6 +47,12 @@
 #define ETH_P_PREAUTH   0x88C7          /* 802.11 Preauthentication */
 #endif
 
+#ifndef ETH_P_MAP
+#define ETH_P_MAP	0x00F9		/* Qualcomm multiplexing and
+					 * aggregation protocol
+					 */
+#endif
+
 #ifndef ETH_MIN_MTU
 #define ETH_MIN_MTU	68
 #endif
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 18/47] patches: Refresh on top of kernel 5.13.19
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (16 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 17/47] headers: Add ETH_P_MAP Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 19/47] headers: Add tasklet_disable_in_atomic() Hauke Mehrtens
                   ` (29 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 .../include_net_cfg80211.patch                   |  2 +-
 .../net_wireless_core.patch                      |  2 +-
 .../0013-fix-makefile-includes/wilc1000.patch    |  4 ++--
 patches/0028-select_queue/mac80211.patch         |  4 ++--
 patches/0028-select_queue/rtl8188eu.patch        |  2 +-
 patches/0028-select_queue/rtl8723bs.patch        |  2 +-
 patches/0077-genl-ro-after-init/nl80211.patch    |  2 +-
 patches/0084-disable-some-staging-dirs.patch     |  6 +++---
 patches/0094-ndo-tx-timeout/usbnet.patch         |  2 +-
 patches/0095-spi-delay/wilc1000.patch            |  6 +++---
 patches/0097-skb-list/mac80211-rx.patch          | 16 ++++++++--------
 patches/0097-skb-list/mt76.patch                 | 16 ++++++++--------
 patches/0099-netlink-range/mac80211.patch        | 13 +++++++------
 patches/0100-revert-small_ops/mac80211.patch     |  4 ++--
 patches/verify.patch                             |  4 ++--
 15 files changed, 43 insertions(+), 42 deletions(-)

diff --git a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
index 580ab9b9..52d72227 100644
--- a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
+++ b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
@@ -1,6 +1,6 @@
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -4947,6 +4947,9 @@ struct wiphy {
+@@ -4951,6 +4951,9 @@ struct wiphy {
  
  	/* assign these fields before you register the wiphy */
  
diff --git a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
index 8bd7c4f5..d7be390e 100644
--- a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
+++ b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
@@ -11,7 +11,7 @@
  	device_initialize(&rdev->wiphy.dev);
  	rdev->wiphy.dev.class = &ieee80211_class;
  	rdev->wiphy.dev.platform_data = rdev;
-@@ -1311,6 +1307,10 @@ void cfg80211_init_wdev(struct wireless_
+@@ -1312,6 +1308,10 @@ void cfg80211_init_wdev(struct wireless_
  	INIT_WORK(&wdev->pmsr_free_wk, cfg80211_pmsr_free_wk);
  
  #ifdef CONFIG_CFG80211_WEXT
diff --git a/patches/0013-fix-makefile-includes/wilc1000.patch b/patches/0013-fix-makefile-includes/wilc1000.patch
index 819a1593..6304b3d7 100644
--- a/patches/0013-fix-makefile-includes/wilc1000.patch
+++ b/patches/0013-fix-makefile-includes/wilc1000.patch
@@ -24,10 +24,10 @@ linux/module.h include needed for kernel 3.18
  #include "cfg80211.h"
 --- a/drivers/net/wireless/microchip/wilc1000/spi.c
 +++ b/drivers/net/wireless/microchip/wilc1000/spi.c
-@@ -7,6 +7,7 @@
- #include <linux/clk.h>
+@@ -8,6 +8,7 @@
  #include <linux/spi/spi.h>
  #include <linux/crc7.h>
+ #include <linux/crc-itu-t.h>
 +#include <linux/module.h>
  
  #include "netdev.h"
diff --git a/patches/0028-select_queue/mac80211.patch b/patches/0028-select_queue/mac80211.patch
index c92dc0e0..36738162 100644
--- a/patches/0028-select_queue/mac80211.patch
+++ b/patches/0028-select_queue/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/mac80211/iface.c
 +++ b/net/mac80211/iface.c
-@@ -694,9 +694,21 @@ static void ieee80211_uninit(struct net_
+@@ -695,9 +695,21 @@ static void ieee80211_uninit(struct net_
  	ieee80211_teardown_sdata(IEEE80211_DEV_TO_SUB_IF(dev));
  }
  
@@ -22,7 +22,7 @@
  {
  	return ieee80211_select_queue(IEEE80211_DEV_TO_SUB_IF(dev), skb);
  }
-@@ -718,9 +730,21 @@ static const struct net_device_ops ieee8
+@@ -719,9 +731,21 @@ static const struct net_device_ops ieee8
  	.ndo_get_stats64	= ieee80211_get_stats64,
  };
  
diff --git a/patches/0028-select_queue/rtl8188eu.patch b/patches/0028-select_queue/rtl8188eu.patch
index 95b555a8..cd0fb42b 100644
--- a/patches/0028-select_queue/rtl8188eu.patch
+++ b/patches/0028-select_queue/rtl8188eu.patch
@@ -17,5 +17,5 @@
 +			    select_queue_fallback_t fallback)
 +#endif
  {
- 	struct adapter *padapter = rtw_netdev_priv(dev);
+ 	struct adapter *padapter = netdev_priv(dev);
  	struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
diff --git a/patches/0028-select_queue/rtl8723bs.patch b/patches/0028-select_queue/rtl8723bs.patch
index 962c0cc9..b3c2a9dc 100644
--- a/patches/0028-select_queue/rtl8723bs.patch
+++ b/patches/0028-select_queue/rtl8723bs.patch
@@ -1,6 +1,6 @@
 --- a/drivers/staging/rtl8723bs/os_dep/os_intfs.c
 +++ b/drivers/staging/rtl8723bs/os_dep/os_intfs.c
-@@ -375,8 +375,18 @@ static unsigned int rtw_classify8021d(st
+@@ -364,8 +364,18 @@ static unsigned int rtw_classify8021d(st
  }
  
  
diff --git a/patches/0077-genl-ro-after-init/nl80211.patch b/patches/0077-genl-ro-after-init/nl80211.patch
index 69f9b075..3976dcaf 100644
--- a/patches/0077-genl-ro-after-init/nl80211.patch
+++ b/patches/0077-genl-ro-after-init/nl80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15793,7 +15793,7 @@ static const struct genl_small_ops nl802
+@@ -15795,7 +15795,7 @@ static const struct genl_small_ops nl802
  	},
  };
  
diff --git a/patches/0084-disable-some-staging-dirs.patch b/patches/0084-disable-some-staging-dirs.patch
index 3852bc9b..2fb803e4 100644
--- a/patches/0084-disable-some-staging-dirs.patch
+++ b/patches/0084-disable-some-staging-dirs.patch
@@ -7,11 +7,11 @@
 -obj-y				+= media/
 +#obj-y				+= media/
  obj-$(CONFIG_PRISM2_USB)	+= wlan-ng/
- obj-$(CONFIG_COMEDI)		+= comedi/
  obj-$(CONFIG_FB_OLPC_DCON)	+= olpc_dcon/
-@@ -46,4 +46,4 @@ obj-$(CONFIG_KPC2000)		+= kpc2000/
+ obj-$(CONFIG_RTL8192U)		+= rtl8192u/
+@@ -42,4 +42,4 @@ obj-$(CONFIG_FIELDBUS_DEV)     += fieldb
+ obj-$(CONFIG_KPC2000)		+= kpc2000/
  obj-$(CONFIG_QLGE)		+= qlge/
- obj-$(CONFIG_WIMAX)		+= wimax/
  obj-$(CONFIG_WFX)		+= wfx/
 -obj-y				+= hikey9xx/
 +#obj-y				+= hikey9xx/
diff --git a/patches/0094-ndo-tx-timeout/usbnet.patch b/patches/0094-ndo-tx-timeout/usbnet.patch
index 2d0ef695..8069862d 100644
--- a/patches/0094-ndo-tx-timeout/usbnet.patch
+++ b/patches/0094-ndo-tx-timeout/usbnet.patch
@@ -1,6 +1,6 @@
 --- a/include/linux/usb/usbnet.h
 +++ b/include/linux/usb/usbnet.h
-@@ -255,6 +255,7 @@ extern int usbnet_stop(struct net_device
+@@ -256,6 +256,7 @@ extern int usbnet_stop(struct net_device
  extern netdev_tx_t usbnet_start_xmit(struct sk_buff *skb,
  				     struct net_device *net);
  extern void usbnet_tx_timeout(struct net_device *net, unsigned int txqueue);
diff --git a/patches/0095-spi-delay/wilc1000.patch b/patches/0095-spi-delay/wilc1000.patch
index d4876f4b..56bbaf9a 100644
--- a/patches/0095-spi-delay/wilc1000.patch
+++ b/patches/0095-spi-delay/wilc1000.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/microchip/wilc1000/spi.c
 +++ b/drivers/net/wireless/microchip/wilc1000/spi.c
-@@ -161,10 +161,14 @@ static int wilc_spi_tx(struct wilc *wilc
+@@ -213,10 +213,14 @@ static int wilc_spi_tx(struct wilc *wilc
  		struct spi_transfer tr = {
  			.tx_buf = b,
  			.len = len,
@@ -15,7 +15,7 @@
  		};
  		char *r_buffer = kzalloc(len, GFP_KERNEL);
  
-@@ -205,10 +209,14 @@ static int wilc_spi_rx(struct wilc *wilc
+@@ -257,10 +261,14 @@ static int wilc_spi_rx(struct wilc *wilc
  		struct spi_transfer tr = {
  			.rx_buf = rb,
  			.len = rlen,
@@ -30,7 +30,7 @@
  
  		};
  		char *t_buffer = kzalloc(rlen, GFP_KERNEL);
-@@ -250,10 +258,14 @@ static int wilc_spi_tx_rx(struct wilc *w
+@@ -302,10 +310,14 @@ static int wilc_spi_tx_rx(struct wilc *w
  			.tx_buf = wb,
  			.len = rlen,
  			.bits_per_word = 8,
diff --git a/patches/0097-skb-list/mac80211-rx.patch b/patches/0097-skb-list/mac80211-rx.patch
index e2be9ddd..bbfb9744 100644
--- a/patches/0097-skb-list/mac80211-rx.patch
+++ b/patches/0097-skb-list/mac80211-rx.patch
@@ -9,7 +9,7 @@ the older kernel instead. The list attributes where also backported to
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -4472,7 +4472,11 @@ void ieee80211_restart_hw(struct ieee802
+@@ -4476,7 +4476,11 @@ void ieee80211_restart_hw(struct ieee802
   * @list: the destination list
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *sta,
@@ -37,7 +37,7 @@ the older kernel instead. The list attributes where also backported to
  	struct ieee80211_sub_if_data *sdata;
 --- a/net/mac80211/rx.c
 +++ b/net/mac80211/rx.c
-@@ -2591,7 +2591,11 @@ static void ieee80211_deliver_skb_to_loc
+@@ -2592,7 +2592,11 @@ static void ieee80211_deliver_skb_to_loc
  
  		/* deliver to local stack */
  		if (rx->list)
@@ -49,7 +49,7 @@ the older kernel instead. The list attributes where also backported to
  		else
  			netif_receive_skb(skb);
  	}
-@@ -4440,7 +4444,11 @@ static void ieee80211_rx_8023(struct iee
+@@ -4441,7 +4445,11 @@ static void ieee80211_rx_8023(struct iee
  	skb->protocol = eth_type_trans(skb, fast_rx->dev);
  	memset(skb->cb, 0, sizeof(skb->cb));
  	if (rx->list)
@@ -61,7 +61,7 @@ the older kernel instead. The list attributes where also backported to
  	else
  		netif_receive_skb(skb);
  
-@@ -4622,7 +4630,11 @@ static bool ieee80211_prepare_and_rx_han
+@@ -4623,7 +4631,11 @@ static bool ieee80211_prepare_and_rx_han
  static void __ieee80211_rx_handle_8023(struct ieee80211_hw *hw,
  				       struct ieee80211_sta *pubsta,
  				       struct sk_buff *skb,
@@ -73,7 +73,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_fast_rx *fast_rx;
-@@ -4663,7 +4675,11 @@ drop:
+@@ -4664,7 +4676,11 @@ drop:
  static void __ieee80211_rx_handle_packet(struct ieee80211_hw *hw,
  					 struct ieee80211_sta *pubsta,
  					 struct sk_buff *skb,
@@ -85,7 +85,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_sub_if_data *sdata;
-@@ -4788,7 +4804,11 @@ static void __ieee80211_rx_handle_packet
+@@ -4789,7 +4805,11 @@ static void __ieee80211_rx_handle_packet
   * 802.11 MPDU is received from the hardware.
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *pubsta,
@@ -97,7 +97,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_rate *rate = NULL;
-@@ -4911,7 +4931,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4912,7 +4932,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		       struct sk_buff *skb, struct napi_struct *napi)
  {
  	struct sk_buff *tmp;
@@ -111,7 +111,7 @@ the older kernel instead. The list attributes where also backported to
  
  
  	/*
-@@ -4928,8 +4954,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4929,8 +4955,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		return;
  	}
  
diff --git a/patches/0097-skb-list/mt76.patch b/patches/0097-skb-list/mt76.patch
index e67d4db9..890b4c3c 100644
--- a/patches/0097-skb-list/mt76.patch
+++ b/patches/0097-skb-list/mt76.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mediatek/mt76/mac80211.c
 +++ b/drivers/net/wireless/mediatek/mt76/mac80211.c
-@@ -922,7 +922,13 @@ void mt76_rx_complete(struct mt76_dev *d
+@@ -998,7 +998,13 @@ void mt76_rx_complete(struct mt76_dev *d
  	struct ieee80211_sta *sta;
  	struct ieee80211_hw *hw;
  	struct sk_buff *skb, *tmp;
@@ -14,7 +14,7 @@
  
  	spin_lock(&dev->rx_lock);
  	while ((skb = __skb_dequeue(frames)) != NULL) {
-@@ -941,8 +947,13 @@ void mt76_rx_complete(struct mt76_dev *d
+@@ -1030,8 +1036,13 @@ void mt76_rx_complete(struct mt76_dev *d
  		return;
  	}
  
@@ -30,7 +30,7 @@
  }
 --- a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
 +++ b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
-@@ -1053,7 +1053,11 @@ mt7915_tx_check_aggr(struct ieee80211_st
+@@ -1086,7 +1086,11 @@ mt7915_tx_check_aggr(struct ieee80211_st
  static void
  mt7915_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
  			  struct ieee80211_sta *sta, u8 stat,
@@ -42,7 +42,7 @@
  {
  	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
  	struct ieee80211_tx_status status = {
-@@ -1116,10 +1120,16 @@ void mt7915_mac_tx_free(struct mt7915_de
+@@ -1149,10 +1153,16 @@ void mt7915_mac_tx_free(struct mt7915_de
  	struct mt76_phy *mphy_ext = mdev->phy2;
  	struct mt76_txwi_cache *txwi;
  	struct ieee80211_sta *sta = NULL;
@@ -60,7 +60,7 @@
  
  	/* clean DMA queues and unmap buffers first */
  	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
-@@ -1218,8 +1228,13 @@ void mt7915_mac_tx_free(struct mt7915_de
+@@ -1240,8 +1250,13 @@ void mt7915_mac_tx_free(struct mt7915_de
  
  	napi_consume_skb(skb, 1);
  
@@ -76,7 +76,7 @@
  }
 --- a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
 +++ b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
-@@ -866,7 +866,11 @@ mt7921_tx_check_aggr(struct ieee80211_st
+@@ -870,7 +870,11 @@ mt7921_tx_check_aggr(struct ieee80211_st
  static void
  mt7921_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
  			  struct ieee80211_sta *sta, u8 stat,
@@ -88,7 +88,7 @@
  {
  	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
  	struct ieee80211_tx_status status = {
-@@ -936,10 +940,16 @@ void mt7921_mac_tx_free(struct mt7921_de
+@@ -940,10 +944,16 @@ void mt7921_mac_tx_free(struct mt7921_de
  	struct mt76_dev *mdev = &dev->mt76;
  	struct mt76_txwi_cache *txwi;
  	struct ieee80211_sta *sta = NULL;
@@ -106,7 +106,7 @@
  
  	/* clean DMA queues and unmap buffers first */
  	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
-@@ -1028,8 +1038,13 @@ void mt7921_mac_tx_free(struct mt7921_de
+@@ -1021,8 +1031,13 @@ void mt7921_mac_tx_free(struct mt7921_de
  
  	napi_consume_skb(skb, 1);
  
diff --git a/patches/0099-netlink-range/mac80211.patch b/patches/0099-netlink-range/mac80211.patch
index d541e3e1..e1037a58 100644
--- a/patches/0099-netlink-range/mac80211.patch
+++ b/patches/0099-netlink-range/mac80211.patch
@@ -1,18 +1,19 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -411,9 +411,11 @@ static const struct nla_policy
+@@ -412,10 +412,12 @@ static const struct nla_policy
  nl80211_fils_discovery_policy[NL80211_FILS_DISCOVERY_ATTR_MAX + 1] = {
  	[NL80211_FILS_DISCOVERY_ATTR_INT_MIN] = NLA_POLICY_MAX(NLA_U32, 10000),
  	[NL80211_FILS_DISCOVERY_ATTR_INT_MAX] = NLA_POLICY_MAX(NLA_U32, 10000),
 +#if LINUX_VERSION_IS_GEQ(5,10,0)
- 	NLA_POLICY_RANGE(NLA_BINARY,
- 			 NL80211_FILS_DISCOVERY_TMPL_MIN_LEN,
- 			 IEEE80211_MAX_DATA_LEN),
+ 	[NL80211_FILS_DISCOVERY_ATTR_TMPL] =
+ 			NLA_POLICY_RANGE(NLA_BINARY,
+ 					 NL80211_FILS_DISCOVERY_TMPL_MIN_LEN,
+ 					 IEEE80211_MAX_DATA_LEN),
 +#endif
  };
  
  static const struct nla_policy
-@@ -653,16 +655,26 @@ static const struct nla_policy nl80211_p
+@@ -655,16 +657,26 @@ static const struct nla_policy nl80211_p
  	 * The value of the Length field of the Supported Operating
  	 * Classes element is between 2 and 253.
  	 */
@@ -39,7 +40,7 @@
  	[NL80211_ATTR_MAC_HINT] = NLA_POLICY_EXACT_LEN_WARN(ETH_ALEN),
  	[NL80211_ATTR_WIPHY_FREQ_HINT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TDLS_PEER_CAPABILITY] = { .type = NLA_U32 },
-@@ -717,10 +729,15 @@ static const struct nla_policy nl80211_p
+@@ -719,10 +731,15 @@ static const struct nla_policy nl80211_p
  	[NL80211_ATTR_TXQ_LIMIT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TXQ_MEMORY_LIMIT] = { .type = NLA_U32 },
  	[NL80211_ATTR_TXQ_QUANTUM] = { .type = NLA_U32 },
diff --git a/patches/0100-revert-small_ops/mac80211.patch b/patches/0100-revert-small_ops/mac80211.patch
index 9c1359fd..c5e3bc84 100644
--- a/patches/0100-revert-small_ops/mac80211.patch
+++ b/patches/0100-revert-small_ops/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15037,9 +15037,11 @@ static const struct genl_ops nl80211_ops
+@@ -15039,9 +15039,11 @@ static const struct genl_ops nl80211_ops
  		/* can be retrieved by unprivileged users */
  		.internal_flags = NL80211_FLAG_NEED_WIPHY,
  	},
@@ -12,7 +12,7 @@
  	{
  		.cmd = NL80211_CMD_SET_WIPHY,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -15822,8 +15824,10 @@ static struct genl_family nl80211_fam __
+@@ -15824,8 +15826,10 @@ static struct genl_family nl80211_fam __
  	.module = THIS_MODULE,
  	.ops = nl80211_ops,
  	.n_ops = ARRAY_SIZE(nl80211_ops),
diff --git a/patches/verify.patch b/patches/verify.patch
index 2d858b34..e32816e9 100644
--- a/patches/verify.patch
+++ b/patches/verify.patch
@@ -23,7 +23,7 @@
  #include "x509_parser.h"
  
  /*
-@@ -153,6 +150,7 @@ not_self_signed:
+@@ -155,6 +152,7 @@ not_self_signed:
  	return 0;
  }
  
@@ -31,7 +31,7 @@
  /*
   * Attempt to parse a data blob for a key as an X509 certificate.
   */
-@@ -271,3 +269,4 @@ module_exit(x509_key_exit);
+@@ -273,3 +271,4 @@ module_exit(x509_key_exit);
  MODULE_DESCRIPTION("X.509 certificate parser");
  MODULE_AUTHOR("Red Hat, Inc.");
  MODULE_LICENSE("GPL");
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 19/47] headers: Add tasklet_disable_in_atomic()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (17 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 18/47] patches: Refresh on top of kernel 5.13.19 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 20/47] headers: Add lockdep_assert_not_held() Hauke Mehrtens
                   ` (28 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The tasklet_disable_in_atomic() function was added in kernel 5.13 and is
used by ath9k now.
The code was copied from the upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/interrupt.h | 23 ++++++++++++++++
 backport/compat/Makefile                    |  1 +
 backport/compat/backport-5.13.c             | 30 +++++++++++++++++++++
 3 files changed, 54 insertions(+)
 create mode 100644 backport/compat/backport-5.13.c

diff --git a/backport/backport-include/linux/interrupt.h b/backport/backport-include/linux/interrupt.h
index f334a963..41d50d7c 100644
--- a/backport/backport-include/linux/interrupt.h
+++ b/backport/backport-include/linux/interrupt.h
@@ -50,4 +50,27 @@ tasklet_setup(struct tasklet_struct *t,
 
 #endif
 
+#if LINUX_VERSION_IS_LESS(5,13,0)
+
+#define tasklet_unlock_spin_wait LINUX_BACKPORT(tasklet_unlock_spin_wait)
+#if defined(CONFIG_SMP) || defined(CONFIG_PREEMPT_RT)
+void tasklet_unlock_spin_wait(struct tasklet_struct *t);
+
+#else
+static inline void tasklet_unlock_spin_wait(struct tasklet_struct *t) { }
+#endif
+
+/*
+ * Do not use in new code. Disabling tasklets from atomic contexts is
+ * error prone and should be avoided.
+ */
+#define tasklet_disable_in_atomic LINUX_BACKPORT(tasklet_disable_in_atomic)
+static inline void tasklet_disable_in_atomic(struct tasklet_struct *t)
+{
+	tasklet_disable_nosync(t);
+	tasklet_unlock_spin_wait(t);
+	smp_mb();
+}
+#endif
+
 #endif /* _BP_LINUX_INTERRUPT_H */
diff --git a/backport/compat/Makefile b/backport/compat/Makefile
index e927a0c8..2761e5f5 100644
--- a/backport/compat/Makefile
+++ b/backport/compat/Makefile
@@ -19,6 +19,7 @@ compat-$(CPTCFG_KERNEL_5_3) += backport-5.3.o
 compat-$(CPTCFG_KERNEL_5_5) += backport-5.5.o
 compat-$(CPTCFG_KERNEL_5_10) += backport-5.10.o
 compat-$(CPTCFG_KERNEL_5_11) += backport-5.11.o
+compat-$(CPTCFG_KERNEL_5_13) += backport-5.13.o
 
 compat-$(CPTCFG_BPAUTO_BUILD_SYSTEM_DATA_VERIFICATION) += verification/verify.o
 compat-$(CPTCFG_BPAUTO_BUILD_SYSTEM_DATA_VERIFICATION) += verification/pkcs7.asn1.o
diff --git a/backport/compat/backport-5.13.c b/backport/compat/backport-5.13.c
new file mode 100644
index 00000000..c10b3321
--- /dev/null
+++ b/backport/compat/backport-5.13.c
@@ -0,0 +1,30 @@
+// SPDX-License-Identifier: GPL-2.0
+
+#include <linux/export.h>
+#include <linux/interrupt.h>
+
+#if defined(CONFIG_SMP) || defined(CONFIG_PREEMPT_RT)
+/*
+ * Do not use in new code. Waiting for tasklets from atomic contexts is
+ * error prone and should be avoided.
+ */
+void tasklet_unlock_spin_wait(struct tasklet_struct *t)
+{
+	while (test_bit(TASKLET_STATE_RUN, &(t)->state)) {
+		if (IS_ENABLED(CONFIG_PREEMPT_RT)) {
+			/*
+			 * Prevent a live lock when current preempted soft
+			 * interrupt processing or prevents ksoftirqd from
+			 * running. If the tasklet runs on a different CPU
+			 * then this has no effect other than doing the BH
+			 * disable/enable dance for nothing.
+			 */
+			local_bh_disable();
+			local_bh_enable();
+		} else {
+			cpu_relax();
+		}
+	}
+}
+EXPORT_SYMBOL_GPL(tasklet_unlock_spin_wait);
+#endif
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 20/47] headers: Add lockdep_assert_not_held()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (18 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 19/47] headers: Add tasklet_disable_in_atomic() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 21/47] headers: Adapt signature of of_get_mac_address() Hauke Mehrtens
                   ` (27 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The lockdep_assert_not_held() define was added in kernel 5.13 and is
used by ath10k now.
The code was copied from the upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/lockdep.h | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/backport/backport-include/linux/lockdep.h b/backport/backport-include/linux/lockdep.h
index 7cf38b23..ed5ea678 100644
--- a/backport/backport-include/linux/lockdep.h
+++ b/backport/backport-include/linux/lockdep.h
@@ -9,4 +9,15 @@ struct lockdep_map { };
 #endif /* CONFIG_LOCKDEP */
 #endif /* LINUX_VERSION_IS_LESS(4,15,0) */
 
+#ifndef lockdep_assert_not_held
+#ifdef CONFIG_LOCKDEP
+#define lockdep_assert_not_held(l)	do {				\
+		WARN_ON(debug_locks &&					\
+			lockdep_is_held(l) == LOCK_STATE_HELD);		\
+	} while (0)
+#else
+#define lockdep_assert_not_held(l)		do { (void)(l); } while (0)
+#endif /* CONFIG_LOCKDEP */
+#endif /* lockdep_assert_not_held */
+
 #endif /* __BACKPORT_LINUX_LOCKDEP_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 21/47] headers: Adapt signature of of_get_mac_address()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (19 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 20/47] headers: Add lockdep_assert_not_held() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 22/47] headers: Add rfkill_set_hw_state_reason() Hauke Mehrtens
                   ` (26 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The function signature of of_get_mac_address() changed in kernel 5.13.
This code converts calls using the new signature to the old API.
The return value changed in kernel 5.2, which is still taken care of.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/of_net.h | 14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

diff --git a/backport/backport-include/linux/of_net.h b/backport/backport-include/linux/of_net.h
index 866aec57..9b9276f1 100644
--- a/backport/backport-include/linux/of_net.h
+++ b/backport/backport-include/linux/of_net.h
@@ -2,19 +2,23 @@
 #define _BP_OF_NET_H
 #include_next <linux/of_net.h>
 #include <linux/version.h>
+#include <linux/etherdevice.h>
 
 /* The behavior of of_get_mac_address() changed in kernel 5.2, it now
  * returns an error code and not NULL in case of an error.
  */
-#if LINUX_VERSION_IS_LESS(5,2,0)
-static inline const void *backport_of_get_mac_address(struct device_node *np)
+#if LINUX_VERSION_IS_LESS(5,13,0)
+static inline int backport_of_get_mac_address(struct device_node *np, u8 *mac_out)
 {
 	const void *mac = of_get_mac_address(np);
 
 	if (!mac)
-		return ERR_PTR(-ENODEV);
-
-	return mac;
+		return -ENODEV;
+	if (IS_ERR(mac))
+		return PTR_ERR(mac);
+	ether_addr_copy(mac_out, mac);
+	
+	return 0;
 }
 #define of_get_mac_address LINUX_BACKPORT(of_get_mac_address)
 #endif /* < 5.2 */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 22/47] headers: Add rfkill_set_hw_state_reason()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (20 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 21/47] headers: Adapt signature of of_get_mac_address() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 23/47] patches: Remove usage of threaded NAPI from mt76 Hauke Mehrtens
                   ` (25 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This adds the new function rfkill_set_hw_state_reason() from kernel 5.11
and maps it to the old rfkill_set_hw_state() by dropping the reason.
kernel 5.11 also moved some definitions to the uapi/linux/rfkill.h, but
on kernel versions < 5.11 it is not sufficient to only include the uapi
version.
This is used by the core wireless system.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/rfkill.h      | 24 +++++++++++++++++++
 .../0013-fix-makefile-includes/cfg80211.patch | 14 ++++++++++-
 2 files changed, 37 insertions(+), 1 deletion(-)
 create mode 100644 backport/backport-include/linux/rfkill.h

diff --git a/backport/backport-include/linux/rfkill.h b/backport/backport-include/linux/rfkill.h
new file mode 100644
index 00000000..c0b99d58
--- /dev/null
+++ b/backport/backport-include/linux/rfkill.h
@@ -0,0 +1,24 @@
+#ifndef __BACKPORT_UAPI__RFKILL_H
+#define __BACKPORT_UAPI__RFKILL_H
+#include_next <linux/rfkill.h>
+
+
+#if LINUX_VERSION_IS_LESS(5,11,0)
+
+/* This should come from uapi/linux/rfkill.h, but it was much easier
+ * to do it this way.
+ */
+enum rfkill_hard_block_reasons {
+	RFKILL_HARD_BLOCK_SIGNAL        = 1 << 0,
+	RFKILL_HARD_BLOCK_NOT_OWNER     = 1 << 1,
+};
+
+static inline bool rfkill_set_hw_state_reason(struct rfkill *rfkill,
+					      bool blocked, unsigned long reason)
+{
+	return rfkill_set_hw_state(rfkill, blocked);
+}
+
+#endif /* 5.11 */
+
+#endif /* __BACKPORT_UAPI__RFKILL_H */
diff --git a/patches/0013-fix-makefile-includes/cfg80211.patch b/patches/0013-fix-makefile-includes/cfg80211.patch
index 0e079911..c44e3f58 100644
--- a/patches/0013-fix-makefile-includes/cfg80211.patch
+++ b/patches/0013-fix-makefile-includes/cfg80211.patch
@@ -6,7 +6,19 @@ the type is renamed.
 
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -22,6 +22,7 @@
+@@ -11,7 +11,11 @@
+  */
+ 
+ #include <linux/ethtool.h>
++#if LINUX_VERSION_IS_LESS(5,11,0)
++#include <linux/rfkill.h>
++#else
+ #include <uapi/linux/rfkill.h>
++#endif
+ #include <linux/netdevice.h>
+ #include <linux/debugfs.h>
+ #include <linux/list.h>
+@@ -23,6 +27,7 @@
  #include <linux/ieee80211.h>
  #include <linux/net.h>
  #include <net/regulatory.h>
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 23/47] patches: Remove usage of threaded NAPI from mt76
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (21 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 22/47] headers: Add rfkill_set_hw_state_reason() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 24/47] headers: Adapt signature of thermal_zone_device_update() Hauke Mehrtens
                   ` (24 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

mt76 uses threaded napi which was introduced in kernel 5.12, it is hard
to backport this, so just remove usage from mt76 in older kernel
versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0101-net_device-threaded/mt76.patch | 41 +++++++++++++++++++++
 1 file changed, 41 insertions(+)
 create mode 100644 patches/0101-net_device-threaded/mt76.patch

diff --git a/patches/0101-net_device-threaded/mt76.patch b/patches/0101-net_device-threaded/mt76.patch
new file mode 100644
index 00000000..0aef6a1b
--- /dev/null
+++ b/patches/0101-net_device-threaded/mt76.patch
@@ -0,0 +1,41 @@
+--- a/drivers/net/wireless/mediatek/mt76/debugfs.c
++++ b/drivers/net/wireless/mediatek/mt76/debugfs.c
+@@ -25,6 +25,7 @@ mt76_reg_get(void *data, u64 *val)
+ DEFINE_DEBUGFS_ATTRIBUTE(fops_regval, mt76_reg_get, mt76_reg_set,
+ 			 "0x%08llx\n");
+ 
++#if LINUX_VERSION_IS_GEQ(5,12,0)
+ static int
+ mt76_napi_threaded_set(void *data, u64 val)
+ {
+@@ -50,6 +51,7 @@ mt76_napi_threaded_get(void *data, u64 *
+ 
+ DEFINE_DEBUGFS_ATTRIBUTE(fops_napi_threaded, mt76_napi_threaded_get,
+ 			 mt76_napi_threaded_set, "%llu\n");
++#endif
+ 
+ int mt76_queues_read(struct seq_file *s, void *data)
+ {
+@@ -128,8 +130,10 @@ struct dentry *mt76_register_debugfs(str
+ 	debugfs_create_u32("regidx", 0600, dir, &dev->debugfs_reg);
+ 	debugfs_create_file_unsafe("regval", 0600, dir, dev,
+ 				   &fops_regval);
++#if LINUX_VERSION_IS_GEQ(5,12,0)
+ 	debugfs_create_file_unsafe("napi_threaded", 0600, dir, dev,
+ 				   &fops_napi_threaded);
++#endif
+ 	debugfs_create_blob("eeprom", 0400, dir, &dev->eeprom);
+ 	if (dev->otp.data)
+ 		debugfs_create_blob("otp", 0400, dir, &dev->otp);
+--- a/drivers/net/wireless/mediatek/mt76/dma.c
++++ b/drivers/net/wireless/mediatek/mt76/dma.c
+@@ -643,7 +643,9 @@ mt76_dma_init(struct mt76_dev *dev,
+ 	init_dummy_netdev(&dev->tx_napi_dev);
+ 	snprintf(dev->napi_dev.name, sizeof(dev->napi_dev.name), "%s",
+ 		 wiphy_name(dev->hw->wiphy));
++#if LINUX_VERSION_IS_GEQ(5,12,0)
+ 	dev->napi_dev.threaded = 1;
++#endif
+ 
+ 	mt76_for_each_q_rx(dev, i) {
+ 		netif_napi_add(&dev->napi_dev, &dev->napi[i], poll, 64);
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 24/47] headers: Adapt signature of thermal_zone_device_update()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (22 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 23/47] patches: Remove usage of threaded NAPI from mt76 Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 25/47] headers: Add time_after32() Hauke Mehrtens
                   ` (23 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The function signature of thermal_zone_device_update() function changed
in kernel 4.9. Drop the event parameter for older kernel versions. This
function is used by iwlwifi.
The code was partly copied from the upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/thermal.h | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/backport/backport-include/linux/thermal.h b/backport/backport-include/linux/thermal.h
index d9b8153e..8210facf 100644
--- a/backport/backport-include/linux/thermal.h
+++ b/backport/backport-include/linux/thermal.h
@@ -13,4 +13,27 @@ static inline int thermal_zone_device_disable(struct thermal_zone_device *tz)
 { return 0; }
 #endif /* < 5.9 */
 
+#if LINUX_VERSION_IS_LESS(4,9,0)
+/* Thermal notification reason */
+enum thermal_notify_event {
+	THERMAL_EVENT_UNSPECIFIED, /* Unspecified event */
+	THERMAL_EVENT_TEMP_SAMPLE, /* New Temperature sample */
+	THERMAL_TRIP_VIOLATED, /* TRIP Point violation */
+	THERMAL_TRIP_CHANGED, /* TRIP Point temperature changed */
+	THERMAL_DEVICE_DOWN, /* Thermal device is down */
+	THERMAL_DEVICE_UP, /* Thermal device is up after a down event */
+	THERMAL_DEVICE_POWER_CAPABILITY_CHANGED, /* power capability changed */
+	THERMAL_TABLE_CHANGED, /* Thermal table(s) changed */
+	THERMAL_EVENT_KEEP_ALIVE, /* Request for user space handler to respond */
+};
+
+static inline void
+backport_thermal_zone_device_update(struct thermal_zone_device *tz,
+				    enum thermal_notify_event event)
+{
+	thermal_zone_device_update(tz);
+}
+#define thermal_zone_device_update LINUX_BACKPORT(thermal_zone_device_update)
+#endif /* < 4.9 */
+
 #endif /* __BACKPORT_LINUX_THERMAL_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 25/47] headers: Add time_after32()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (23 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 24/47] headers: Adapt signature of thermal_zone_device_update() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:42 ` [PATCH 26/47] patches: Refresh on top of kernel 5.14.13 Hauke Mehrtens
                   ` (22 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The function time_after32() was added in kernel 4.14 and is now used by
the mt76 driver.
The code was copied from the upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/time.h | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/backport/backport-include/linux/time.h b/backport/backport-include/linux/time.h
index ce8a1b03..712881db 100644
--- a/backport/backport-include/linux/time.h
+++ b/backport/backport-include/linux/time.h
@@ -12,4 +12,21 @@ static inline void time64_to_tm(time64_t totalsecs, int offset,
 }
 #endif
 
+#ifndef time_after32
+/**
+ * time_after32 - compare two 32-bit relative times
+ * @a:	the time which may be after @b
+ * @b:	the time which may be before @a
+ *
+ * time_after32(a, b) returns true if the time @a is after time @b.
+ * time_before32(b, a) returns true if the time @b is before time @a.
+ *
+ * Similar to time_after(), compare two 32-bit timestamps for relative
+ * times.  This is useful for comparing 32-bit seconds values that can't
+ * be converted to 64-bit values (e.g. due to disk format or wire protocol
+ * issues) when it is known that the times are less than 68 years apart.
+ */
+#define time_after32(a, b)	((s32)((u32)(b) - (u32)(a)) < 0)
+#endif
+
 #endif /* __BACKPORT_LINUX_TIME_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 26/47] patches: Refresh on top of kernel 5.14.13
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (24 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 25/47] headers: Add time_after32() Hauke Mehrtens
@ 2021-10-19 21:42 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 27/47] headers: Add FW_ACTION_NOUEVENT and FW_ACTION_UEVENT Hauke Mehrtens
                   ` (21 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:42 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 .../include_net_cfg80211.patch                |  2 +-
 .../net_wireless_core.patch                   |  2 +-
 .../0013-fix-makefile-includes/cfg80211.patch |  4 +-
 .../0013-fix-makefile-includes/rtw88.patch    |  2 +-
 patches/0028-select_queue/rtl8188eu.patch     |  2 +-
 patches/0028-select_queue/rtl8723bs.patch     |  2 +-
 patches/0077-genl-ro-after-init/hwsim.patch   |  2 +-
 patches/0077-genl-ro-after-init/nl80211.patch |  2 +-
 patches/0079-netdev-destructor/brcmfmac.patch |  4 +-
 patches/0084-disable-some-staging-dirs.patch  |  4 +-
 patches/0097-skb-list/mac80211-rx.patch       |  4 +-
 patches/0097-skb-list/mac80211-status.patch   |  6 +-
 patches/0097-skb-list/mt76.patch              | 56 ++++++++++++++-----
 patches/0100-revert-small_ops/mac80211.patch  |  4 +-
 .../mac80211_hwsim.patch                      |  4 +-
 patches/0101-net_device-threaded/mt76.patch   |  2 +-
 16 files changed, 65 insertions(+), 37 deletions(-)

diff --git a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
index 52d72227..0f3e7431 100644
--- a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
+++ b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
@@ -1,6 +1,6 @@
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -4951,6 +4951,9 @@ struct wiphy {
+@@ -4961,6 +4961,9 @@ struct wiphy {
  
  	/* assign these fields before you register the wiphy */
  
diff --git a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
index d7be390e..f7484b67 100644
--- a/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
+++ b/patches/0010-add-wext-handlers-to-netdev/net_wireless_core.patch
@@ -11,7 +11,7 @@
  	device_initialize(&rdev->wiphy.dev);
  	rdev->wiphy.dev.class = &ieee80211_class;
  	rdev->wiphy.dev.platform_data = rdev;
-@@ -1312,6 +1308,10 @@ void cfg80211_init_wdev(struct wireless_
+@@ -1296,6 +1292,10 @@ void cfg80211_init_wdev(struct wireless_
  	INIT_WORK(&wdev->pmsr_free_wk, cfg80211_pmsr_free_wk);
  
  #ifdef CONFIG_CFG80211_WEXT
diff --git a/patches/0013-fix-makefile-includes/cfg80211.patch b/patches/0013-fix-makefile-includes/cfg80211.patch
index c44e3f58..599ffa4f 100644
--- a/patches/0013-fix-makefile-includes/cfg80211.patch
+++ b/patches/0013-fix-makefile-includes/cfg80211.patch
@@ -18,9 +18,9 @@ the type is renamed.
  #include <linux/netdevice.h>
  #include <linux/debugfs.h>
  #include <linux/list.h>
-@@ -23,6 +27,7 @@
- #include <linux/ieee80211.h>
+@@ -24,6 +28,7 @@
  #include <linux/net.h>
+ #include <linux/rfkill.h>
  #include <net/regulatory.h>
 +#include <net/netlink.h>
  
diff --git a/patches/0013-fix-makefile-includes/rtw88.patch b/patches/0013-fix-makefile-includes/rtw88.patch
index e66439d9..41dea13e 100644
--- a/patches/0013-fix-makefile-includes/rtw88.patch
+++ b/patches/0013-fix-makefile-includes/rtw88.patch
@@ -2,7 +2,7 @@ linux/module.h include needed for kernel 3.18
 
 --- a/drivers/net/wireless/realtek/rtw88/main.c
 +++ b/drivers/net/wireless/realtek/rtw88/main.c
-@@ -15,6 +15,7 @@
+@@ -17,6 +17,7 @@
  #include "tx.h"
  #include "debug.h"
  #include "bf.h"
diff --git a/patches/0028-select_queue/rtl8188eu.patch b/patches/0028-select_queue/rtl8188eu.patch
index cd0fb42b..7d3c7b95 100644
--- a/patches/0028-select_queue/rtl8188eu.patch
+++ b/patches/0028-select_queue/rtl8188eu.patch
@@ -1,6 +1,6 @@
 --- a/drivers/staging/rtl8188eu/os_dep/os_intfs.c
 +++ b/drivers/staging/rtl8188eu/os_dep/os_intfs.c
-@@ -245,8 +245,18 @@ static unsigned int rtw_classify8021d(st
+@@ -243,8 +243,18 @@ static unsigned int rtw_classify8021d(st
  	return dscp >> 5;
  }
  
diff --git a/patches/0028-select_queue/rtl8723bs.patch b/patches/0028-select_queue/rtl8723bs.patch
index b3c2a9dc..f19199b6 100644
--- a/patches/0028-select_queue/rtl8723bs.patch
+++ b/patches/0028-select_queue/rtl8723bs.patch
@@ -1,6 +1,6 @@
 --- a/drivers/staging/rtl8723bs/os_dep/os_intfs.c
 +++ b/drivers/staging/rtl8723bs/os_dep/os_intfs.c
-@@ -364,8 +364,18 @@ static unsigned int rtw_classify8021d(st
+@@ -363,8 +363,18 @@ static unsigned int rtw_classify8021d(st
  }
  
  
diff --git a/patches/0077-genl-ro-after-init/hwsim.patch b/patches/0077-genl-ro-after-init/hwsim.patch
index 189b1822..7dc66712 100644
--- a/patches/0077-genl-ro-after-init/hwsim.patch
+++ b/patches/0077-genl-ro-after-init/hwsim.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mac80211_hwsim.c
 +++ b/drivers/net/wireless/mac80211_hwsim.c
-@@ -4106,7 +4106,7 @@ static const struct genl_small_ops hwsim
+@@ -4103,7 +4103,7 @@ static const struct genl_small_ops hwsim
  	},
  };
  
diff --git a/patches/0077-genl-ro-after-init/nl80211.patch b/patches/0077-genl-ro-after-init/nl80211.patch
index 3976dcaf..84cb42a8 100644
--- a/patches/0077-genl-ro-after-init/nl80211.patch
+++ b/patches/0077-genl-ro-after-init/nl80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15795,7 +15795,7 @@ static const struct genl_small_ops nl802
+@@ -15803,7 +15803,7 @@ static const struct genl_small_ops nl802
  	},
  };
  
diff --git a/patches/0079-netdev-destructor/brcmfmac.patch b/patches/0079-netdev-destructor/brcmfmac.patch
index 33e12792..1e16b92c 100644
--- a/patches/0079-netdev-destructor/brcmfmac.patch
+++ b/patches/0079-netdev-destructor/brcmfmac.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c
 +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c
-@@ -633,6 +633,23 @@ static const struct net_device_ops brcmf
+@@ -638,6 +638,23 @@ static const struct net_device_ops brcmf
  	.ndo_set_rx_mode = brcmf_netdev_set_multicast_list
  };
  
@@ -24,7 +24,7 @@
  int brcmf_net_attach(struct brcmf_if *ifp, bool locked)
  {
  	struct brcmf_pub *drvr = ifp->drvr;
-@@ -883,7 +900,11 @@ struct brcmf_if *brcmf_add_if(struct brc
+@@ -888,7 +905,11 @@ struct brcmf_if *brcmf_add_if(struct brc
  		if (!ndev)
  			return ERR_PTR(-ENOMEM);
  
diff --git a/patches/0084-disable-some-staging-dirs.patch b/patches/0084-disable-some-staging-dirs.patch
index 2fb803e4..74abcff1 100644
--- a/patches/0084-disable-some-staging-dirs.patch
+++ b/patches/0084-disable-some-staging-dirs.patch
@@ -9,8 +9,8 @@
  obj-$(CONFIG_PRISM2_USB)	+= wlan-ng/
  obj-$(CONFIG_FB_OLPC_DCON)	+= olpc_dcon/
  obj-$(CONFIG_RTL8192U)		+= rtl8192u/
-@@ -42,4 +42,4 @@ obj-$(CONFIG_FIELDBUS_DEV)     += fieldb
- obj-$(CONFIG_KPC2000)		+= kpc2000/
+@@ -41,4 +41,4 @@ obj-$(CONFIG_XIL_AXIS_FIFO)	+= axis-fifo
+ obj-$(CONFIG_FIELDBUS_DEV)     += fieldbus/
  obj-$(CONFIG_QLGE)		+= qlge/
  obj-$(CONFIG_WFX)		+= wfx/
 -obj-y				+= hikey9xx/
diff --git a/patches/0097-skb-list/mac80211-rx.patch b/patches/0097-skb-list/mac80211-rx.patch
index bbfb9744..7806c70f 100644
--- a/patches/0097-skb-list/mac80211-rx.patch
+++ b/patches/0097-skb-list/mac80211-rx.patch
@@ -9,7 +9,7 @@ the older kernel instead. The list attributes where also backported to
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -4476,7 +4476,11 @@ void ieee80211_restart_hw(struct ieee802
+@@ -4500,7 +4500,11 @@ void ieee80211_restart_hw(struct ieee802
   * @list: the destination list
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *sta,
@@ -37,7 +37,7 @@ the older kernel instead. The list attributes where also backported to
  	struct ieee80211_sub_if_data *sdata;
 --- a/net/mac80211/rx.c
 +++ b/net/mac80211/rx.c
-@@ -2592,7 +2592,11 @@ static void ieee80211_deliver_skb_to_loc
+@@ -2604,7 +2604,11 @@ static void ieee80211_deliver_skb_to_loc
  
  		/* deliver to local stack */
  		if (rx->list)
diff --git a/patches/0097-skb-list/mac80211-status.patch b/patches/0097-skb-list/mac80211-status.patch
index 8f5ac983..c9a67103 100644
--- a/patches/0097-skb-list/mac80211-status.patch
+++ b/patches/0097-skb-list/mac80211-status.patch
@@ -7,7 +7,7 @@ kernel versions.
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -1135,7 +1135,11 @@ struct ieee80211_tx_status {
+@@ -1137,7 +1137,11 @@ struct ieee80211_tx_status {
  	struct ieee80211_tx_info *info;
  	struct sk_buff *skb;
  	struct rate_info *rate;
@@ -21,7 +21,7 @@ kernel versions.
  /**
 --- a/net/mac80211/status.c
 +++ b/net/mac80211/status.c
-@@ -1029,7 +1029,11 @@ static void __ieee80211_tx_status(struct
+@@ -1047,7 +1047,11 @@ static void __ieee80211_tx_status(struct
  	 */
  	if (!local->monitors && (!send_to_cooked || !local->cooked_mntrs)) {
  		if (status->free_list)
@@ -33,7 +33,7 @@ kernel versions.
  		else
  			dev_kfree_skb(skb);
  		return;
-@@ -1179,7 +1183,11 @@ free:
+@@ -1197,7 +1201,11 @@ free:
  
  	ieee80211_report_used_skb(local, skb, false);
  	if (status->free_list)
diff --git a/patches/0097-skb-list/mt76.patch b/patches/0097-skb-list/mt76.patch
index 890b4c3c..7ed0796e 100644
--- a/patches/0097-skb-list/mt76.patch
+++ b/patches/0097-skb-list/mt76.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mediatek/mt76/mac80211.c
 +++ b/drivers/net/wireless/mediatek/mt76/mac80211.c
-@@ -998,7 +998,13 @@ void mt76_rx_complete(struct mt76_dev *d
+@@ -1024,7 +1024,13 @@ void mt76_rx_complete(struct mt76_dev *d
  	struct ieee80211_sta *sta;
  	struct ieee80211_hw *hw;
  	struct sk_buff *skb, *tmp;
@@ -14,7 +14,7 @@
  
  	spin_lock(&dev->rx_lock);
  	while ((skb = __skb_dequeue(frames)) != NULL) {
-@@ -1030,8 +1036,13 @@ void mt76_rx_complete(struct mt76_dev *d
+@@ -1056,8 +1062,13 @@ void mt76_rx_complete(struct mt76_dev *d
  		return;
  	}
  
@@ -28,21 +28,35 @@
  		napi_gro_receive(napi, skb);
  	}
  }
+--- a/drivers/net/wireless/mediatek/mt76/mt76.h
++++ b/drivers/net/wireless/mediatek/mt76/mt76.h
+@@ -1089,7 +1089,11 @@ struct sk_buff *mt76_tx_status_skb_get(s
+ void mt76_tx_status_skb_done(struct mt76_dev *dev, struct sk_buff *skb,
+ 			     struct sk_buff_head *list);
+ void __mt76_tx_complete_skb(struct mt76_dev *dev, u16 wcid, struct sk_buff *skb,
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 			    struct list_head *free_list);
++#else
++			    struct sk_buff_head *free_list);
++#endif
+ static inline void
+ mt76_tx_complete_skb(struct mt76_dev *dev, u16 wcid, struct sk_buff *skb)
+ {
 --- a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
 +++ b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c
-@@ -1086,7 +1086,11 @@ mt7915_tx_check_aggr(struct ieee80211_st
+@@ -1104,7 +1104,11 @@ mt7915_txp_skb_unmap(struct mt76_dev *de
+ 
  static void
- mt7915_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
- 			  struct ieee80211_sta *sta, u8 stat,
+ mt7915_txwi_free(struct mt7915_dev *dev, struct mt76_txwi_cache *t,
 +#if LINUX_VERSION_IS_GEQ(4,19,0)
- 			  struct list_head *free_list)
+ 		 struct ieee80211_sta *sta, struct list_head *free_list)
 +#else
-+			  struct sk_buff_head *free_list)
++		 struct ieee80211_sta *sta, struct sk_buff_head *free_list)
 +#endif
  {
- 	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
- 	struct ieee80211_tx_status status = {
-@@ -1149,10 +1153,16 @@ void mt7915_mac_tx_free(struct mt7915_de
+ 	struct mt76_dev *mdev = &dev->mt76;
+ 	struct mt76_wcid *wcid;
+@@ -1141,10 +1145,16 @@ mt7915_mac_tx_free(struct mt7915_dev *de
  	struct mt76_phy *mphy_ext = mdev->phy2;
  	struct mt76_txwi_cache *txwi;
  	struct ieee80211_sta *sta = NULL;
@@ -60,7 +74,7 @@
  
  	/* clean DMA queues and unmap buffers first */
  	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
-@@ -1240,8 +1250,13 @@ void mt7915_mac_tx_free(struct mt7915_de
+@@ -1211,8 +1221,13 @@ mt7915_mac_tx_free(struct mt7915_dev *de
  
  	napi_consume_skb(skb, 1);
  
@@ -76,7 +90,7 @@
  }
 --- a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
 +++ b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c
-@@ -870,7 +870,11 @@ mt7921_tx_check_aggr(struct ieee80211_st
+@@ -929,7 +929,11 @@ mt7921_tx_check_aggr(struct ieee80211_st
  static void
  mt7921_tx_complete_status(struct mt76_dev *mdev, struct sk_buff *skb,
  			  struct ieee80211_sta *sta, u8 stat,
@@ -88,7 +102,7 @@
  {
  	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
  	struct ieee80211_tx_status status = {
-@@ -940,10 +944,16 @@ void mt7921_mac_tx_free(struct mt7921_de
+@@ -999,10 +1003,16 @@ void mt7921_mac_tx_free(struct mt7921_de
  	struct mt76_dev *mdev = &dev->mt76;
  	struct mt76_txwi_cache *txwi;
  	struct ieee80211_sta *sta = NULL;
@@ -106,7 +120,7 @@
  
  	/* clean DMA queues and unmap buffers first */
  	mt76_queue_tx_cleanup(dev, dev->mphy.q_tx[MT_TXQ_PSD], false);
-@@ -1021,8 +1031,13 @@ void mt7921_mac_tx_free(struct mt7921_de
+@@ -1080,8 +1090,13 @@ void mt7921_mac_tx_free(struct mt7921_de
  
  	napi_consume_skb(skb, 1);
  
@@ -120,3 +134,17 @@
  		napi_consume_skb(skb, 1);
  	}
  
+--- a/drivers/net/wireless/mediatek/mt76/tx.c
++++ b/drivers/net/wireless/mediatek/mt76/tx.c
+@@ -195,7 +195,11 @@ mt76_tx_check_non_aql(struct mt76_dev *d
+ }
+ 
+ void __mt76_tx_complete_skb(struct mt76_dev *dev, u16 wcid_idx, struct sk_buff *skb,
++#if LINUX_VERSION_IS_GEQ(4,19,0)
+ 			    struct list_head *free_list)
++#else
++			    struct sk_buff_head *free_list)
++#endif
+ {
+ 	struct ieee80211_tx_status status = {
+ 		.skb = skb,
diff --git a/patches/0100-revert-small_ops/mac80211.patch b/patches/0100-revert-small_ops/mac80211.patch
index c5e3bc84..e1ec9db1 100644
--- a/patches/0100-revert-small_ops/mac80211.patch
+++ b/patches/0100-revert-small_ops/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15039,9 +15039,11 @@ static const struct genl_ops nl80211_ops
+@@ -15047,9 +15047,11 @@ static const struct genl_ops nl80211_ops
  		/* can be retrieved by unprivileged users */
  		.internal_flags = NL80211_FLAG_NEED_WIPHY,
  	},
@@ -12,7 +12,7 @@
  	{
  		.cmd = NL80211_CMD_SET_WIPHY,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -15824,8 +15826,10 @@ static struct genl_family nl80211_fam __
+@@ -15832,8 +15834,10 @@ static struct genl_family nl80211_fam __
  	.module = THIS_MODULE,
  	.ops = nl80211_ops,
  	.n_ops = ARRAY_SIZE(nl80211_ops),
diff --git a/patches/0100-revert-small_ops/mac80211_hwsim.patch b/patches/0100-revert-small_ops/mac80211_hwsim.patch
index 6e8dff8c..a68428c0 100644
--- a/patches/0100-revert-small_ops/mac80211_hwsim.patch
+++ b/patches/0100-revert-small_ops/mac80211_hwsim.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mac80211_hwsim.c
 +++ b/drivers/net/wireless/mac80211_hwsim.c
-@@ -4069,7 +4069,11 @@ done:
+@@ -4066,7 +4066,11 @@ done:
  }
  
  /* Generic Netlink operations array */
@@ -12,7 +12,7 @@
  	{
  		.cmd = HWSIM_CMD_REGISTER,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -4113,8 +4117,13 @@ static struct genl_family hwsim_genl_fam
+@@ -4110,8 +4114,13 @@ static struct genl_family hwsim_genl_fam
  	.policy = hwsim_genl_policy,
  	.netnsok = true,
  	.module = THIS_MODULE,
diff --git a/patches/0101-net_device-threaded/mt76.patch b/patches/0101-net_device-threaded/mt76.patch
index 0aef6a1b..af155cec 100644
--- a/patches/0101-net_device-threaded/mt76.patch
+++ b/patches/0101-net_device-threaded/mt76.patch
@@ -29,7 +29,7 @@
  		debugfs_create_blob("otp", 0400, dir, &dev->otp);
 --- a/drivers/net/wireless/mediatek/mt76/dma.c
 +++ b/drivers/net/wireless/mediatek/mt76/dma.c
-@@ -643,7 +643,9 @@ mt76_dma_init(struct mt76_dev *dev,
+@@ -644,7 +644,9 @@ mt76_dma_init(struct mt76_dev *dev,
  	init_dummy_netdev(&dev->tx_napi_dev);
  	snprintf(dev->napi_dev.name, sizeof(dev->napi_dev.name), "%s",
  		 wiphy_name(dev->hw->wiphy));
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 27/47] headers: Add FW_ACTION_NOUEVENT and FW_ACTION_UEVENT
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (25 preceding siblings ...)
  2021-10-19 21:42 ` [PATCH 26/47] patches: Refresh on top of kernel 5.14.13 Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 28/47] headers: Add linux/wwan.h file Hauke Mehrtens
                   ` (20 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

FW_ACTION_NOHOTPLUG and FW_ACTION_HOTPLUG were renamed to
FW_ACTION_NOUEVENT and FW_ACTION_UEVENT in kernel 5.14.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/firmware.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/backport/backport-include/linux/firmware.h b/backport/backport-include/linux/firmware.h
index 7d41637c..c12ce98c 100644
--- a/backport/backport-include/linux/firmware.h
+++ b/backport/backport-include/linux/firmware.h
@@ -14,4 +14,12 @@ static inline int firmware_request_cache(struct device *device, const char *name
 }
 #endif
 
+#ifndef FW_ACTION_NOUEVENT
+#define FW_ACTION_NOUEVENT FW_ACTION_NOHOTPLUG
+#endif
+
+#ifndef FW_ACTION_UEVENT
+#define FW_ACTION_UEVENT FW_ACTION_HOTPLUG
+#endif
+
 #endif /* __BACKPORT_LINUX_FIRMWARE_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 28/47] headers: Add linux/wwan.h file
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (26 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 27/47] headers: Add FW_ACTION_NOUEVENT and FW_ACTION_UEVENT Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 29/47] headers: Add DEVICE_ATTR_ADMIN_RW Hauke Mehrtens
                   ` (19 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Add the linux/wwan.h header file from the new wwan subsystem. This adds
only the enum wwan_port_type which is also used when the wwan subsystem
is deactivated.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/wwan.h | 35 ++++++++++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 backport/backport-include/linux/wwan.h

diff --git a/backport/backport-include/linux/wwan.h b/backport/backport-include/linux/wwan.h
new file mode 100644
index 00000000..b3e4769f
--- /dev/null
+++ b/backport/backport-include/linux/wwan.h
@@ -0,0 +1,35 @@
+#ifndef __BACKPORT_WWAN_H
+#define __BACKPORT_WWAN_H
+#include <linux/version.h>
+#if LINUX_VERSION_IS_GEQ(5,13,0)
+#include_next <linux/wwan.h>
+#else
+
+/**
+ * enum wwan_port_type - WWAN port types
+ * @WWAN_PORT_AT: AT commands
+ * @WWAN_PORT_MBIM: Mobile Broadband Interface Model control
+ * @WWAN_PORT_QMI: Qcom modem/MSM interface for modem control
+ * @WWAN_PORT_QCDM: Qcom Modem diagnostic interface
+ * @WWAN_PORT_FIREHOSE: XML based command protocol
+ *
+ * @WWAN_PORT_MAX: Highest supported port types
+ * @WWAN_PORT_UNKNOWN: Special value to indicate an unknown port type
+ * @__WWAN_PORT_MAX: Internal use
+ */
+enum wwan_port_type {
+	WWAN_PORT_AT,
+	WWAN_PORT_MBIM,
+	WWAN_PORT_QMI,
+	WWAN_PORT_QCDM,
+	WWAN_PORT_FIREHOSE,
+
+	/* Add new port types above this line */
+
+	__WWAN_PORT_MAX,
+	WWAN_PORT_MAX = __WWAN_PORT_MAX - 1,
+	WWAN_PORT_UNKNOWN,
+};
+
+#endif /* >= 5.13 */
+#endif /* __BACKPORT_WWAN_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 29/47] headers: Add DEVICE_ATTR_ADMIN_RW
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (27 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 28/47] headers: Add linux/wwan.h file Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 30/47] headers: Add get_unaligned_be24 Hauke Mehrtens
                   ` (18 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The DEVICE_ATTR_ADMIN_RW define was added with kernel 5.9 and is now
used by ssb.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/device.h | 10 ++++++++++
 backport/backport-include/linux/sysfs.h  |  9 +++++++++
 2 files changed, 19 insertions(+)
 create mode 100644 backport/backport-include/linux/device.h

diff --git a/backport/backport-include/linux/device.h b/backport/backport-include/linux/device.h
new file mode 100644
index 00000000..46f2190b
--- /dev/null
+++ b/backport/backport-include/linux/device.h
@@ -0,0 +1,10 @@
+#ifndef __BACKPORT_DEVICE_H_
+#define __BACKPORT_DEVICE_H_
+#include_next <linux/device.h>
+
+#ifndef DEVICE_ATTR_ADMIN_RW
+#define DEVICE_ATTR_ADMIN_RW(_name) \
+	struct device_attribute dev_attr_##_name = __ATTR_RW_MODE(_name, 0600)
+#endif
+
+#endif /* __BACKPORT_DEVICE_H_ */
diff --git a/backport/backport-include/linux/sysfs.h b/backport/backport-include/linux/sysfs.h
index ad8a8229..7126fb03 100644
--- a/backport/backport-include/linux/sysfs.h
+++ b/backport/backport-include/linux/sysfs.h
@@ -22,4 +22,13 @@ static inline int sysfs_emit(char *buf, const char *fmt, ...)
 #endif /* CONFIG_SYSFS */
 #endif /* < 5.10 */
 
+#ifndef __ATTR_RW_MODE
+#define __ATTR_RW_MODE(_name, _mode) {					\
+	.attr	= { .name = __stringify(_name),				\
+		    .mode = VERIFY_OCTAL_PERMISSIONS(_mode) },		\
+	.show	= _name##_show,						\
+	.store	= _name##_store,					\
+}
+#endif
+
 #endif /* __BACKPORT_LINUX_SYSFS_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 30/47] headers: Add get_unaligned_be24
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (28 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 29/47] headers: Add DEVICE_ATTR_ADMIN_RW Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 31/47] headers: Add rbtree cached Hauke Mehrtens
                   ` (17 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The get_unaligned_be24 function was added with kernel 5.7 to the general
header files and is now used by rtl8723bs.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/asm/unaligned.h | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)
 create mode 100644 backport/backport-include/asm/unaligned.h

diff --git a/backport/backport-include/asm/unaligned.h b/backport/backport-include/asm/unaligned.h
new file mode 100644
index 00000000..4e2a6a41
--- /dev/null
+++ b/backport/backport-include/asm/unaligned.h
@@ -0,0 +1,17 @@
+#ifndef __BACKPORT_ASM_GENERIC_UNALIGNED_H
+#define __BACKPORT_ASM_GENERIC_UNALIGNED_H
+#include_next <asm/unaligned.h>
+
+#if LINUX_VERSION_IS_LESS(5,7,0)
+static inline u32 __get_unaligned_be24(const u8 *p)
+{
+	return p[0] << 16 | p[1] << 8 | p[2];
+}
+
+static inline u32 get_unaligned_be24(const void *p)
+{
+	return __get_unaligned_be24(p);
+}
+#endif /* < 5.7 */
+
+#endif /* __BACKPORT_ASM_GENERIC_UNALIGNED_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 31/47] headers: Add rbtree cached
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (29 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 30/47] headers: Add get_unaligned_be24 Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 32/47] headers: Adapt signature of hrtimer_forward_now() Hauke Mehrtens
                   ` (16 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This copies the version of the rbtree which caches the left most
element. This only needs extensions to the header files.

The cached version was initially integrated in kernel 4.14, but it was
changed to a header only extension in kernel 5.3, which is used here.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/rbtree.h | 59 ++++++++++++++++++++++++
 1 file changed, 59 insertions(+)
 create mode 100644 backport/backport-include/linux/rbtree.h

diff --git a/backport/backport-include/linux/rbtree.h b/backport/backport-include/linux/rbtree.h
new file mode 100644
index 00000000..a364f07b
--- /dev/null
+++ b/backport/backport-include/linux/rbtree.h
@@ -0,0 +1,59 @@
+#ifndef __BACKPORT_LINUX_RBTREE_H
+#define __BACKPORT_LINUX_RBTREE_H
+#include_next <linux/rbtree.h>
+
+#if LINUX_VERSION_IS_LESS(4,14,0)
+/*
+ * Leftmost-cached rbtrees.
+ *
+ * We do not cache the rightmost node based on footprint
+ * size vs number of potential users that could benefit
+ * from O(1) rb_last(). Just not worth it, users that want
+ * this feature can always implement the logic explicitly.
+ * Furthermore, users that want to cache both pointers may
+ * find it a bit asymmetric, but that's ok.
+ */
+struct rb_root_cached {
+	struct rb_root rb_root;
+	struct rb_node *rb_leftmost;
+};
+
+#define RB_ROOT_CACHED (struct rb_root_cached) { {NULL, }, NULL }
+
+/* Same as rb_first(), but O(1) */
+#define rb_first_cached(root) (root)->rb_leftmost
+
+static inline void rb_insert_color_cached(struct rb_node *node,
+					  struct rb_root_cached *root,
+					  bool leftmost)
+{
+	if (leftmost)
+		root->rb_leftmost = node;
+	rb_insert_color(node, &root->rb_root);
+}
+
+
+static inline struct rb_node *
+rb_erase_cached(struct rb_node *node, struct rb_root_cached *root)
+{
+	struct rb_node *leftmost = NULL;
+
+	if (root->rb_leftmost == node)
+		leftmost = root->rb_leftmost = rb_next(node);
+
+	rb_erase(node, &root->rb_root);
+
+	return leftmost;
+}
+
+static inline void rb_replace_node_cached(struct rb_node *victim,
+					  struct rb_node *new,
+					  struct rb_root_cached *root)
+{
+	if (root->rb_leftmost == victim)
+		root->rb_leftmost = new;
+	rb_replace_node(victim, new, &root->rb_root);
+}
+#endif
+
+#endif /* __BACKPORT_LINUX_RBTREE_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 32/47] headers: Adapt signature of hrtimer_forward_now()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (30 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 31/47] headers: Add rbtree cached Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 33/47] dependencies: Build RTL8723BS only on kernel >= 5.4 Hauke Mehrtens
                   ` (15 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The hrtimer_forward_now() function is now used by mac80211_hwsim.
In kernel 4.10 the type of the interval parameter of
hrtimer_forward_now() was changed from ktime_t to s64. This change
converts calls using the new version to the old one.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/interrupt.h | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/backport/backport-include/linux/interrupt.h b/backport/backport-include/linux/interrupt.h
index 41d50d7c..f42f2ddd 100644
--- a/backport/backport-include/linux/interrupt.h
+++ b/backport/backport-include/linux/interrupt.h
@@ -16,6 +16,15 @@ backport_hrtimer_forward(struct hrtimer *timer, ktime_t now, s64 interval)
 }
 #define hrtimer_forward LINUX_BACKPORT(hrtimer_forward)
 
+static inline u64
+backport_hrtimer_forward_now(struct hrtimer *timer, s64 interval)
+{
+	ktime_t _interval = { .tv64 = interval };
+
+	return hrtimer_forward_now(timer, _interval);
+}
+#define hrtimer_forward_now LINUX_BACKPORT(hrtimer_forward_now)
+
 static inline s64 backport_ns_to_ktime(u64 ns)
 {
 	ktime_t _time = ns_to_ktime(ns);
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 33/47] dependencies: Build RTL8723BS only on kernel >= 5.4
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (31 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 32/47] headers: Adapt signature of hrtimer_forward_now() Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 34/47] backports: Remove rtl8188eu driver Hauke Mehrtens
                   ` (14 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

RTL8723BS now uses aes_expandkey() and aes_encrypt(), which were only
added in kernel 5.4

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 dependencies | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dependencies b/dependencies
index 8f0ca5ef..d8c3f106 100644
--- a/dependencies
+++ b/dependencies
@@ -34,3 +34,6 @@ AIRO_CS 4.20
 
 # mt7915 testmode uses skb_copy_header()
 NL80211_TESTMODE 4.18
+
+# Needs aes_expandkey() and aes_encrypt()
+RTL8723BS 5.4
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 34/47] backports: Remove rtl8188eu driver
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (32 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 33/47] dependencies: Build RTL8723BS only on kernel >= 5.4 Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 35/47] backports: Remove prism54 driver Hauke Mehrtens
                   ` (13 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This driver was removed from upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/defconfigs/wifi                  |  1 -
 copy-list                                 |  1 -
 patches/0028-select_queue/rtl8188eu.patch | 21 ---------------------
 3 files changed, 23 deletions(-)
 delete mode 100644 patches/0028-select_queue/rtl8188eu.patch

diff --git a/backport/defconfigs/wifi b/backport/defconfigs/wifi
index 8f7b9f58..86e3bd6e 100644
--- a/backport/defconfigs/wifi
+++ b/backport/defconfigs/wifi
@@ -85,7 +85,6 @@ CPTCFG_PCMCIA_SPECTRUM=m
 CPTCFG_PLX_HERMES=m
 CPTCFG_RSI_91X=m
 CPTCFG_QTNFMAC_PCIE=m
-CPTCFG_R8188EU=m
 CPTCFG_RT2400PCI=m
 CPTCFG_RT2500PCI=m
 CPTCFG_RT2500USB=m
diff --git a/copy-list b/copy-list
index 8c787e06..63ea7eda 100644
--- a/copy-list
+++ b/copy-list
@@ -124,7 +124,6 @@ drivers/net/usb/usbnet.c
 
 drivers/staging/Makefile
 drivers/staging/Kconfig
-drivers/staging/rtl8188eu/
 drivers/staging/rtl8723bs/
 
 drivers/usb/class/Makefile
diff --git a/patches/0028-select_queue/rtl8188eu.patch b/patches/0028-select_queue/rtl8188eu.patch
deleted file mode 100644
index 7d3c7b95..00000000
--- a/patches/0028-select_queue/rtl8188eu.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/drivers/staging/rtl8188eu/os_dep/os_intfs.c
-+++ b/drivers/staging/rtl8188eu/os_dep/os_intfs.c
-@@ -243,8 +243,18 @@ static unsigned int rtw_classify8021d(st
- 	return dscp >> 5;
- }
- 
-+#if LINUX_VERSION_IS_GEQ(5,2,0)
- static u16 rtw_select_queue(struct net_device *dev, struct sk_buff *skb,
- 			    struct net_device *sb_dev)
-+#elif LINUX_VERSION_IS_GEQ(4,19,0)
-+static u16 rtw_select_queue(struct net_device *dev, struct sk_buff *skb,
-+			    struct net_device *sb_dev,
-+			    select_queue_fallback_t fallback)
-+#else
-+static u16 rtw_select_queue(struct net_device *dev, struct sk_buff *skb,
-+			    void *accel_priv,
-+			    select_queue_fallback_t fallback)
-+#endif
- {
- 	struct adapter *padapter = netdev_priv(dev);
- 	struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 35/47] backports: Remove prism54 driver
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (33 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 34/47] backports: Remove rtl8188eu driver Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 36/47] patches: Refresh on top of kernel 5.15-rc6 Hauke Mehrtens
                   ` (12 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This driver was removed from upstream kernel.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/defconfigs/wifi                  |  1 -
 patches/0094-ndo-tx-timeout/prism54.patch | 23 -----------------------
 2 files changed, 24 deletions(-)
 delete mode 100644 patches/0094-ndo-tx-timeout/prism54.patch

diff --git a/backport/defconfigs/wifi b/backport/defconfigs/wifi
index 86e3bd6e..ea0aee71 100644
--- a/backport/defconfigs/wifi
+++ b/backport/defconfigs/wifi
@@ -76,7 +76,6 @@ CPTCFG_P54_COMMON=m
 CPTCFG_P54_PCI=m
 CPTCFG_P54_SPI=m
 CPTCFG_P54_USB=m
-CPTCFG_PRISM54=m
 CPTCFG_PCI_ATMEL=m
 CPTCFG_PCI_HERMES=m
 CPTCFG_PCMCIA_ATMEL=m
diff --git a/patches/0094-ndo-tx-timeout/prism54.patch b/patches/0094-ndo-tx-timeout/prism54.patch
deleted file mode 100644
index 1e55f03c..00000000
--- a/patches/0094-ndo-tx-timeout/prism54.patch
+++ /dev/null
@@ -1,23 +0,0 @@
---- a/drivers/net/wireless/intersil/prism54/islpci_eth.h
-+++ b/drivers/net/wireless/intersil/prism54/islpci_eth.h
-@@ -54,6 +54,7 @@ void islpci_eth_cleanup_transmit(islpci_
- netdev_tx_t islpci_eth_transmit(struct sk_buff *, struct net_device *);
- int islpci_eth_receive(islpci_private *);
- void islpci_eth_tx_timeout(struct net_device *, unsigned int txqueue);
-+void bp_islpci_eth_tx_timeout(struct net_device *);
- void islpci_do_reset_and_wake(struct work_struct *);
- 
- #endif				/* _ISL_GEN_H */
---- a/drivers/net/wireless/intersil/prism54/islpci_eth.c
-+++ b/drivers/net/wireless/intersil/prism54/islpci_eth.c
-@@ -487,3 +487,10 @@ islpci_eth_tx_timeout(struct net_device
- 			"%s: tx_timeout, waiting for reset", ndev->name);
- 	}
- }
-+
-+#if LINUX_VERSION_IS_LESS(5,6,0)
-+void bp_islpci_eth_tx_timeout(struct net_device *dev) {
-+	islpci_eth_tx_timeout(dev, 0);
-+}
-+EXPORT_SYMBOL_GPL(bp_islpci_eth_tx_timeout);
-+#endif
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 36/47] patches: Refresh on top of kernel 5.15-rc6
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (34 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 35/47] backports: Remove prism54 driver Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 37/47] backports: Remove old CISCO airo driver Hauke Mehrtens
                   ` (11 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 .../include_net_cfg80211.patch                 |  2 +-
 patches/0028-select_queue/mac80211.patch       |  4 ++--
 patches/0028-select_queue/rtl8723bs.patch      |  2 +-
 patches/0077-genl-ro-after-init/nl80211.patch  |  2 +-
 patches/0084-disable-some-staging-dirs.patch   |  6 ------
 patches/0095-spi-delay/wilc1000.patch          |  6 +++---
 patches/0097-skb-list/mac80211-rx.patch        | 18 +++++++++---------
 patches/0097-skb-list/mac80211-status.patch    |  4 ++--
 patches/0100-revert-small_ops/mac80211.patch   |  4 ++--
 9 files changed, 21 insertions(+), 27 deletions(-)

diff --git a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
index 0f3e7431..a8040774 100644
--- a/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
+++ b/patches/0003-cfg80211-wext-padding/include_net_cfg80211.patch
@@ -1,6 +1,6 @@
 --- a/include/net/cfg80211.h
 +++ b/include/net/cfg80211.h
-@@ -4961,6 +4961,9 @@ struct wiphy {
+@@ -4987,6 +4987,9 @@ struct wiphy {
  
  	/* assign these fields before you register the wiphy */
  
diff --git a/patches/0028-select_queue/mac80211.patch b/patches/0028-select_queue/mac80211.patch
index 36738162..64a397b9 100644
--- a/patches/0028-select_queue/mac80211.patch
+++ b/patches/0028-select_queue/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/mac80211/iface.c
 +++ b/net/mac80211/iface.c
-@@ -695,9 +695,21 @@ static void ieee80211_uninit(struct net_
+@@ -697,9 +697,21 @@ static void ieee80211_uninit(struct net_
  	ieee80211_teardown_sdata(IEEE80211_DEV_TO_SUB_IF(dev));
  }
  
@@ -22,7 +22,7 @@
  {
  	return ieee80211_select_queue(IEEE80211_DEV_TO_SUB_IF(dev), skb);
  }
-@@ -719,9 +731,21 @@ static const struct net_device_ops ieee8
+@@ -721,9 +733,21 @@ static const struct net_device_ops ieee8
  	.ndo_get_stats64	= ieee80211_get_stats64,
  };
  
diff --git a/patches/0028-select_queue/rtl8723bs.patch b/patches/0028-select_queue/rtl8723bs.patch
index f19199b6..f32fd41f 100644
--- a/patches/0028-select_queue/rtl8723bs.patch
+++ b/patches/0028-select_queue/rtl8723bs.patch
@@ -1,6 +1,6 @@
 --- a/drivers/staging/rtl8723bs/os_dep/os_intfs.c
 +++ b/drivers/staging/rtl8723bs/os_dep/os_intfs.c
-@@ -363,8 +363,18 @@ static unsigned int rtw_classify8021d(st
+@@ -341,8 +341,18 @@ static unsigned int rtw_classify8021d(st
  }
  
  
diff --git a/patches/0077-genl-ro-after-init/nl80211.patch b/patches/0077-genl-ro-after-init/nl80211.patch
index 84cb42a8..aff82a2b 100644
--- a/patches/0077-genl-ro-after-init/nl80211.patch
+++ b/patches/0077-genl-ro-after-init/nl80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15803,7 +15803,7 @@ static const struct genl_small_ops nl802
+@@ -15909,7 +15909,7 @@ static const struct genl_small_ops nl802
  	},
  };
  
diff --git a/patches/0084-disable-some-staging-dirs.patch b/patches/0084-disable-some-staging-dirs.patch
index 74abcff1..8018addc 100644
--- a/patches/0084-disable-some-staging-dirs.patch
+++ b/patches/0084-disable-some-staging-dirs.patch
@@ -9,9 +9,3 @@
  obj-$(CONFIG_PRISM2_USB)	+= wlan-ng/
  obj-$(CONFIG_FB_OLPC_DCON)	+= olpc_dcon/
  obj-$(CONFIG_RTL8192U)		+= rtl8192u/
-@@ -41,4 +41,4 @@ obj-$(CONFIG_XIL_AXIS_FIFO)	+= axis-fifo
- obj-$(CONFIG_FIELDBUS_DEV)     += fieldbus/
- obj-$(CONFIG_QLGE)		+= qlge/
- obj-$(CONFIG_WFX)		+= wfx/
--obj-y				+= hikey9xx/
-+#obj-y				+= hikey9xx/
diff --git a/patches/0095-spi-delay/wilc1000.patch b/patches/0095-spi-delay/wilc1000.patch
index 56bbaf9a..1cf5014b 100644
--- a/patches/0095-spi-delay/wilc1000.patch
+++ b/patches/0095-spi-delay/wilc1000.patch
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/microchip/wilc1000/spi.c
 +++ b/drivers/net/wireless/microchip/wilc1000/spi.c
-@@ -213,10 +213,14 @@ static int wilc_spi_tx(struct wilc *wilc
+@@ -217,10 +217,14 @@ static int wilc_spi_tx(struct wilc *wilc
  		struct spi_transfer tr = {
  			.tx_buf = b,
  			.len = len,
@@ -15,7 +15,7 @@
  		};
  		char *r_buffer = kzalloc(len, GFP_KERNEL);
  
-@@ -257,10 +261,14 @@ static int wilc_spi_rx(struct wilc *wilc
+@@ -261,10 +265,14 @@ static int wilc_spi_rx(struct wilc *wilc
  		struct spi_transfer tr = {
  			.rx_buf = rb,
  			.len = rlen,
@@ -30,7 +30,7 @@
  
  		};
  		char *t_buffer = kzalloc(rlen, GFP_KERNEL);
-@@ -302,10 +310,14 @@ static int wilc_spi_tx_rx(struct wilc *w
+@@ -306,10 +314,14 @@ static int wilc_spi_tx_rx(struct wilc *w
  			.tx_buf = wb,
  			.len = rlen,
  			.bits_per_word = 8,
diff --git a/patches/0097-skb-list/mac80211-rx.patch b/patches/0097-skb-list/mac80211-rx.patch
index 7806c70f..c4c22bb3 100644
--- a/patches/0097-skb-list/mac80211-rx.patch
+++ b/patches/0097-skb-list/mac80211-rx.patch
@@ -9,7 +9,7 @@ the older kernel instead. The list attributes where also backported to
 
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -4500,7 +4500,11 @@ void ieee80211_restart_hw(struct ieee802
+@@ -4519,7 +4519,11 @@ void ieee80211_restart_hw(struct ieee802
   * @list: the destination list
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *sta,
@@ -23,7 +23,7 @@ the older kernel instead. The list attributes where also backported to
   * ieee80211_rx_napi - receive frame from NAPI context
 --- a/net/mac80211/ieee80211_i.h
 +++ b/net/mac80211/ieee80211_i.h
-@@ -199,7 +199,11 @@ enum ieee80211_rx_flags {
+@@ -200,7 +200,11 @@ enum ieee80211_rx_flags {
  };
  
  struct ieee80211_rx_data {
@@ -37,7 +37,7 @@ the older kernel instead. The list attributes where also backported to
  	struct ieee80211_sub_if_data *sdata;
 --- a/net/mac80211/rx.c
 +++ b/net/mac80211/rx.c
-@@ -2604,7 +2604,11 @@ static void ieee80211_deliver_skb_to_loc
+@@ -2609,7 +2609,11 @@ static void ieee80211_deliver_skb_to_loc
  
  		/* deliver to local stack */
  		if (rx->list)
@@ -49,7 +49,7 @@ the older kernel instead. The list attributes where also backported to
  		else
  			netif_receive_skb(skb);
  	}
-@@ -4441,7 +4445,11 @@ static void ieee80211_rx_8023(struct iee
+@@ -4519,7 +4523,11 @@ static void ieee80211_rx_8023(struct iee
  	skb->protocol = eth_type_trans(skb, fast_rx->dev);
  	memset(skb->cb, 0, sizeof(skb->cb));
  	if (rx->list)
@@ -61,7 +61,7 @@ the older kernel instead. The list attributes where also backported to
  	else
  		netif_receive_skb(skb);
  
-@@ -4623,7 +4631,11 @@ static bool ieee80211_prepare_and_rx_han
+@@ -4701,7 +4709,11 @@ static bool ieee80211_prepare_and_rx_han
  static void __ieee80211_rx_handle_8023(struct ieee80211_hw *hw,
  				       struct ieee80211_sta *pubsta,
  				       struct sk_buff *skb,
@@ -73,7 +73,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_fast_rx *fast_rx;
-@@ -4664,7 +4676,11 @@ drop:
+@@ -4742,7 +4754,11 @@ drop:
  static void __ieee80211_rx_handle_packet(struct ieee80211_hw *hw,
  					 struct ieee80211_sta *pubsta,
  					 struct sk_buff *skb,
@@ -85,7 +85,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_sub_if_data *sdata;
-@@ -4789,7 +4805,11 @@ static void __ieee80211_rx_handle_packet
+@@ -4867,7 +4883,11 @@ static void __ieee80211_rx_handle_packet
   * 802.11 MPDU is received from the hardware.
   */
  void ieee80211_rx_list(struct ieee80211_hw *hw, struct ieee80211_sta *pubsta,
@@ -97,7 +97,7 @@ the older kernel instead. The list attributes where also backported to
  {
  	struct ieee80211_local *local = hw_to_local(hw);
  	struct ieee80211_rate *rate = NULL;
-@@ -4912,7 +4932,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -4990,7 +5010,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		       struct sk_buff *skb, struct napi_struct *napi)
  {
  	struct sk_buff *tmp;
@@ -111,7 +111,7 @@ the older kernel instead. The list attributes where also backported to
  
  
  	/*
-@@ -4929,8 +4955,13 @@ void ieee80211_rx_napi(struct ieee80211_
+@@ -5007,8 +5033,13 @@ void ieee80211_rx_napi(struct ieee80211_
  		return;
  	}
  
diff --git a/patches/0097-skb-list/mac80211-status.patch b/patches/0097-skb-list/mac80211-status.patch
index c9a67103..04d1a6af 100644
--- a/patches/0097-skb-list/mac80211-status.patch
+++ b/patches/0097-skb-list/mac80211-status.patch
@@ -21,7 +21,7 @@ kernel versions.
  /**
 --- a/net/mac80211/status.c
 +++ b/net/mac80211/status.c
-@@ -1047,7 +1047,11 @@ static void __ieee80211_tx_status(struct
+@@ -1060,7 +1060,11 @@ static void __ieee80211_tx_status(struct
  	 */
  	if (!local->monitors && (!send_to_cooked || !local->cooked_mntrs)) {
  		if (status->free_list)
@@ -33,7 +33,7 @@ kernel versions.
  		else
  			dev_kfree_skb(skb);
  		return;
-@@ -1197,7 +1201,11 @@ free:
+@@ -1210,7 +1214,11 @@ free:
  
  	ieee80211_report_used_skb(local, skb, false);
  	if (status->free_list)
diff --git a/patches/0100-revert-small_ops/mac80211.patch b/patches/0100-revert-small_ops/mac80211.patch
index e1ec9db1..294af180 100644
--- a/patches/0100-revert-small_ops/mac80211.patch
+++ b/patches/0100-revert-small_ops/mac80211.patch
@@ -1,6 +1,6 @@
 --- a/net/wireless/nl80211.c
 +++ b/net/wireless/nl80211.c
-@@ -15047,9 +15047,11 @@ static const struct genl_ops nl80211_ops
+@@ -15145,9 +15145,11 @@ static const struct genl_ops nl80211_ops
  		/* can be retrieved by unprivileged users */
  		.internal_flags = NL80211_FLAG_NEED_WIPHY,
  	},
@@ -12,7 +12,7 @@
  	{
  		.cmd = NL80211_CMD_SET_WIPHY,
  		.validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-@@ -15832,8 +15834,10 @@ static struct genl_family nl80211_fam __
+@@ -15938,8 +15940,10 @@ static struct genl_family nl80211_fam __
  	.module = THIS_MODULE,
  	.ops = nl80211_ops,
  	.n_ops = ARRAY_SIZE(nl80211_ops),
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 37/47] backports: Remove old CISCO airo driver
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (35 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 36/47] patches: Refresh on top of kernel 5.15-rc6 Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 38/47] backports: Remove intersil hostap driver Hauke Mehrtens
                   ` (10 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This driver only support very old 802.11b wifi chips.
It now uses the new callback ndo_siocdevprivate. There are probably not
many users of these device any more, so just remove this driver.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/defconfigs/wifi | 3 ---
 copy-list                | 1 -
 2 files changed, 4 deletions(-)

diff --git a/backport/defconfigs/wifi b/backport/defconfigs/wifi
index ea0aee71..4a3fbd28 100644
--- a/backport/defconfigs/wifi
+++ b/backport/defconfigs/wifi
@@ -1,7 +1,5 @@
 CPTCFG_ADM8211=m
 CPTCFG_AR5523=m
-CPTCFG_AIRO=m
-CPTCFG_AIRO_CS=m
 CPTCFG_AT76C50X_USB=m
 CPTCFG_ATH10K=m
 CPTCFG_ATH10K_PCI=m
@@ -134,7 +132,6 @@ CPTCFG_WLAN_VENDOR_ADMTEK=y
 CPTCFG_WLAN_VENDOR_ATH=y
 CPTCFG_WLAN_VENDOR_ATMEL=y
 CPTCFG_WLAN_VENDOR_BROADCOM=y
-CPTCFG_WLAN_VENDOR_CISCO=y
 CPTCFG_WLAN_VENDOR_INTEL=y
 CPTCFG_WLAN_VENDOR_INTERSIL=y
 CPTCFG_WLAN_VENDOR_MARVELL=y
diff --git a/copy-list b/copy-list
index 63ea7eda..c21596f8 100644
--- a/copy-list
+++ b/copy-list
@@ -96,7 +96,6 @@ drivers/ssb/
 include/linux/ssb/
 drivers/bcma/
 include/linux/bcma/
-drivers/net/wireless/cisco/
 drivers/net/wireless/atmel/
 drivers/net/wireless/broadcom/
 drivers/net/wireless/st/
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 38/47] backports: Remove intersil hostap driver
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (36 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 37/47] backports: Remove old CISCO airo driver Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 39/47] patches: Adapt signature of bus_type->remove callback Hauke Mehrtens
                   ` (9 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This removes the old hostap driver which only supports 802.11b devices.
It now uses the new callback ndo_siocdevprivate. There are probably not
many users of these device any more, so just remove this driver.

This does not remove hostapd suport for other dveices.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 copy-list | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/copy-list b/copy-list
index c21596f8..b9fdd2ff 100644
--- a/copy-list
+++ b/copy-list
@@ -104,7 +104,10 @@ drivers/net/wireless/ralink/
 drivers/net/wireless/zydas/
 drivers/net/wireless/marvell/
 drivers/net/wireless/microchip/
-drivers/net/wireless/intersil/
+drivers/net/wireless/intersil/Kconfig
+drivers/net/wireless/intersil/Makefile
+drivers/net/wireless/intersil/orinoco/
+drivers/net/wireless/intersil/p54/
 drivers/net/wireless/quantenna/
 drivers/net/wireless/realtek/
 drivers/net/wireless/ti/
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 39/47] patches: Adapt signature of bus_type->remove callback
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (37 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 38/47] backports: Remove intersil hostap driver Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 40/47] patches: Adapt signature of ethtool_ops->set_coalesce callback Hauke Mehrtens
                   ` (8 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

With kernel 5.15 the return type of the bus_type->remove callback was
changed from int to void.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0102-remove-callback.patch | 63 ++++++++++++++++++++++++++++++
 1 file changed, 63 insertions(+)
 create mode 100644 patches/0102-remove-callback.patch

diff --git a/patches/0102-remove-callback.patch b/patches/0102-remove-callback.patch
new file mode 100644
index 00000000..9f5a54f1
--- /dev/null
+++ b/patches/0102-remove-callback.patch
@@ -0,0 +1,63 @@
+--- a/drivers/bcma/main.c
++++ b/drivers/bcma/main.c
+@@ -28,6 +28,7 @@ static DEFINE_MUTEX(bcma_buses_mutex);
+ static int bcma_bus_match(struct device *dev, struct device_driver *drv);
+ static int bcma_device_probe(struct device *dev);
+ static void bcma_device_remove(struct device *dev);
++static int bcma_device_remove_bp(struct device *dev);
+ static int bcma_device_uevent(struct device *dev, struct kobj_uevent_env *env);
+ 
+ static ssize_t manuf_show(struct device *dev, struct device_attribute *attr, char *buf)
+@@ -71,7 +72,11 @@ static struct bus_type bcma_bus_type = {
+ 	.name		= "bcma",
+ 	.match		= bcma_bus_match,
+ 	.probe		= bcma_device_probe,
++#if LINUX_VERSION_IS_GEQ(5,15,0)
+ 	.remove		= bcma_device_remove,
++#else
++	.remove		= bcma_device_remove_bp,
++#endif
+ 	.uevent		= bcma_device_uevent,
+ 	.dev_groups	= bcma_device_groups,
+ };
+@@ -625,6 +630,12 @@ static void bcma_device_remove(struct de
+ 	put_device(dev);
+ }
+ 
++static int bcma_device_remove_bp(struct device *dev)
++{
++	bcma_device_remove(dev);
++	return 0;
++}
++
+ static int bcma_device_uevent(struct device *dev, struct kobj_uevent_env *env)
+ {
+ 	struct bcma_device *core = container_of(dev, struct bcma_device, dev);
+--- a/drivers/ssb/main.c
++++ b/drivers/ssb/main.c
+@@ -293,6 +293,13 @@ static void ssb_device_remove(struct dev
+ 	ssb_device_put(ssb_dev);
+ }
+ 
++static int ssb_device_remove_bp(struct device *dev)
++{
++	ssb_device_remove(dev);
++
++	return 0;
++}
++
+ static int ssb_device_probe(struct device *dev)
+ {
+ 	struct ssb_device *ssb_dev = dev_to_ssb_dev(dev);
+@@ -388,7 +395,11 @@ static struct bus_type ssb_bustype = {
+ 	.name		= "ssb",
+ 	.match		= ssb_bus_match,
+ 	.probe		= ssb_device_probe,
++#if LINUX_VERSION_IS_GEQ(5,15,0)
+ 	.remove		= ssb_device_remove,
++#else
++	.remove		= ssb_device_remove_bp,
++#endif
+ 	.shutdown	= ssb_device_shutdown,
+ 	.suspend	= ssb_device_suspend,
+ 	.resume		= ssb_device_resume,
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 40/47] patches: Adapt signature of ethtool_ops->set_coalesce callback
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (38 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 39/47] patches: Adapt signature of bus_type->remove callback Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 41/47] patches: Do not set mhi_controller->reg_len on older kernel versions Hauke Mehrtens
                   ` (7 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

With kernel 5.15 ethtool_ops->set_coalesce and ethtool_ops->get_coalesce
callback function got extra parameters. Add a patch to handle this.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0103-ethtool-coalesce.patch | 36 +++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100644 patches/0103-ethtool-coalesce.patch

diff --git a/patches/0103-ethtool-coalesce.patch b/patches/0103-ethtool-coalesce.patch
new file mode 100644
index 00000000..a41b9c4b
--- /dev/null
+++ b/patches/0103-ethtool-coalesce.patch
@@ -0,0 +1,36 @@
+--- a/drivers/net/wireless/ath/wil6210/ethtool.c
++++ b/drivers/net/wireless/ath/wil6210/ethtool.c
+@@ -11,11 +11,16 @@
+ 
+ #include "wil6210.h"
+ 
++#if LINUX_VERSION_IS_GEQ(5,15,0)
+ static int
+ wil_ethtoolops_get_coalesce(struct net_device *ndev,
+ 			    struct ethtool_coalesce *cp,
+ 			    struct kernel_ethtool_coalesce *kernel_coal,
+ 			    struct netlink_ext_ack *extack)
++#else
++static int wil_ethtoolops_get_coalesce(struct net_device *ndev,
++				       struct ethtool_coalesce *cp)
++#endif
+ {
+ 	struct wil6210_priv *wil = ndev_to_wil(ndev);
+ 	u32 tx_itr_en, tx_itr_val = 0;
+@@ -48,11 +53,16 @@ out:
+ 	return ret;
+ }
+ 
++#if LINUX_VERSION_IS_GEQ(5,15,0)
+ static int
+ wil_ethtoolops_set_coalesce(struct net_device *ndev,
+ 			    struct ethtool_coalesce *cp,
+ 			    struct kernel_ethtool_coalesce *kernel_coal,
+ 			    struct netlink_ext_ack *extack)
++#else
++static int wil_ethtoolops_set_coalesce(struct net_device *ndev,
++				       struct ethtool_coalesce *cp)
++#endif
+ {
+ 	struct wil6210_priv *wil = ndev_to_wil(ndev);
+ 	struct wireless_dev *wdev = ndev->ieee80211_ptr;
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 41/47] patches: Do not set mhi_controller->reg_len on older kernel versions
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (39 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 40/47] patches: Adapt signature of ethtool_ops->set_coalesce callback Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 42/47] backports: Update wifi defconfig Hauke Mehrtens
                   ` (6 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

With kernel 5.15 struct mhi_controller got a new attribute reg_len to
check that the register length is correct. Do not set it on older kernel
versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0104-mhi-reg-len.patch | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 patches/0104-mhi-reg-len.patch

diff --git a/patches/0104-mhi-reg-len.patch b/patches/0104-mhi-reg-len.patch
new file mode 100644
index 00000000..32d1e55a
--- /dev/null
+++ b/patches/0104-mhi-reg-len.patch
@@ -0,0 +1,12 @@
+--- a/drivers/net/wireless/ath/ath11k/mhi.c
++++ b/drivers/net/wireless/ath/ath11k/mhi.c
+@@ -330,7 +330,9 @@ int ath11k_mhi_register(struct ath11k_pc
+ 	mhi_ctrl->cntrl_dev = ab->dev;
+ 	mhi_ctrl->fw_image = ab_pci->amss_path;
+ 	mhi_ctrl->regs = ab->mem;
++#if LINUX_VERSION_IS_GEQ(5,15,0)
+ 	mhi_ctrl->reg_len = ab->mem_len;
++#endif
+ 
+ 	ret = ath11k_mhi_get_msi(ab_pci);
+ 	if (ret) {
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 42/47] backports: Update wifi defconfig
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (40 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 41/47] patches: Do not set mhi_controller->reg_len on older kernel versions Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 43/47] backports: Add new r8188eu driver Hauke Mehrtens
                   ` (5 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This adds some  missing config options and sorts the configuration. The
drivers for the new configuration options were added in the last
years.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/defconfigs/wifi | 22 +++++++++++++++++-----
 1 file changed, 17 insertions(+), 5 deletions(-)

diff --git a/backport/defconfigs/wifi b/backport/defconfigs/wifi
index 4a3fbd28..be74147d 100644
--- a/backport/defconfigs/wifi
+++ b/backport/defconfigs/wifi
@@ -5,6 +5,8 @@ CPTCFG_ATH10K=m
 CPTCFG_ATH10K_PCI=m
 CPTCFG_ATH10K_SDIO=m
 CPTCFG_ATH10K_USB=m
+CPTCFG_ATH11K=m
+CPTCFG_ATH11K_PCI=m
 CPTCFG_ATH5K=m
 CPTCFG_ATH6KL=m
 CPTCFG_ATH6KL_SDIO=m
@@ -59,10 +61,14 @@ CPTCFG_MAC80211_MESH=y
 CPTCFG_MT7601U=m
 CPTCFG_MT7603E=m
 CPTCFG_MT7615E=m
+CPTCFG_MT7663S=m
+CPTCFG_MT7663U=m
 CPTCFG_MT76x0E=m
 CPTCFG_MT76x0U=m
 CPTCFG_MT76x2E=m
 CPTCFG_MT76x2U=m
+CPTCFG_MT7915E=m
+CPTCFG_MT7921E=m
 CPTCFG_MWIFIEX=m
 CPTCFG_MWIFIEX_PCIE=m
 CPTCFG_MWIFIEX_SDIO=m
@@ -80,8 +86,8 @@ CPTCFG_PCMCIA_ATMEL=m
 CPTCFG_PCMCIA_HERMES=m
 CPTCFG_PCMCIA_SPECTRUM=m
 CPTCFG_PLX_HERMES=m
-CPTCFG_RSI_91X=m
 CPTCFG_QTNFMAC_PCIE=m
+CPTCFG_RSI_91X=m
 CPTCFG_RT2400PCI=m
 CPTCFG_RT2500PCI=m
 CPTCFG_RT2500USB=m
@@ -109,6 +115,10 @@ CPTCFG_RTL8723BS=m
 CPTCFG_RTL8821AE=m
 CPTCFG_RTL8XXXU=m
 CPTCFG_RTLWIFI=m
+CPTCFG_RTW88_8723DE=m
+CPTCFG_RTW88_8821CE=m
+CPTCFG_RTW88_8822BE=m
+CPTCFG_RTW88_8822CE=m
 CPTCFG_RTW88=m
 CPTCFG_SSB=m
 CPTCFG_SSB_PCMCIAHOST=y
@@ -119,15 +129,13 @@ CPTCFG_USB_NET_RNDIS_WLAN=m
 CPTCFG_USB_ZD1201=m
 CPTCFG_WCN36XX=m
 CPTCFG_WIL6210=m
+CPTCFG_WILC1000_SDIO=m
+CPTCFG_WILC1000_SPI=m
 CPTCFG_WL1251=m
 CPTCFG_WL1251_SDIO=m
 CPTCFG_WL1251_SPI=m
 CPTCFG_WL12XX=m
 CPTCFG_WL18XX=m
-CPTCFG_WLAN=y
-CPTCFG_WLCORE=m
-CPTCFG_WLCORE_SDIO=m
-CPTCFG_WLCORE_SPI=m
 CPTCFG_WLAN_VENDOR_ADMTEK=y
 CPTCFG_WLAN_VENDOR_ATH=y
 CPTCFG_WLAN_VENDOR_ATMEL=y
@@ -143,4 +151,8 @@ CPTCFG_WLAN_VENDOR_RSI=y
 CPTCFG_WLAN_VENDOR_ST=y
 CPTCFG_WLAN_VENDOR_TI=y
 CPTCFG_WLAN_VENDOR_ZYDAS=y
+CPTCFG_WLAN=y
+CPTCFG_WLCORE=m
+CPTCFG_WLCORE_SDIO=m
+CPTCFG_WLCORE_SPI=m
 CPTCFG_ZD1211RW=m
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 43/47] backports: Add new r8188eu driver
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (41 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 42/47] backports: Update wifi defconfig Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 44/47] headers: Add new include/linux/bits.h Hauke Mehrtens
                   ` (4 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

This driver replaces the rtl8188eu driver which was removed upstream.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/defconfigs/wifi                       |  1 +
 copy-list                                      |  1 +
 .../0013-fix-makefile-includes/r8188eu.patch   | 12 ++++++++++++
 patches/0028-select_queue/r8188eu.patch        | 18 ++++++++++++++++++
 4 files changed, 32 insertions(+)
 create mode 100644 patches/0013-fix-makefile-includes/r8188eu.patch
 create mode 100644 patches/0028-select_queue/r8188eu.patch

diff --git a/backport/defconfigs/wifi b/backport/defconfigs/wifi
index be74147d..936203d9 100644
--- a/backport/defconfigs/wifi
+++ b/backport/defconfigs/wifi
@@ -87,6 +87,7 @@ CPTCFG_PCMCIA_HERMES=m
 CPTCFG_PCMCIA_SPECTRUM=m
 CPTCFG_PLX_HERMES=m
 CPTCFG_QTNFMAC_PCIE=m
+CPTCFG_R8188EU=m
 CPTCFG_RSI_91X=m
 CPTCFG_RT2400PCI=m
 CPTCFG_RT2500PCI=m
diff --git a/copy-list b/copy-list
index b9fdd2ff..be8539d4 100644
--- a/copy-list
+++ b/copy-list
@@ -126,6 +126,7 @@ drivers/net/usb/usbnet.c
 
 drivers/staging/Makefile
 drivers/staging/Kconfig
+drivers/staging/r8188eu/
 drivers/staging/rtl8723bs/
 
 drivers/usb/class/Makefile
diff --git a/patches/0013-fix-makefile-includes/r8188eu.patch b/patches/0013-fix-makefile-includes/r8188eu.patch
new file mode 100644
index 00000000..b1c32f21
--- /dev/null
+++ b/patches/0013-fix-makefile-includes/r8188eu.patch
@@ -0,0 +1,12 @@
+Needed for kernel <= 5.7
+
+--- a/drivers/staging/r8188eu/core/rtw_security.c
++++ b/drivers/staging/r8188eu/core/rtw_security.c
+@@ -7,6 +7,7 @@
+ #include "../include/drv_types.h"
+ #include "../include/wifi.h"
+ #include "../include/osdep_intf.h"
++#include <linux/crc32.h>
+ 
+ /* WEP related ===== */
+ 
diff --git a/patches/0028-select_queue/r8188eu.patch b/patches/0028-select_queue/r8188eu.patch
new file mode 100644
index 00000000..d12fa9c4
--- /dev/null
+++ b/patches/0028-select_queue/r8188eu.patch
@@ -0,0 +1,18 @@
+--- a/drivers/staging/r8188eu/os_dep/os_intfs.c
++++ b/drivers/staging/r8188eu/os_dep/os_intfs.c
+@@ -635,7 +635,15 @@ static unsigned int rtw_classify8021d(st
+ 	return dscp >> 5;
+ }
+ 
++#if LINUX_VERSION_IS_GEQ(5,2,0)
+ static u16 rtw_select_queue(struct net_device *dev, struct sk_buff *skb, struct net_device *sb_dev)
++#elif LINUX_VERSION_IS_GEQ(4,19,0)
++static u16 rtw_select_queue(struct net_device *dev, struct sk_buff *skb, struct net_device *sb_dev,
++			    select_queue_fallback_t fallback)
++#else
++static u16 rtw_select_queue(struct net_device *dev, struct sk_buff *skb, void *accel_priv,
++			    select_queue_fallback_t fallback)
++#endif
+ {
+ 	struct adapter	*padapter = rtw_netdev_priv(dev);
+ 	struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 44/47] headers: Add new include/linux/bits.h
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (42 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 43/47] backports: Add new r8188eu driver Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 45/47] headers: Add function devm_clk_get_optional() Hauke Mehrtens
                   ` (3 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

With kernel 4.19 some defines from include/linux/bitops.h were extracted
to the new file include/linux/bits.h. This patch was also backported to
older stable kernel versions. This patch makes code include the
include/linux/bitops.h file on older kernel versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/bits.h | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
 create mode 100644 backport/backport-include/linux/bits.h

diff --git a/backport/backport-include/linux/bits.h b/backport/backport-include/linux/bits.h
new file mode 100644
index 00000000..db792196
--- /dev/null
+++ b/backport/backport-include/linux/bits.h
@@ -0,0 +1,14 @@
+#ifndef __BACKPORT_LINUX_BITS_H
+#define __BACKPORT_LINUX_BITS_H
+#include <linux/version.h>
+
+#if LINUX_VERSION_IS_GEQ(4,19,0) || \
+    LINUX_VERSION_IN_RANGE(4,14,119, 4,15,0) || \
+    LINUX_VERSION_IN_RANGE(4,9,176, 4,10,0) || \
+    LINUX_VERSION_IN_RANGE(4,4,180, 4,5,0)
+#include_next <linux/bits.h>
+#else
+#include <linux/bitops.h>
+#endif /* >= 4.19 */
+
+#endif /* __BACKPORT_LINUX_BITS_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 45/47] headers: Add function devm_clk_get_optional()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (43 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 44/47] headers: Add new include/linux/bits.h Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 46/47] patches: Remove usage of DMI_PRODUCT_SKU Hauke Mehrtens
                   ` (2 subsequent siblings)
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The devm_clk_get_optional() function was added with kernel 5.1 and is
used by the wilc1000 driver now.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/clk.h | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
 create mode 100644 backport/backport-include/linux/clk.h

diff --git a/backport/backport-include/linux/clk.h b/backport/backport-include/linux/clk.h
new file mode 100644
index 00000000..7b4ab5b0
--- /dev/null
+++ b/backport/backport-include/linux/clk.h
@@ -0,0 +1,20 @@
+#ifndef __BACKPORT_LINUX_CLK_H
+#define __BACKPORT_LINUX_CLK_H
+#include_next <linux/clk.h>
+
+#include <linux/version.h>
+#if LINUX_VERSION_IS_LESS(5,1,0)
+
+static inline
+struct clk *devm_clk_get_optional(struct device *dev, const char *id)
+{
+	struct clk *clk = devm_clk_get(dev, id);
+
+	if (clk == ERR_PTR(-ENOENT))
+		return NULL;
+
+	return clk;
+}
+
+#endif /* < 5.1 */
+#endif /* __BACKPORT_LINUX_CLK_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 46/47] patches: Remove usage of DMI_PRODUCT_SKU
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (44 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 45/47] headers: Add function devm_clk_get_optional() Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-19 21:43 ` [PATCH 47/47] headers: Check for NULL in dev_put() and dev_hold() Hauke Mehrtens
  2021-10-20 12:22 ` [PATCH 00/47] backports: Update to kernel 5.15-rc6 Janusz Dziedzic
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

The mwifiex driver now uses DMI_PRODUCT_SKU, which was only added with
kernel 4.18. Do not use this on older kernel versions.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0089-unknown-dmi/mwifiex.patch | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 patches/0089-unknown-dmi/mwifiex.patch

diff --git a/patches/0089-unknown-dmi/mwifiex.patch b/patches/0089-unknown-dmi/mwifiex.patch
new file mode 100644
index 00000000..4bd68825
--- /dev/null
+++ b/patches/0089-unknown-dmi/mwifiex.patch
@@ -0,0 +1,22 @@
+--- a/drivers/net/wireless/marvell/mwifiex/pcie_quirks.c
++++ b/drivers/net/wireless/marvell/mwifiex/pcie_quirks.c
+@@ -34,7 +34,9 @@ static const struct dmi_system_id mwifie
+ 		.matches = {
+ 			/* match for SKU here due to generic product name "Surface Pro" */
+ 			DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Microsoft Corporation"),
++#if LINUX_VERSION_IS_GEQ(4,18,0)
+ 			DMI_EXACT_MATCH(DMI_PRODUCT_SKU, "Surface_Pro_1796"),
++#endif
+ 		},
+ 		.driver_data = (void *)QUIRK_FW_RST_D3COLD,
+ 	},
+@@ -43,7 +45,9 @@ static const struct dmi_system_id mwifie
+ 		.matches = {
+ 			/* match for SKU here due to generic product name "Surface Pro" */
+ 			DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Microsoft Corporation"),
++#if LINUX_VERSION_IS_GEQ(4,18,0)
+ 			DMI_EXACT_MATCH(DMI_PRODUCT_SKU, "Surface_Pro_1807"),
++#endif
+ 		},
+ 		.driver_data = (void *)QUIRK_FW_RST_D3COLD,
+ 	},
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* [PATCH 47/47] headers: Check for NULL in dev_put() and dev_hold()
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (45 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 46/47] patches: Remove usage of DMI_PRODUCT_SKU Hauke Mehrtens
@ 2021-10-19 21:43 ` Hauke Mehrtens
  2021-10-20 12:22 ` [PATCH 00/47] backports: Update to kernel 5.15-rc6 Janusz Dziedzic
  47 siblings, 0 replies; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-19 21:43 UTC (permalink / raw)
  To: backports; +Cc: Hauke Mehrtens

Since kernel 5.15 the dev_put() and dev_hold() functions check if the
given dev is not NULL before accessing the pointer. Previously the code
to check for NULL was in the calling function. Add this check for NULL
because some checks were already removed from the driver code.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 backport/backport-include/linux/netdevice.h | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h
index 5c30426d..22942398 100644
--- a/backport/backport-include/linux/netdevice.h
+++ b/backport/backport-include/linux/netdevice.h
@@ -151,4 +151,20 @@ struct rtnl_link_stats64 *
 bp_dev_get_tstats64(struct net_device *dev, struct rtnl_link_stats64 *s);
 #endif /* < 4.11 */
 
+#if LINUX_VERSION_IS_LESS(5,15,0)
+static inline void backport_dev_put(struct net_device *dev)
+{
+	if (dev)
+		dev_put(dev);
+}
+#define dev_put LINUX_BACKPORT(dev_put)
+
+static inline void backport_dev_hold(struct net_device *dev)
+{
+	if (dev)
+		dev_hold(dev);
+}
+#define dev_hold LINUX_BACKPORT(dev_hold)
+#endif /* < 5.15 */
+
 #endif /* __BACKPORT_NETDEVICE_H */
-- 
2.30.2

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply related	[flat|nested] 51+ messages in thread

* Re: [PATCH 00/47] backports: Update to kernel 5.15-rc6
  2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
                   ` (46 preceding siblings ...)
  2021-10-19 21:43 ` [PATCH 47/47] headers: Check for NULL in dev_put() and dev_hold() Hauke Mehrtens
@ 2021-10-20 12:22 ` Janusz Dziedzic
  2021-10-20 18:27   ` Hauke Mehrtens
  47 siblings, 1 reply; 51+ messages in thread
From: Janusz Dziedzic @ 2021-10-20 12:22 UTC (permalink / raw)
  To: Hauke Mehrtens; +Cc: backports

wt., 19 paź 2021 o 23:44 Hauke Mehrtens <hauke@hauke-m.de> napisał(a):
>
> This updates backports to kernel 5.15-rc6.
>
> This is done in multiple steps, I plan to make a release based on the
> latest stable version for each major kernel version between 5.10 and
> 5.15-rc6. This was compile tested against kernel 4.4 till 5.10 and
> runtime tested in AP mode with ath9k. We want to use this in OpenWrt and
> are testing this in OpenWrt now.
>
> These patches are also available here:
> https://github.com/hauke/backports/tree/devel-5.15-2
>
Thanks!

Could you also share openwrt branch that using this backports.
I already have ath9k/10k/11k (PCI) cards could check.

BR
Janusz

>
> Hauke Mehrtens (47):
>   patches: Refresh on kernel 5.11.22
>   backports: Add dev_get_tstats64() and bp_dev_get_tstats64()
>   backports: Add empty implementation for skb_get_kcov_handle()
>   backports: Add linux/math.h
>   backports: Add dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add()
>   headers: Add linux/kcov.h
>   patches: Do not use rx_list in mt76 on older kernel versions.
>   dependencies: Build mt7915 only on kernel >= 4.6
>   patches: Remove const from struct rchan_callbacks
>   patches: Refresh patches on top of kernel 5.12.19
>   patches: include linux/modules.h in mt76/mt76_connac_mcu.c
>   patches: Do not use rx_list in mt76/mt7921 driver on older kernel
>     versions.
>   patches: Do not use rx_list in mt7601u driver on older kernel
>     versions.
>   dependencies: Build mt7921 only on kernel >= 4.6
>   dependencies: Build NL80211_TESTMODE only on kernel >= 4.18
>   headers: Add DECLARE_STATIC_KEY_FALSE
>   headers: Add ETH_P_MAP
>   patches: Refresh on top of kernel 5.13.19
>   headers: Add tasklet_disable_in_atomic()
>   headers: Add lockdep_assert_not_held()
>   headers: Adapt signature of of_get_mac_address()
>   headers: Add rfkill_set_hw_state_reason()
>   patches: Remove usage of threaded NAPI from mt76
>   headers: Adapt signature of thermal_zone_device_update()
>   headers: Add time_after32()
>   patches: Refresh on top of kernel 5.14.13
>   headers: Add FW_ACTION_NOUEVENT and FW_ACTION_UEVENT
>   headers: Add linux/wwan.h file
>   headers: Add DEVICE_ATTR_ADMIN_RW
>   headers: Add get_unaligned_be24
>   headers: Add rbtree cached
>   headers: Adapt signature of hrtimer_forward_now()
>   dependencies: Build RTL8723BS only on kernel >= 5.4
>   backports: Remove rtl8188eu driver
>   backports: Remove prism54 driver
>   patches: Refresh on top of kernel 5.15-rc6
>   backports: Remove old CISCO airo driver
>   backports: Remove intersil hostap driver
>   patches: Adapt signature of bus_type->remove callback
>   patches: Adapt signature of ethtool_ops->set_coalesce callback
>   patches: Do not set mhi_controller->reg_len on older kernel versions
>   backports: Update wifi defconfig
>   backports: Add new r8188eu driver
>   headers: Add new include/linux/bits.h
>   headers: Add function devm_clk_get_optional()
>   patches: Remove usage of DMI_PRODUCT_SKU
>   headers: Check for NULL in dev_put() and dev_hold()
>
>  backport/backport-include/asm/unaligned.h     |  17 ++
>  backport/backport-include/linux/bits.h        |  14 ++
>  backport/backport-include/linux/clk.h         |  20 +++
>  backport/backport-include/linux/device.h      |  10 ++
>  backport/backport-include/linux/firmware.h    |   8 +
>  backport/backport-include/linux/if_ether.h    |   6 +
>  backport/backport-include/linux/interrupt.h   |  32 ++++
>  backport/backport-include/linux/jump_label.h  |  10 ++
>  backport/backport-include/linux/kcov.h        |  16 ++
>  backport/backport-include/linux/lockdep.h     |  11 ++
>  backport/backport-include/linux/math.h        |  12 ++
>  backport/backport-include/linux/netdevice.h   |  54 +++++++
>  backport/backport-include/linux/of_net.h      |  14 +-
>  backport/backport-include/linux/rbtree.h      |  59 +++++++
>  backport/backport-include/linux/rfkill.h      |  24 +++
>  backport/backport-include/linux/sched.h       |   5 +
>  backport/backport-include/linux/skbuff.h      |   8 +
>  backport/backport-include/linux/sysfs.h       |   9 ++
>  backport/backport-include/linux/thermal.h     |  23 +++
>  backport/backport-include/linux/time.h        |  17 ++
>  backport/backport-include/linux/wwan.h        |  35 ++++
>  backport/compat/Makefile                      |   3 +
>  backport/compat/backport-4.11.c               |  12 ++
>  backport/compat/backport-5.11.c               |  19 +++
>  backport/compat/backport-5.13.c               |  30 ++++
>  backport/defconfigs/wifi                      |  26 +--
>  copy-list                                     |   8 +-
>  dependencies                                  |  10 ++
>  .../include_net_cfg80211.patch                |   4 +-
>  .../net_wireless_core.patch                   |   2 +-
>  .../net_wireless_core.patch                   |   4 +-
>  .../0013-fix-makefile-includes/cfg80211.patch |  16 +-
>  patches/0013-fix-makefile-includes/mt76.patch |  10 ++
>  .../0013-fix-makefile-includes/r8188eu.patch  |  12 ++
>  .../0013-fix-makefile-includes/rtw88.patch    |  10 +-
>  .../0013-fix-makefile-includes/wilc1000.patch |   4 +-
>  patches/0028-select_queue/mac80211.patch      |   4 +-
>  patches/0028-select_queue/mwifiex.patch       |   2 +-
>  .../{rtl8188eu.patch => r8188eu.patch}        |  17 +-
>  patches/0028-select_queue/rtl8723bs.patch     |   2 +-
>  patches/0075-ndo-stats-64/usbnet.patch        |  24 ---
>  patches/0077-genl-ro-after-init/hwsim.patch   |   2 +-
>  patches/0077-genl-ro-after-init/nl80211.patch |   2 +-
>  patches/0079-netdev-destructor/brcmfmac.patch |   6 +-
>  patches/0084-disable-some-staging-dirs.patch  |   8 +-
>  patches/0089-unknown-dmi/mwifiex.patch        |  22 +++
>  patches/0092-listified-rx/iwlwifi.patch       |  19 ---
>  patches/0094-ndo-tx-timeout/prism54.patch     |  23 ---
>  patches/0094-ndo-tx-timeout/usbnet.patch      |   2 +-
>  patches/0095-spi-delay/wilc1000.patch         |   6 +-
>  patches/0097-skb-list/mac80211-rx.patch       |  28 +++-
>  patches/0097-skb-list/mac80211-status.patch   |   6 +-
>  patches/0097-skb-list/mt76.patch              | 150 ++++++++++++++++++
>  patches/0097-skb-list/mt7601u.patch           |  30 ++++
>  patches/0098-netdev_nested_priv/qtnfmac.patch |   6 +-
>  patches/0099-netlink-range/mac80211.patch     |  13 +-
>  patches/0100-revert-small_ops/mac80211.patch  |   8 +-
>  .../mac80211_hwsim.patch                      |   4 +-
>  patches/0101-net_device-threaded/mt76.patch   |  41 +++++
>  patches/0102-remove-callback.patch            |  63 ++++++++
>  patches/0103-ethtool-coalesce.patch           |  36 +++++
>  patches/0104-mhi-reg-len.patch                |  12 ++
>  ...05-remove-const-from-rchan_callbacks.patch |  42 +++++
>  patches/verify.patch                          |  14 +-
>  64 files changed, 1002 insertions(+), 164 deletions(-)
>  create mode 100644 backport/backport-include/asm/unaligned.h
>  create mode 100644 backport/backport-include/linux/bits.h
>  create mode 100644 backport/backport-include/linux/clk.h
>  create mode 100644 backport/backport-include/linux/device.h
>  create mode 100644 backport/backport-include/linux/jump_label.h
>  create mode 100644 backport/backport-include/linux/kcov.h
>  create mode 100644 backport/backport-include/linux/math.h
>  create mode 100644 backport/backport-include/linux/rbtree.h
>  create mode 100644 backport/backport-include/linux/rfkill.h
>  create mode 100644 backport/backport-include/linux/wwan.h
>  create mode 100644 backport/compat/backport-4.11.c
>  create mode 100644 backport/compat/backport-5.11.c
>  create mode 100644 backport/compat/backport-5.13.c
>  create mode 100644 patches/0013-fix-makefile-includes/r8188eu.patch
>  rename patches/0028-select_queue/{rtl8188eu.patch => r8188eu.patch} (56%)
>  delete mode 100644 patches/0075-ndo-stats-64/usbnet.patch
>  create mode 100644 patches/0089-unknown-dmi/mwifiex.patch
>  delete mode 100644 patches/0092-listified-rx/iwlwifi.patch
>  delete mode 100644 patches/0094-ndo-tx-timeout/prism54.patch
>  create mode 100644 patches/0097-skb-list/mt76.patch
>  create mode 100644 patches/0097-skb-list/mt7601u.patch
>  create mode 100644 patches/0101-net_device-threaded/mt76.patch
>  create mode 100644 patches/0102-remove-callback.patch
>  create mode 100644 patches/0103-ethtool-coalesce.patch
>  create mode 100644 patches/0104-mhi-reg-len.patch
>  create mode 100644 patches/0105-remove-const-from-rchan_callbacks.patch
>
> --
> 2.30.2
>
> --
> To unsubscribe from this list: send the line "unsubscribe backports" in



-- 
Janusz Dziedzic
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 51+ messages in thread

* Re: [PATCH 00/47] backports: Update to kernel 5.15-rc6
  2021-10-20 12:22 ` [PATCH 00/47] backports: Update to kernel 5.15-rc6 Janusz Dziedzic
@ 2021-10-20 18:27   ` Hauke Mehrtens
  2021-10-20 20:09     ` Robert Marko
  0 siblings, 1 reply; 51+ messages in thread
From: Hauke Mehrtens @ 2021-10-20 18:27 UTC (permalink / raw)
  To: Janusz Dziedzic; +Cc: backports, Robert Marko

On 10/20/21 2:22 PM, Janusz Dziedzic wrote:
> wt., 19 paź 2021 o 23:44 Hauke Mehrtens <hauke@hauke-m.de> napisał(a):
>>
>> This updates backports to kernel 5.15-rc6.
>>
>> This is done in multiple steps, I plan to make a release based on the
>> latest stable version for each major kernel version between 5.10 and
>> 5.15-rc6. This was compile tested against kernel 4.4 till 5.10 and
>> runtime tested in AP mode with ath9k. We want to use this in OpenWrt and
>> are testing this in OpenWrt now.
>>
>> These patches are also available here:
>> https://github.com/hauke/backports/tree/devel-5.15-2
>>
> Thanks!
> 
> Could you also share openwrt branch that using this backports.
> I already have ath9k/10k/11k (PCI) cards could check.
> 
> BR
> Janusz

Hi,

I have a feature branch with the patches here:
https://git.openwrt.org/?p=openwrt/staging/hauke.git;a=shortlog;h=refs/heads/mac80211-5.15

There are still some problems with ath11k, Robert Marko is working on 
that. ath11k needs some more changes in other frameworks.

Hauke
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 51+ messages in thread

* Re: [PATCH 00/47] backports: Update to kernel 5.15-rc6
  2021-10-20 18:27   ` Hauke Mehrtens
@ 2021-10-20 20:09     ` Robert Marko
  0 siblings, 0 replies; 51+ messages in thread
From: Robert Marko @ 2021-10-20 20:09 UTC (permalink / raw)
  To: Hauke Mehrtens; +Cc: Janusz Dziedzic, backports

On Wed, Oct 20, 2021 at 8:27 PM Hauke Mehrtens <hauke@hauke-m.de> wrote:
>
> On 10/20/21 2:22 PM, Janusz Dziedzic wrote:
> > wt., 19 paź 2021 o 23:44 Hauke Mehrtens <hauke@hauke-m.de> napisał(a):
> >>
> >> This updates backports to kernel 5.15-rc6.
> >>
> >> This is done in multiple steps, I plan to make a release based on the
> >> latest stable version for each major kernel version between 5.10 and
> >> 5.15-rc6. This was compile tested against kernel 4.4 till 5.10 and
> >> runtime tested in AP mode with ath9k. We want to use this in OpenWrt and
> >> are testing this in OpenWrt now.
> >>
> >> These patches are also available here:
> >> https://github.com/hauke/backports/tree/devel-5.15-2
> >>
> > Thanks!
> >
> > Could you also share openwrt branch that using this backports.
> > I already have ath9k/10k/11k (PCI) cards could check.
> >
> > BR
> > Janusz
>
> Hi,
>
> I have a feature branch with the patches here:
> https://git.openwrt.org/?p=openwrt/staging/hauke.git;a=shortlog;h=refs/heads/mac80211-5.15
>
> There are still some problems with ath11k, Robert Marko is working on
> that. ath11k needs some more changes in other frameworks.

ath11k is a pain as its PCI support depends on MHI and QRTR support.
Both of which have things that must be backported in order to kind of work.

I hope to have the ath11k support cleaned up soon so that it can be
sent at least for the PCI variant
after 5.15 backports get merged.

Regards,
Robert
>
> Hauke



-- 
Robert Marko
Staff Embedded Linux Engineer
Sartura Ltd.
Lendavska ulica 16a
10000 Zagreb, Croatia
Email: robert.marko@sartura.hr
Web: www.sartura.hr
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 51+ messages in thread

end of thread, other threads:[~2021-10-20 20:09 UTC | newest]

Thread overview: 51+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-19 21:42 [PATCH 00/47] backports: Update to kernel 5.15-rc6 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 01/47] patches: Refresh on kernel 5.11.22 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 02/47] backports: Add dev_get_tstats64() and bp_dev_get_tstats64() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 03/47] backports: Add empty implementation for skb_get_kcov_handle() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 04/47] backports: Add linux/math.h Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 05/47] backports: Add dev_sw_netstats_rx_add() and dev_sw_netstats_tx_add() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 06/47] headers: Add linux/kcov.h Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 07/47] patches: Do not use rx_list in mt76 on older kernel versions Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 08/47] dependencies: Build mt7915 only on kernel >= 4.6 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 09/47] patches: Remove const from struct rchan_callbacks Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 10/47] patches: Refresh patches on top of kernel 5.12.19 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 11/47] patches: include linux/modules.h in mt76/mt76_connac_mcu.c Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 12/47] patches: Do not use rx_list in mt76/mt7921 driver on older kernel versions Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 13/47] patches: Do not use rx_list in mt7601u " Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 14/47] dependencies: Build mt7921 only on kernel >= 4.6 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 15/47] dependencies: Build NL80211_TESTMODE only on kernel >= 4.18 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 16/47] headers: Add DECLARE_STATIC_KEY_FALSE Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 17/47] headers: Add ETH_P_MAP Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 18/47] patches: Refresh on top of kernel 5.13.19 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 19/47] headers: Add tasklet_disable_in_atomic() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 20/47] headers: Add lockdep_assert_not_held() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 21/47] headers: Adapt signature of of_get_mac_address() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 22/47] headers: Add rfkill_set_hw_state_reason() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 23/47] patches: Remove usage of threaded NAPI from mt76 Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 24/47] headers: Adapt signature of thermal_zone_device_update() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 25/47] headers: Add time_after32() Hauke Mehrtens
2021-10-19 21:42 ` [PATCH 26/47] patches: Refresh on top of kernel 5.14.13 Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 27/47] headers: Add FW_ACTION_NOUEVENT and FW_ACTION_UEVENT Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 28/47] headers: Add linux/wwan.h file Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 29/47] headers: Add DEVICE_ATTR_ADMIN_RW Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 30/47] headers: Add get_unaligned_be24 Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 31/47] headers: Add rbtree cached Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 32/47] headers: Adapt signature of hrtimer_forward_now() Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 33/47] dependencies: Build RTL8723BS only on kernel >= 5.4 Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 34/47] backports: Remove rtl8188eu driver Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 35/47] backports: Remove prism54 driver Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 36/47] patches: Refresh on top of kernel 5.15-rc6 Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 37/47] backports: Remove old CISCO airo driver Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 38/47] backports: Remove intersil hostap driver Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 39/47] patches: Adapt signature of bus_type->remove callback Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 40/47] patches: Adapt signature of ethtool_ops->set_coalesce callback Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 41/47] patches: Do not set mhi_controller->reg_len on older kernel versions Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 42/47] backports: Update wifi defconfig Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 43/47] backports: Add new r8188eu driver Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 44/47] headers: Add new include/linux/bits.h Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 45/47] headers: Add function devm_clk_get_optional() Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 46/47] patches: Remove usage of DMI_PRODUCT_SKU Hauke Mehrtens
2021-10-19 21:43 ` [PATCH 47/47] headers: Check for NULL in dev_put() and dev_hold() Hauke Mehrtens
2021-10-20 12:22 ` [PATCH 00/47] backports: Update to kernel 5.15-rc6 Janusz Dziedzic
2021-10-20 18:27   ` Hauke Mehrtens
2021-10-20 20:09     ` Robert Marko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).