Giter Club home page Giter Club logo

rtl8852be's Introduction

RTL8852BE

github
githubSee Here:HRex39/rtl8852be_bt.

github
For kernel > 6.0.0, You should view lwfinger/rtw8852be. https://github.com/lwfinger/rtw89

LTS

github
Support CI/CD based on Github-hosted runners: Ubuntu 18.04, Ubuntu 20.04, Ubuntu 22.04.

Unstable

github github github github

Introduction

This code is cloned from TinkerBoard2/kernel and it's author is Rock_Shen ([email protected]).
The default compilation option is i386_PC For Linux, you can also change the compilation options of MAKEFILE in line149.

Prerequisites (for Ubuntu/Debian)

build-essential 
linux-headers
bc

Prerequisites (for Fedora)

kernel-headers
kernel-devel-`uname -r`
make
automake
cmake
gcc
gcc-c++
bc

Build(for kernel < 5.18)

#Turn off your Security Boot in BIOS

git clone https://github.com/HRex39/rtl8852be.git
cd rtl8852be
make -j8
sudo make install
sudo modprobe 8852be

Build(for kernel >= 5.18)

#Turn off your Security Boot in BIOS

git clone https://github.com/HRex39/rtl8852be.git -b dev
cd rtl8852be
make -j8
sudo make install
sudo modprobe 8852be

WHAT IS LINUX?

WHAT IS LINUX?

  Linux is a clone of the operating system Unix, written from scratch by
  Linus Torvalds with assistance from a loosely-knit team of hackers across
  the Net. It aims towards POSIX and Single UNIX Specification compliance.

  It has all the features you would expect in a modern fully-fledged Unix,
  including true multitasking, virtual memory, shared libraries, demand
  loading, shared copy-on-write executables, proper memory management,
  and multistack networking including IPv4 and IPv6.

  It is distributed under the GNU General Public License - see the
  accompanying COPYING file for more details. 

rtl8852be's People

Contributors

hrex39 avatar thaneesh-babu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rtl8852be's Issues

modprobe: ERROR: could not insert '8852be': Invalid argument

I have a laptop with Ryzen 6800H CPU.
The keyboard fails to work, but fixed according to https://lore.kernel.org/all/[email protected]/ . Patched /drivers/acpi/resource.c file. Then recompiled the kernel according to https://wiki.ubuntu.com/Kernel/BuildYourOwnKernel. The kernel version is 5.15.0-46.49.
Now, the keyboard works as expected.

The compile of rtl8852be driver passed with no errors.
But fails to load into the kernel.

modprobe: ERROR: could not insert '8852be': Invalid argument

Not sure why.

With the original kernel from Ubuntu, the rtl8852be driver compiles and loads successfully.

Compile failed when i update the new kernal 5.19.2.

╭─cres@cres in ~/rtw8852be on main ✔ (origin/main)

╰$ make -j8    
#rm -f .symvers.8852be
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.19.2-arch1-1/build M=/home/cres/rtw8852be  modules
make[1]: 进入目录“/usr/lib/modules/5.19.2-arch1-1/build”
  CC [M]  /home/cres/rtw8852be/platform/platform_linux_pc_pci.o
  CC [M]  /home/cres/rtw8852be/os_dep/osdep_service.o
  CC [M]  /home/cres/rtw8852be/os_dep/osdep_service_linux.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/rtw_cfg.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/ioctl_linux.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/os_intfs.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/xmit_linux.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/mlme_linux.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/recv_linux.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/rtw_cfgvendor.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/wifi_regd.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/rtw_android.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/rtw_proc.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/nlrtw.o
  CC [M]  /home/cres/rtw8852be/os_dep/linux/rtw_rhashtable.o
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c: 在函数‘rtw_cfg80211_ch_switch_notify’中:
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:513:9: 错误:提供给函数‘cfg80211_ch_switch_notify’的实参太少
  513 |         cfg80211_ch_switch_notify(adapter->pnetdev, &chdef);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/cres/rtw8852be/include/osdep_service_linux.h:100,
                 from /home/cres/rtw8852be/include/osdep_service.h:42,
                 from /home/cres/rtw8852be/include/drv_types.h:25,
                 from /home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:17:
