该楼层疑似违规已被系统折叠 隐藏此楼查看此楼
网上搜的资料,按照下面的命令操作了,但是进行到第二步就失败了。
第一步:git clone https://github.com/whitebatman2/rtl8821CU.gitcd rtl8821CU
第二步:make
第三步:sudo make install
第四步:sudo modprobe 8821cu
报错信息:[root@localhost rtl8821CU]# make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/4.18.0-240.el8.x86_64/build M=/home/james_kenway/rtl8821CU modules
make[1]: 进入目录“/usr/src/kernels/4.18.0-240.el8.x86_64”
CC [M] /home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.o
In file included from /home/james_kenway/rtl8821CU/include/drv_types.h:35,
from /home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.c:25:
/home/james_kenway/rtl8821CU/include/wifi.h:1019: 警告:“IEEE80211_MAX_AMPDU_BUF”重定义
#define IEEE80211_MAX_AMPDU_BUF 0x40
In file included from /home/james_kenway/rtl8821CU/include/osdep_service_linux.h:86,
from /home/james_kenway/rtl8821CU/include/osdep_service.h:47,
from /home/james_kenway/rtl8821CU/include/drv_types.h:32,
from /home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.c:25:
./include/linux/ieee80211.h:1463: 附注:这是先前定义的位置
#define IEEE80211_MAX_AMPDU_BUF 0x100
/home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.c: 在函数‘rtw_android_priv_cmd’中:
/home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.c:632:62: 错误:宏“access_ok”传递了 3 个参数,但只需要 2 个
if (!access_ok(VERIFY_READ, priv_cmd.buf, priv_cmd.total_len)) {
^
/home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.c:632:7: 错误:‘access_ok’未声明(在此函数内第一次使用)
if (!access_ok(VERIFY_READ, priv_cmd.buf, priv_cmd.total_len)) {
^~~~~~~~~
/home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.c:632:7: 附注:每个未声明的标识符在其出现的函数内只报告一次
make[2]: *** [scripts/Makefile.build:316:/home/james_kenway/rtl8821CU/os_dep/linux/rtw_android.o] 错误 1
make[1]: *** [Makefile:1544:_module_/home/james_kenway/rtl8821CU] 错误 2
make[1]: 离开目录“/usr/src/kernels/4.18.0-240.el8.x86_64”
make: *** [Makefile:1923:modules] 错误 2
内核版本信息如下:
[root@localhost rtl8821CU]# uname -a
Linux localhost.localdomain 4.18.0-240.el8.x86_64 #1 SMP Fri Sep 25 19:48:47 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux