I'm trying to reinstall this driver after i upgraded the kernel of a machine from 5.15.74-3 to 5.19.14-1-MANJARO, but i'm getting some errors during the build process (it worked OOTB on 5.15.74-3).
Build WITHOUT dkms:
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/osdep_service.o
/home/asgea/Documents/rtl8821CU/os_dep/osdep_service.c: In function ‘rtw_change_ifname’:
/home/asgea/Documents/rtl8821CU/os_dep/osdep_service.c:2494:28: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
2494 | _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
| ~~~~~~~^~~~~~~~~~
/home/asgea/Documents/rtl8821CU/os_dep/osdep_service.c:925:24: note: expected ‘void *’ but argument is of type ‘const unsigned char *’
925 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
| ~~~~~~^~~
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/os_intfs.o
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/usb_intf.o
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/usb_ops_linux.o
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_linux.o
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_linux.c: In function ‘rtw_mp_efuse_set’:
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_linux.c:9781:46: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
9781 | _rtw_memcpy(padapter->pnetdev->dev_addr, get_hal_mac_addr(padapter), ETH_ALEN); /* set mac addr to net_device */
| ~~~~~~~~~~~~~~~~~^~~~~~~~~~
In file included from /home/asgea/Documents/rtl8821CU/include/drv_types.h:27,
from /home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_linux.c:17:
/home/asgea/Documents/rtl8821CU/include/osdep_service.h:296:35: note: expected ‘void *’ but argument is of type ‘const unsigned char *’
296 | extern void _rtw_memcpy(void *dec, const void *sour, u32 sz);
| ~~~~~~^~~
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/xmit_linux.o
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/mlme_linux.o
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/recv_linux.o
CC [M] /home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.o
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c: In function ‘rtw_cfg80211_ch_switch_notify’:
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c:420:9: error: too few arguments to function ‘cfg80211_ch_switch_notify’
420 | cfg80211_ch_switch_notify(adapter->pnetdev, &chdef);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/asgea/Documents/rtl8821CU/include/osdep_service_linux.h:93,
from /home/asgea/Documents/rtl8821CU/include/osdep_service.h:50,
from /home/asgea/Documents/rtl8821CU/include/drv_types.h:27,
from /home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c:17:
./include/net/cfg80211.h:7967:6: note: declared here
7967 | void cfg80211_ch_switch_notify(struct net_device *dev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c: In function ‘cfg80211_rtw_scan’:
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c:2867:33: warning: the comparison will always evaluate as ‘true’ for the address of ‘ssid’ will never be NULL [-Waddress]
2867 | if (ssids->ssid != NULL
| ^~
./include/net/cfg80211.h:2302:12: note: ‘ssid’ declared here
2302 | u8 ssid[IEEE80211_MAX_SSID_LEN];
| ^~~~
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c: At top level:
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c:9416:20: error: initialization of ‘int (*)(struct wiphy *, struct net_device *, unsigned int)’ from incompatible pointer type ‘int (*)(struct wiphy *, struct net_device *)’ [-Werror=incompatible-pointer-types]
9416 | .stop_ap = cfg80211_rtw_stop_ap,
| ^~~~~~~~~~~~~~~~~~~~
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c:9416:20: note: (near initialization for ‘rtw_cfg80211_ops.stop_ap’)
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c: In function ‘rtw_wdev_unregister’:
/home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.c:9682:17: error: ‘struct wireless_dev’ has no member named ‘current_bss’
9682 | if (wdev->current_bss) {
| ^~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:249: /home/asgea/Documents/rtl8821CU/os_dep/linux/ioctl_cfg80211.o] Error 1
make[1]: *** [Makefile:1846: /home/asgea/Documents/rtl8821CU] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.19.14-1-MANJARO/build'
make: *** [Makefile:2217: modules] Error 2
Build with dkms:
About to run dkms install steps...
Error! DKMS tree already contains: rtl8821CU-5.4.1
You cannot add the same module/version combo more than once.
Sign command: /usr/lib/modules/5.19.14-1-MANJARO/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub
Building module:
Cleaning build area...
'make' KVER=5.19.14-1-MANJARO...........(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.19.14-1-MANJARO (x86_64)
Consult /var/lib/dkms/rtl8821CU/5.4.1/build/make.log for more information.
Sign command: /usr/lib/modules/5.19.14-1-MANJARO/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub
Building module:
Cleaning build area...
'make' KVER=5.19.14-1-MANJARO...........(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.19.14-1-MANJARO (x86_64)
Consult /var/lib/dkms/rtl8821CU/5.4.1/build/make.log for more information.
Finished running dkms install steps.
Contents of the above mentioned make.log:
DKMS make.log for rtl8821CU-5.4.1 for kernel 5.19.14-1-MANJARO (x86_64)
sáb 15 out 2022 20:24:50 -03
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.19.14-1-MANJARO/build M=/var/lib/dkms/rtl8821CU/5.4.1/build modules
make[1]: Entering directory '/usr/lib/modules/5.19.14-1-MANJARO/build'
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_cmd.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_security.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_debug.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_io.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ioctl_query.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ioctl_set.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ieee80211.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_mlme.o
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_mlme.c: In function ‘rtw_drv_scan_by_self’:
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_mlme.c:3122:17: warning: this ‘else’ clause does not guard... [-Wmisleading-indentation]
3122 | else
| ^~~~
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_mlme.c:3125:25: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘else’
3125 | goto exit;
| ^~~~
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_mlme_ext.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_mi.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_wlan_util.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_vht.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_pwrctrl.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_rf.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_recv.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_sta_mgt.o
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_sta_mgt.c: In function ‘rtw_mfree_stainfo’:
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_sta_mgt.c:379:25: warning: the comparison will always evaluate as ‘true’ for the address of ‘lock’ will never be NULL [-Waddress]
379 | if (&psta->lock != NULL)
| ^~
In file included from /var/lib/dkms/rtl8821CU/5.4.1/build/include/drv_types.h:107,
from /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_sta_mgt.c:17:
/var/lib/dkms/rtl8821CU/5.4.1/build/include/sta_info.h:256:17: note: ‘lock’ declared here
256 | _lock lock;
| ^~~~
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ap.o
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ap.c: In function ‘rtw_ap_update_chbw_by_ifbmp’:
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ap.c:4397:42: warning: the comparison will always evaluate as ‘true’ for the address of ‘padapters’ will never be NULL [-Waddress]
4397 | if (!(ifbmp & BIT(i)) || !dvobj->padapters)
| ^
In file included from /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ap.c:17:
/var/lib/dkms/rtl8821CU/5.4.1/build/include/drv_types.h:1020:19: note: ‘padapters’ declared here
1020 | _adapter *padapters[CONFIG_IFACE_NUMBER];/*IFACE_ID_MAX*/
| ^~~~~~~~~
/var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_ap.c:4417:42: warning: the comparison will always evaluate as ‘true’ for the address of ‘padapters’ will never be NULL [-Waddress]
4417 | if (!(ifbmp & BIT(i)) || !dvobj->padapters)
| ^
/var/lib/dkms/rtl8821CU/5.4.1/build/include/drv_types.h:1020:19: note: ‘padapters’ declared here
1020 | _adapter *padapters[CONFIG_IFACE_NUMBER];/*IFACE_ID_MAX*/
| ^~~~~~~~~
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/mesh/rtw_mesh.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/mesh/rtw_mesh_pathtbl.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/mesh/rtw_mesh_hwmp.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_xmit.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_p2p.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_rson.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_tdls.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_br_ext.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_iol.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_sreset.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_btcoex_wifionly.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_btcoex.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_beamforming.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_odm.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_rm.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/rtw_rm_fsm.o
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/core/efuse/rtw_efuse.o
/var/lib/dkms/rtl8821CU/5.4.1/build/core/efuse/rtw_efuse.c: In function ‘rtw_efuse_analyze’:
/var/lib/dkms/rtl8821CU/5.4.1/build/core/efuse/rtw_efuse.c:781:17: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
781 | if (i % 16 == 0)
| ^~
In file included from /var/lib/dkms/rtl8821CU/5.4.1/build/include/drv_types.h:60,
from /var/lib/dkms/rtl8821CU/5.4.1/build/core/efuse/rtw_efuse.c:17:
/var/lib/dkms/rtl8821CU/5.4.1/build/include/rtw_debug.h:231:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
231 | do {\
| ^~
/var/lib/dkms/rtl8821CU/5.4.1/build/core/efuse/rtw_efuse.c:783:25: note: in expansion of macro ‘_RTW_PRINT_SEL’
783 | _RTW_PRINT_SEL(RTW_DBGDUMP, "%02X%s"
| ^~~~~~~~~~~~~~
CC [M] /var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.o
/var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.c: In function ‘thread_exit’:
/var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.c:1297:9: error: implicit declaration of function ‘complete_and_exit’ [-Werror=implicit-function-declaration]
1297 | complete_and_exit(comp, 0);
| ^~~~~~~~~~~~~~~~~
/var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.c: In function ‘rtw_change_ifname’:
/var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.c:2490:28: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
2490 | _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
| ~~~~~~~^~~~~~~~~~
/var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.c:925:24: note: expected ‘void *’ but argument is of type ‘const unsigned char *’
925 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
| ~~~~~~^~~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:249: /var/lib/dkms/rtl8821CU/5.4.1/build/os_dep/osdep_service.o] Error 1
make[1]: *** [Makefile:1846: /var/lib/dkms/rtl8821CU/5.4.1/build] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.19.14-1-MANJARO/build'
make: *** [Makefile:2222: modules] Error 2
Logs above generated from a standard master branch without any modifications.
I'm trying to reinstall this driver after i upgraded the kernel of a machine from
5.15.74-3
to5.19.14-1-MANJARO
, but i'm getting some errors during the build process (it worked OOTB on5.15.74-3
).Build WITHOUT dkms:
Build with dkms:
Contents of the above mentioned
make.log
:Logs above generated from a standard
master branch
without any modifications.So far i've tried:
I'll try other things in the meantime, but any help is highly appreciated!