./include/net/cfg80211.h:7967:6: 附注:在此声明
 7967 | void cfg80211_ch_switch_notify(struct net_device *dev,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c: 在文件作用域:
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:10619:20: 错误:initialization of ‘int (*)(struct wiphy *, struct net_device *, unsigned int)’ from incompatible pointer type ‘int (*)(struct wiphy *, struct net_device *)’ [-Werror=incompatible-pointer-types]
10619 |         .stop_ap = cfg80211_rtw_stop_ap,
      |                    ^~~~~~~~~~~~~~~~~~~~
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:10619:20: 附注:(在‘rtw_cfg80211_ops.stop_ap’的初始化附近)
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:10661:24: 错误:initialization of ‘int (*)(struct wiphy *, struct wireless_dev *, unsigned int,  struct cfg80211_chan_def *)’ from incompatible pointer type ‘int (*)(struct wiphy *, struct wireless_dev *, struct cfg80211_chan_def *)’ [-Werror=incompatible-pointer-types]
10661 |         .get_channel = cfg80211_rtw_get_channel,
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:10661:24: 附注:(在‘rtw_cfg80211_ops.get_channel’的初始化附近)
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c: 在函数‘rtw_wdev_unregister’中:
/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.c:10917:17: 错误:‘struct wireless_dev’没有名为‘current_bss’的成员
10917 |         if (wdev->current_bss) {
      |                 ^~
cc1:有些警告被当作是错误
make[2]: *** [scripts/Makefile.build:249:/home/cres/rtw8852be/os_dep/linux/ioctl_cfg80211.o] 错误 1
make[2]: *** 正在等待未完成的任务....
make[1]: *** [Makefile:1849:/home/cres/rtw8852be] 错误 2
make[1]: 离开目录“/usr/lib/modules/5.19.2-arch1-1/build”
make: *** [Makefile:770:modules] 错误 2

thinkbook14+ 网卡 8852be arch 5.17.5 使用 git:dev-linux5.17 分支编译失败

arch 版本

$ neofetch
                   -`                    ifnk@ifnk
                  .o+`                   ---------
                 `ooo/                   OS: Arch Linux x86_64
                `+oooo:                  Host: 21CX ThinkBook 14 G4+ IAP
               `+oooooo:                 Kernel: 5.17.5-arch1-2
               -+oooooo+:                Uptime: 11 mins
             `/:-:++oooo+:               Packages: 1140 (pacman)
            `/++++/+++++++:              Shell: zsh 5.8.1
           `/++++++++++++++:             Resolution: 1920x1080
          `/+++ooooooooooooo/`           WM: i3
         ./ooosssso++osssssso+`          Theme: Adwaita [GTK2/3]
        .oossssso-````/ossssss+`         Icons: Adwaita [GTK2/3]
       -osssssso.      :ssssssso.        Terminal: alacritty
      :osssssss/        osssso+++.       CPU: 12th Gen Intel i7-12700H (20) @ 4.600GHz
     /ossssssss/        +ssssooo/-       GPU: Intel Alder Lake-P
   `/ossssso+/:-        -:/+osssso+-     Memory: 2370MiB / 31827MiB
  `+sso+:-`                 `.-/+oso:
 `++:.                           `-/+/
 .`                                 `/

网卡 问 联想公众号的官方客服 告诉我 无线网卡 是 瑞昱 的 8852be

根据 readme for kernel >= 5.15 流程走

报错如下

# ifnk @ ifnk in ~/github/rtl8852be on git:dev-linux5.17 o [9:48:02]
$ make -j8
#rm -f .symvers.8852be
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.17.5-arch1-2/build M=/home/ifnk/github/rtl8852be  modules
make[1]: 进入目录“/usr/lib/modules/5.17.5-arch1-2/build”
  CC [M]  /home/ifnk/github/rtl8852be/os_dep/linux/rtw_proc.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_vht.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_he.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_pwrctrl.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_rf.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_chplan.o
  CC [M]  /home/ifnk/github/rtl8852be/core/monitor/rtw_radiotap.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_recv.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_recv_shortcut.o
/home/ifnk/github/rtl8852be/os_dep/linux/rtw_proc.c: 在函数‘rtw_drv_proc_open’中:
/home/ifnk/github/rtl8852be/os_dep/linux/rtw_proc.c:293:34: 错误:implicit declaration of function ‘PDE_DATA’; did you mean ‘NODE_DATA’? [-Werror=implicit-function-declaration]
  293 |         ssize_t index = (ssize_t)PDE_DATA(inode);
      |                                  ^~~~~~~~
      |                                  NODE_DATA
/home/ifnk/github/rtl8852be/core/rtw_vht.c: 在函数‘rtw_reattach_vht_ies’中:
/home/ifnk/github/rtl8852be/core/rtw_vht.c:1423:27: 警告:the comparison will always evaluate as ‘true’ for the address of ‘IEs’ will never be NULL [-Waddress]
 1423 |         if (pnetwork->IEs != NULL) {
      |                           ^~
In file included from /home/ifnk/github/rtl8852be/include/drv_types.h:27,
                 from /home/ifnk/github/rtl8852be/core/rtw_vht.c:17:
/home/ifnk/github/rtl8852be/include/wlan_bssdef.h:245:13: 附注:‘IEs’在此声明
  245 |         u8  IEs[MAX_IE_SZ];     /* (timestamp, beacon interval, and capability information) */
      |             ^~~
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_sta_mgt.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_ap.o
  CC [M]  /home/ifnk/github/rtl8852be/core/rtw_csa.o
  CC [M]  /home/ifnk/github/rtl8852be/core/wds/rtw_wds.o
  CC [M]  /home/ifnk/github/rtl8852be/core/mesh/rtw_mesh.o
  CC [M]  /home/ifnk/github/rtl8852be/core/mesh/rtw_mesh_pathtbl.o
cc1:有些警告被当作是错误
make[2]: *** [scripts/Makefile.build:288:/home/ifnk/github/rtl8852be/os_dep/linux/rtw_proc.o] 错误 1
make[2]: *** 正在等待未完成的任务....
/home/ifnk/github/rtl8852be/core/rtw_sta_mgt.c: 在函数‘rtw_mfree_stainfo’中:
/home/ifnk/github/rtl8852be/core/rtw_sta_mgt.c:389:25: 警告:the comparison will always evaluate as ‘true’ for the address of ‘lock’ will never be NULL [-Waddress]
  389 |         if (&psta->lock != NULL)
      |                         ^~
In file included from /home/ifnk/github/rtl8852be/include/drv_types.h:110,
                 from /home/ifnk/github/rtl8852be/core/rtw_sta_mgt.c:17:
/home/ifnk/github/rtl8852be/include/sta_info.h:273:17: 附注:‘lock’在此声明
  273 |         _lock   lock;
      |                 ^~~~
make[1]: *** [Makefile:1831:/home/ifnk/github/rtl8852be] 错误 2
make[1]: 离开目录“/usr/lib/modules/5.17.5-arch1-2/build”
make: *** [Makefile:637:modules] 错误 2

请问是什么问题呢 ……

kernel 5.18.1 编译失败

uname -a Linux archlinux 5.18.1-arch1-1

error:

#rm -f .symvers.8852be
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.18.1-arch1-1/build M=/home/dong/code/rtl8852be  modules
make[1]: 进入目录“/usr/lib/modules/5.18.1-arch1-1/build”
  CC [M]  /home/dong/code/rtl8852be/platform/platform_linux_pc_pci.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/osdep_service.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/osdep_service_linux.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/rtw_cfg.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/os_intfs.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/ioctl_linux.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/xmit_linux.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/mlme_linux.o
/home/dong/code/rtl8852be/os_dep/linux/os_intfs.c: 在函数‘rtw_net_set_mac_address’中:
/home/dong/code/rtl8852be/os_dep/linux/os_intfs.c:79:28: 警告:passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
   79 |         _rtw_memcpy(pnetdev->dev_addr, sa->sa_data, ETH_ALEN); /* set mac addr to net_device */
      |                     ~~~~~~~^~~~~~~~~~
In file included from /home/dong/code/rtl8852be/include/drv_types.h:25,
                 from /home/dong/code/rtl8852be/os_dep/linux/os_intfs.c:17:
/home/dong/code/rtl8852be/include/osdep_service.h:281:24: 附注:需要类型‘void *’,但实参的类型为‘const unsigned char *’
  281 | void _rtw_memcpy(void *dec, const void *sour, u32 sz);
      |                  ~~~~~~^~~
/home/dong/code/rtl8852be/os_dep/osdep_service_linux.c: 在函数‘rtw_change_ifname’中:
/home/dong/code/rtl8852be/os_dep/osdep_service_linux.c:810:28: 警告:passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
  810 |         _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
      |                     ~~~~~~~^~~~~~~~~~
/home/dong/code/rtl8852be/os_dep/osdep_service_linux.c:48:24: 附注:需要类型‘void *’,但实参的类型为‘const unsigned char *’
   48 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
      |                  ~~~~~~^~~
/home/dong/code/rtl8852be/os_dep/linux/os_intfs.c: 在函数‘rtw_os_ndev_register’中:
/home/dong/code/rtl8852be/os_dep/linux/os_intfs.c:623:25: 警告:passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
  623 |         _rtw_memcpy(ndev->dev_addr, adapter_mac_addr(adapter), ETH_ALEN);
      |                     ~~~~^~~~~~~~~~
/home/dong/code/rtl8852be/include/osdep_service.h:281:24: 附注:需要类型‘void *’,但实参的类型为‘const unsigned char *’
  281 | void _rtw_memcpy(void *dec, const void *sour, u32 sz);
      |                  ~~~~~~^~~
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c: 在函数‘pci_cache_wback’中:
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c:21:17: 错误:implicit declaration of function ‘pci_dma_sync_single_for_device’; did you mean ‘dma_sync_single_for_device’? [-Werror=implicit-function-declaration]
   21 |                 pci_dma_sync_single_for_device(hwdev, *bus_addr, size,
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                 dma_sync_single_for_device
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c: 在函数‘pci_cache_inv’中:
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c:30:17: 错误:implicit declaration of function ‘pci_dma_sync_single_for_cpu’; did you mean ‘dma_sync_single_for_cpu’? [-Werror=implicit-function-declaration]
   30 |                 pci_dma_sync_single_for_cpu(hwdev, *bus_addr, size, direction);
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                 dma_sync_single_for_cpu
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c: 在函数‘pci_get_bus_addr’中:
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c:39:29: 错误:implicit declaration of function ‘pci_map_single’; did you mean ‘dma_map_single’? [-Werror=implicit-function-declaration]
   39 |                 *bus_addr = pci_map_single(hwdev, vir_addr, size, direction);
      |                             ^~~~~~~~~~~~~~
      |                             dma_map_single
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c: 在函数‘pci_unmap_bus_addr’中:
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c:50:17: 错误:implicit declaration of function ‘pci_unmap_single’; did you mean ‘dma_unmap_single’? [-Werror=implicit-function-declaration]
   50 |                 pci_unmap_single(hwdev, *bus_addr, size, direction);
      |                 ^~~~~~~~~~~~~~~~
      |                 dma_unmap_single
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/recv_linux.o
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c: 在函数‘pci_free_noncache_mem’中:
/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.c:97:17: 错误:隐式声明函数‘pci_free_consistent’ [-Werror=implicit-function-declaration]
   97 |                 pci_free_consistent(pdev, size, vir_addr, *bus_addr);
      |                 ^~~~~~~~~~~~~~~~~~~
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/ioctl_cfg80211.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/rtw_cfgvendor.o
  CC [M]  /home/dong/code/rtl8852be/os_dep/linux/wifi_regd.o
cc1:有些警告被当作是错误
make[2]: *** [scripts/Makefile.build:288:/home/dong/code/rtl8852be/platform/platform_linux_pc_pci.o] 错误 1
make[2]: *** 正在等待未完成的任务....
/home/dong/code/rtl8852be/os_dep/linux/ioctl_cfg80211.c: 在函数‘rtw_get_chbwoff_from_cfg80211_chan_def’中:
/home/dong/code/rtl8852be/os_dep/linux/ioctl_cfg80211.c:6233:21: 警告:this statement may fall through [-Wimplicit-fallthrough=]
 6233 |                 *ht = 0;
      |                 ~~~~^~~
/home/dong/code/rtl8852be/os_dep/linux/ioctl_cfg80211.c:6235:9: 附注:here
 6235 |         case NL80211_CHAN_WIDTH_20:
      |         ^~~~
make[1]: *** [Makefile:1834:/home/dong/code/rtl8852be] 错误 2
make[1]: 离开目录“/usr/lib/modules/5.18.1-arch1-1/build”
make: *** [Makefile:637:modules] 错误 2

archlinux compile error

os: archlinux
kernerl version: Linux laptop 5.17.3-arch1-1 #1 SMP PREEMPT Thu, 14 Apr 2022 01:18:36 +0000 x86_64 GNU/Linux
platform: x86_64
config:

CONFIG_PLATFORM_I386_PC = y
CONFIG_PLATFORM_RTL8198D = n
CONFIG_PLATFORM_ANDROID_X86 = n
CONFIG_PLATFORM_ANDROID_INTEL_X86 = n
CONFIG_PLATFORM_NV_TK1 = n
CONFIG_PLATFORM_NV_TK1_UBUNTU = n
CONFIG_PLATFORM_ARM_SUNxI = n
CONFIG_PLATFORM_RTK1319 = n
CONFIG_PLATFORM_RTK16XXB = n
CONFIG_PLATFORM_AML_S905 = n
CONFIG_PLATFORM_HUANGLONG = n
CONFIG_PLATFORM_ARM_RK3399 = n

When I tried to compile the firmware of rtl8852be for this machine, the following error occurred:

#rm -f .symvers.8852be
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.17.3-arch1-1/build M=/home/evine/scripts/rtl8852be  modules
make[1]: Entering directory '/usr/lib/modules/5.17.3-arch1-1/build'
  CC [M]  /home/evine/scripts/rtl8852be/platform/platform_linux_pc_pci.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/osdep_service.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/osdep_service_linux.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/linux/rtw_cfg.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/linux/ioctl_linux.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/linux/xmit_linux.o
  CC [M]  /home/evine/scripts/rtl8852be/os_dep/linux/mlme_linux.o
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/osdep_service_linux.c:16:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/osdep_service.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/xmit_linux.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/mlme_linux.c:19:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/ioctl_linux.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/platform/platform_linux_pc_pci.c:15:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/osdep_service.h:42,
                 from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/rtw_cfg.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h: In function 'rtw_thread_exit':
/home/evine/scripts/rtl8852be/include/osdep_service_linux.h:491:9: error: implicit declaration of function 'complete_and_exit' [-Werror=implicit-function-declaration]
  491 |         complete_and_exit(comp, 0);
      |         ^~~~~~~~~~~~~~~~~
/home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c: In function 'rtw_net_set_mac_address':
/home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c:79:28: warning: passing argument 1 of '_rtw_memcpy' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
   79 |         _rtw_memcpy(pnetdev->dev_addr, sa->sa_data, ETH_ALEN); /* set mac addr to net_device */
      |                     ~~~~~~~^~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service.h:281:24: note: expected 'void *' but argument is of type 'const unsigned char *'
  281 | void _rtw_memcpy(void *dec, const void *sour, u32 sz);
      |                  ~~~~~~^~~
/home/evine/scripts/rtl8852be/os_dep/osdep_service_linux.c: In function 'rtw_change_ifname':
/home/evine/scripts/rtl8852be/os_dep/osdep_service_linux.c:810:28: warning: passing argument 1 of '_rtw_memcpy' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
  810 |         _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
      |                     ~~~~~~~^~~~~~~~~~
/home/evine/scripts/rtl8852be/os_dep/osdep_service_linux.c:48:24: note: expected 'void *' but argument is of type 'const unsigned char *'
   48 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
      |                  ~~~~~~^~~
/home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c: In function 'rtw_os_ndev_register':
/home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c:623:25: warning: passing argument 1 of '_rtw_memcpy' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
  623 |         _rtw_memcpy(ndev->dev_addr, adapter_mac_addr(adapter), ETH_ALEN);
      |                     ~~~~^~~~~~~~~~
In file included from /home/evine/scripts/rtl8852be/include/drv_types.h:25,
                 from /home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.c:17:
/home/evine/scripts/rtl8852be/include/osdep_service.h:281:24: note: expected 'void *' but argument is of type 'const unsigned char *'
  281 | void _rtw_memcpy(void *dec, const void *sour, u32 sz);
      |                  ~~~~~~^~~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/platform/platform_linux_pc_pci.o] Error 1
make[2]: *** Waiting for unfinished jobs....
cc1: some warnings being treated as errors
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/linux/mlme_linux.o] Error 1
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/linux/xmit_linux.o] Error 1
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/osdep_service_linux.o] Error 1
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/linux/rtw_cfg.o] Error 1
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/osdep_service.o] Error 1
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/linux/os_intfs.o] Error 1
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/evine/scripts/rtl8852be/os_dep/linux/ioctl_linux.o] Error 1
make[1]: *** [Makefile:1831: /home/evine/scripts/rtl8852be] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.17.3-arch1-1/build'
make: *** [Makefile:637: modules] Error 2

