[wl-kmod] Add patch for kernel >= 4.8 - add cfg80211_scan_info struct in cfg80211_scan_done call

Nicolas Viéville nvieville at rpmfusion.org
Thu Sep 8 00:47:26 CEST 2016


commit 69c510c4457cea34c3080acaa9ea87781ba8e8b7
Author: Nicolas Viéville <nicolas.vieville at univ-valenciennes.fr>
Date:   Thu Sep 8 00:40:59 2016 +0200

    Add patch for kernel >= 4.8 - add cfg80211_scan_info struct in cfg80211_scan_done call

 ..._kernel_4.8_add_cfg80211_scan_info_struct.patch | 51 ++++++++++++++++++++++
 wl-kmod.spec                                       |  7 ++-
 2 files changed, 57 insertions(+), 1 deletion(-)
---
diff --git a/wl-kmod-007_kernel_4.8_add_cfg80211_scan_info_struct.patch b/wl-kmod-007_kernel_4.8_add_cfg80211_scan_info_struct.patch
new file mode 100644
index 0000000..51de084
--- /dev/null
+++ b/wl-kmod-007_kernel_4.8_add_cfg80211_scan_info_struct.patch
@@ -0,0 +1,51 @@
+diff -Naur hybrid-v35_64-nodebug-pcoem-6_30_223_271.orig/src/wl/sys/wl_cfg80211_hybrid.c hybrid-v35_64-nodebug-pcoem-6_30_223_271/src/wl/sys/wl_cfg80211_hybrid.c
+--- hybrid-v35_64-nodebug-pcoem-6_30_223_271.orig/src/wl/sys/wl_cfg80211_hybrid.c	2016-09-07 22:38:13.303835653 +0200
++++ hybrid-v35_64-nodebug-pcoem-6_30_223_271/src/wl/sys/wl_cfg80211_hybrid.c	2016-09-07 22:54:53.550730661 +0200
+@@ -2439,8 +2439,17 @@
+ 	s32 err = 0;
+ 
+ 	if (wl->scan_request) {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
++		struct cfg80211_scan_info info = {
++			.aborted = true,
++		};
++#endif
+ 		WL_DBG(("%s: Aborting scan\n", __FUNCTION__));
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
++		cfg80211_scan_done(wl->scan_request, &info);     
++#else
+ 		cfg80211_scan_done(wl->scan_request, true);     
++#endif
+ 		wl->scan_request = NULL;
+ 	}
+ 
+@@ -2541,7 +2550,14 @@
+ 
+ scan_done_out:
+ 	if (wl->scan_request) {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
++		struct cfg80211_scan_info info = {
++			.aborted = false,
++		};
++		cfg80211_scan_done(wl->scan_request, &info);
++#else
+ 		cfg80211_scan_done(wl->scan_request, false);
++#endif
+ 		wl->scan_request = NULL;
+ 	}
+ 	rtnl_unlock();
+@@ -2970,7 +2986,14 @@
+ 	s32 err = 0;
+ 
+ 	if (wl->scan_request) {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 8, 0)
++		struct cfg80211_scan_info info = {
++			.aborted = true,
++		};
++		cfg80211_scan_done(wl->scan_request, &info);
++#else
+ 		cfg80211_scan_done(wl->scan_request, true);	
++#endif
+ 		wl->scan_request = NULL;
+ 	}
+ 
diff --git a/wl-kmod.spec b/wl-kmod.spec
index e3daceb..c733a55 100644
--- a/wl-kmod.spec
+++ b/wl-kmod.spec
@@ -8,7 +8,7 @@
 
 Name:       wl-kmod
 Version:    6.30.223.271
-Release:    6%{?dist}
+Release:    7%{?dist}
 Summary:    Kernel module for Broadcom wireless devices
 Group:      System Environment/Kernel
 License:    Redistributable, no modification permitted
@@ -22,6 +22,7 @@ Patch2:     wl-kmod-003_gcc_4.9_remove_TIME_DATE_macros.patch
 Patch3:     wl-kmod-004_kernel_4.3_rdtscl_to_rdtsc.patch
 Patch4:     wl-kmod-005_kernel_4.7_IEEE80211_BAND_to_NL80211_BAND.patch
 Patch5:     wl-kmod-006_gcc_6_fix_indentation_warnings.patch
+Patch6:     wl-kmod-007_kernel_4.8_add_cfg80211_scan_info_struct.patch
 
 BuildRequires:  %{_bindir}/kmodtool
 
@@ -66,6 +67,7 @@ pushd %{name}-%{version}-src
 %patch3  -p1 -b .kernel_4.3_rdtscl_to_rdtsc.patch
 %patch4  -p1 -b .kernel_4.7_IEEE80211_BAND_to_NL80211_BAND
 %patch5  -p1 -b .gcc_6_fix_indentation_warnings
+%patch6  -p1 -b .kernel_4.8_add_cfg80211_scan_info_struct
 popd
 
 for kernel_version in %{?kernel_versions} ; do
@@ -95,6 +97,9 @@ chmod 0755 $RPM_BUILD_ROOT%{kmodinstdir_prefix}*%{kmodinstdir_postfix}/* || :
 rm -rf $RPM_BUILD_ROOT
 
 %changelog
+* Wed Sep 07 2016 Nicolas Viéville <nicolas.vieville at univ-valenciennes.fr> - 6.30.223.271-7
+- Add patch for kernel >= 4.8 - add cfg80211_scan_info struct in cfg80211_scan_done call
+
 * Fri Sep 02 2016 Leigh Scott <leigh123linux at googlemail.com> - 6.30.223.271-6
 - Fix 4.7 kernel patch
 


More information about the rpmfusion-commits mailing list