Android-x86
Fork
捐款

  • R/O
  • HTTP
  • SSH
  • HTTPS

external-kernel-drivers: 提交

external/kernel-drivers


Commit MetaInfo

修訂8e2d5a403b8e7b63e481f4504d3edbdd605ac414 (tree)
時間2022-04-18 03:40:14
作者Mauro Rossi <issor.oruam@gmai...>
CommiterMauro Rossi

Log Message

wl: fix build with kernel 5.17

Add https://github.com/rpmfusion/wl-kmod/blob/master/wl-kmod-021_kernel_5.17_adaptation.patch

Changes due to commit:
359745d7 ("proc: remove PDE_DATA() completely")

Change Summary

差異

--- /dev/null
+++ b/wl/wl-kmod-021_kernel_5.17_adaptation.patch
@@ -0,0 +1,78 @@
1+diff -Naur hybrid-v35_64-nodebug-pcoem-6_30_223_271.orig/src/wl/sys/wl_iw.h hybrid-v35_64-nodebug-pcoem-6_30_223_271-021_kernel_5.17_adaptation/src/wl/sys/wl_iw.h
2+--- hybrid-v35_64-nodebug-pcoem-6_30_223_271.orig/src/wl/sys/wl_iw.h 2020-12-29 18:29:39.463940664 +0100
3++++ hybrid-v35_64-nodebug-pcoem-6_30_223_271-021_kernel_5.17_adaptation/src/wl/sys/wl_iw.h 2022-04-01 10:25:05.515054893 +0200
4+@@ -70,7 +70,9 @@
5+ #define WL_IW_RSSI_EXCELLENT -57
6+ #define WL_IW_RSSI_INVALID 0
7+ #define MAX_WX_STRING 80
8++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 17, 0)
9+ #define isprint(c) bcm_isprint(c)
10++#endif
11+ #define WL_IW_SET_ACTIVE_SCAN (SIOCIWFIRSTPRIV+1)
12+ #define WL_IW_GET_RSSI (SIOCIWFIRSTPRIV+3)
13+ #define WL_IW_SET_PASSIVE_SCAN (SIOCIWFIRSTPRIV+5)
14+diff -Naur hybrid-v35_64-nodebug-pcoem-6_30_223_271.orig/src/wl/sys/wl_linux.c hybrid-v35_64-nodebug-pcoem-6_30_223_271-021_kernel_5.17_adaptation/src/wl/sys/wl_linux.c
15+--- hybrid-v35_64-nodebug-pcoem-6_30_223_271.orig/src/wl/sys/wl_linux.c 2020-12-29 21:55:44.899067286 +0100
16++++ hybrid-v35_64-nodebug-pcoem-6_30_223_271-021_kernel_5.17_adaptation/src/wl/sys/wl_linux.c 2022-04-01 10:00:24.985252480 +0200
17+@@ -638,7 +638,11 @@
18+ WL_ERROR(("wl%d: Error setting MAC ADDRESS\n", unit));
19+ }
20+ #endif
21++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 17, 0)
22+ bcopy(&wl->pub->cur_etheraddr, dev->dev_addr, ETHER_ADDR_LEN);
23++#else
24++ dev_addr_mod(dev, 0, &wl->pub->cur_etheraddr, ETHER_ADDR_LEN);
25++#endif
26+
27+ online_cpus = 1;
28+
29+@@ -1862,7 +1866,11 @@
30+
31+ WL_LOCK(wl);
32+
33++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 17, 0)
34+ bcopy(sa->sa_data, dev->dev_addr, ETHER_ADDR_LEN);
35++#else
36++ dev_addr_mod(dev, 0, sa->sa_data, ETHER_ADDR_LEN);
37++#endif
38+ err = wlc_iovar_op(wl->wlc, "cur_etheraddr", NULL, 0, sa->sa_data, ETHER_ADDR_LEN,
39+ IOV_SET, (WL_DEV_IF(dev))->wlcif);
40+ WL_UNLOCK(wl);
41+@@ -3054,7 +3062,11 @@
42+ else
43+ dev->type = ARPHRD_IEEE80211_RADIOTAP;
44+
45++#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 17, 0)
46+ bcopy(wl->dev->dev_addr, dev->dev_addr, ETHER_ADDR_LEN);
47++#else
48++ dev_addr_mod(dev, 0, wl->dev->dev_addr, ETHER_ADDR_LEN);
49++#endif
50+
51+ #if defined(WL_USE_NETDEV_OPS)
52+ dev->netdev_ops = &wl_netdev_monitor_ops;
53+@@ -3335,8 +3347,12 @@
54+ static ssize_t
55+ wl_proc_read(struct file *filp, char __user *buffer, size_t length, loff_t *offp)
56+ {
57++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 17, 0))
58++ wl_info_t * wl = pde_data(file_inode(filp));
59++#else
60+ wl_info_t * wl = PDE_DATA(file_inode(filp));
61+ #endif
62++#endif
63+ int bcmerror, len;
64+ int to_user = 0;
65+ char tmp[8];
66+@@ -3392,8 +3408,12 @@
67+ static ssize_t
68+ wl_proc_write(struct file *filp, const char __user *buff, size_t length, loff_t *offp)
69+ {
70++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 17, 0))
71++ wl_info_t * wl = pde_data(file_inode(filp));
72++#else
73+ wl_info_t * wl = PDE_DATA(file_inode(filp));
74+ #endif
75++#endif
76+ int from_user = 0;
77+ int bcmerror;
78+
Show on old repository browser