该驱动的5.17分支在5.15版本内核编译失败的问题

首先非常感谢作者对于这个无线网卡所作的工作,让我最终能够在ubuntu下使用无线网络。
我的电脑是联想thinkbook 14+,系统环境是ubuntu 22.04LTS,默认内核是5.15.0版本,在使用此驱动的5.17分支,编译时,报出pde_data定义冲突错误,我只是简单说明下过程啊,具体报文就不贴出来了。后来参考了前面的讨论,将rtw_proc.c文件里的pde_data 全部替换成了PDE_DATA,最终顺利编译通过,安装后也可正常使用了。
不过有意思的是,我后来将系统内核升级到了5.17.6,发现改后的源文件没办法正常编译了,又爆出PDE_DATA定义冲突错误,然后,我又将它改回了pde_data,结果顺利编译通过,并安装成功了。想问问这是为什么呢?以及该分支版本的驱动文件是对所有5.15版本以上的内核都通用吗?
另外一个问题,这个8852be芯片,是个包含无线和蓝牙的芯片,我这部笔记本电脑目前的蓝牙在linux下还是用不了,查了很多信息,但没找到合适的驱动,作者能否把这个问题也解决一下呢?非常感谢并期盼您的回复

Testing Result Feedback

This issue is for testing result feedback.
You can comment your test result via following format.
Like:

PC brands: ThinkBook 16 G4+ IAP
OS: Ubuntu 22.04
Kernel Version: 5.15.0-25-generic
branch: main
Status: Build pass and Wi-Fi Connected

make error

archlinux 5.18.3
error message
ps: The bc, build-essential, linux-header have been installed.

❯ make
#rm -f .symvers.8852be
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.18.3-arch1-1/build M=/home/mika/rtl8852be  modules
make[1]: *** /lib/modules/5.18.3-arch1-1/build: No such file or directory.  Stop.
make: *** [Makefile:637: modules] Error 2

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.