FS#53974 - [broadcom-wl-dkms] Doesn't build with kernel >= 4.11
Attached to Project:
Community Packages
Opened by Deactivated account (TechnicalTotoro) - Monday, 08 May 2017, 17:36 GMT
Last edited by Alexander F. Rødseth (xyproto) - Wednesday, 10 May 2017, 20:37 GMT
Opened by Deactivated account (TechnicalTotoro) - Monday, 08 May 2017, 17:36 GMT
Last edited by Alexander F. Rødseth (xyproto) - Wednesday, 10 May 2017, 20:37 GMT
|
Details
In kernel versions before 4.11 struct net_device had a
member called last_rx, but since this member has been
removed in 4.11-rc1, broadcom-wl-dkms fails to build as it
can't find it. I have attached my build log.
The broadcom-wl package in the AUR has a patch for this: https://aur.archlinux.org/cgit/aur.git/tree/linux411.patch?h=broadcom-wl |
This task depends upon
Closed by Alexander F. Rødseth (xyproto)
Wednesday, 10 May 2017, 20:37 GMT
Reason for closing: Fixed
Wednesday, 10 May 2017, 20:37 GMT
Reason for closing: Fixed
diff --git a/src/wl/sys/wl_cfg80211_hybrid.c b/src/wl/sys/wl_cfg80211_hybrid.c
index a9671e2..e2c69f9 100644
--- a/src/wl/sys/wl_cfg80211_hybrid.c
+++ b/src/wl/sys/wl_cfg80211_hybrid.c
@@ -38,6 +38,9 @@
#include <wlioctl.h>
#include <proto/802.11.h>
#include <wl_cfg80211_hybrid.h>
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 11, 0)
+#include <linux/sched/signal.h>
+#endif
#define EVENT_TYPE(e) dtoh32((e)->event_type)
#define EVENT_FLAGS(e) dtoh16((e)->flags)
diff --git a/src/wl/sys/wl_linux.c b/src/wl/sys/wl_linux.c
index 4a99b9a..89e615b 100644
--- a/src/wl/sys/wl_linux.c
+++ b/src/wl/sys/wl_linux.c
@@ -2916,7 +2916,9 @@ wl_monitor(wl_info_t *wl, wl_rxsts_t *rxsts, void *p)
if (skb == NULL) return;
skb->dev = wl->monitor_dev;
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 11, 0)
skb->dev->last_rx = jiffies;
+#endif
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 22)
skb_reset_mac_header(skb);
#else
follow the same principal as https://git.archlinux.org/svntogit/community.git/tree/trunk/linux-4.11.patch?h=packages/r8168&id=dc514506045c45a2d81da61b536d7bd4ebaccba8
of not storing a value that is never used