Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at fix-function-merge 66 lines 2.0 kB view raw
1From 8c536235639010135f8dc11a8ec0968f9b200a6e Mon Sep 17 00:00:00 2001 2From: Alberto Milone <alberto.milone@canonical.com> 3Date: Fri, 2 Sep 2016 17:35:34 +0200 4Subject: [PATCH 05/16] linuxPackages.broadcom_sta: fix build for kernel 4.8+ 5 6Original author: Krzysztof Kolasa 7 8Source: https://git.archlinux.org/svntogit/community.git/tree/trunk/004-linux48.patch?h=packages/broadcom-wl-dkms 9--- 10 src/wl/sys/wl_cfg80211_hybrid.c | 22 ++++++++++++++++++++++ 11 1 file changed, 22 insertions(+) 12 13diff --git a/src/wl/sys/wl_cfg80211_hybrid.c b/src/wl/sys/wl_cfg80211_hybrid.c 14index 3b438ba..84f0068 100644 15--- a/src/wl/sys/wl_cfg80211_hybrid.c 16+++ b/src/wl/sys/wl_cfg80211_hybrid.c 17@@ -2386,8 +2386,16 @@ wl_bss_connect_done(struct wl_cfg80211_priv *wl, struct net_device *ndev, 18 s32 err = 0; 19 20 if (wl->scan_request) { 21+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0) 22+ struct cfg80211_scan_info info = { 23+ .aborted = true, 24+ }; 25+ WL_DBG(("%s: Aborting scan\n", __FUNCTION__)); 26+ cfg80211_scan_done(wl->scan_request, &info); 27+#else 28 WL_DBG(("%s: Aborting scan\n", __FUNCTION__)); 29 cfg80211_scan_done(wl->scan_request, true); 30+#endif 31 wl->scan_request = NULL; 32 } 33 34@@ -2488,7 +2496,14 @@ wl_notify_scan_status(struct wl_cfg80211_priv *wl, struct net_device *ndev, 35 36 scan_done_out: 37 if (wl->scan_request) { 38+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0) 39+ struct cfg80211_scan_info info = { 40+ .aborted = false, 41+ }; 42+ cfg80211_scan_done(wl->scan_request, &info); 43+#else 44 cfg80211_scan_done(wl->scan_request, false); 45+#endif 46 wl->scan_request = NULL; 47 } 48 rtnl_unlock(); 49@@ -2913,7 +2928,14 @@ s32 wl_cfg80211_down(struct net_device *ndev) 50 s32 err = 0; 51 52 if (wl->scan_request) { 53+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0) 54+ struct cfg80211_scan_info info = { 55+ .aborted = true, 56+ }; 57+ cfg80211_scan_done(wl->scan_request, &info); 58+#else 59 cfg80211_scan_done(wl->scan_request, true); 60+#endif 61 wl->scan_request = NULL; 62 } 63 64-- 652.45.1 66