Jump to content

Recommended Posts

Posted

I want to install the usb wifi/bluetooth card drivers but I keep getting an error during compilation. What to do? below code:
 

DKMS make.log for rtl8812au-5.13.6 for kernel 5.10.110-rockchip-rk3588 (aarch64)
Tue Jan 10 08:48:19 PM CET 2023
make ARCH=arm64 CROSS_COMPILE= -C /lib/modules/5.10.110-rockchip-rk3588/build M=/var/lib/dkms/rtl8812au/5.13.6/build  modules
make[1]: Entering directory '/usr/src/linux-headers-5.10.110-rockchip-rk3588'
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_cmd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_security.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_debug.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_io.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_ioctl_query.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_ioctl_set.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_ieee80211.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_mlme.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_mlme_ext.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_mi.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_wlan_util.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_vht.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_pwrctrl.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_rf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_chplan.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/monitor/rtw_radiotap.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_recv.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_sta_mgt.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_ap.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/wds/rtw_wds.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/mesh/rtw_mesh.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/mesh/rtw_mesh_pathtbl.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/mesh/rtw_mesh_hwmp.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_xmit.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_p2p.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_rson.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_tdls.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_br_ext.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_iol.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_sreset.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_btcoex_wifionly.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_btcoex.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_beamforming.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_odm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_rm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_rm_fsm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_ft.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_wnm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_mbo.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_rm_util.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/efuse/rtw_efuse.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_roch.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-internal.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-internal-enc.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-gcm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-ccm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-omac1.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/ccmp.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/gcmp.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-siv.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/aes-ctr.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/sha256-internal.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/sha256.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/sha256-prf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/crypto/rtw_crypto_wrap.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/core/rtw_swcrypto.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/osdep_service.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/os_intfs.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/usb_intf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/usb_ops_linux.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/ioctl_linux.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/xmit_linux.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/mlme_linux.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/recv_linux.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/ioctl_cfg80211.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/rtw_cfgvendor.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/wifi_regd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/rtw_android.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/rtw_proc.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/nlrtw.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/os_dep/linux/rtw_rhashtable.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_intf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_com.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_com_phycfg.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_phy.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_dm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_dm_acs.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_btcoex_wifionly.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_btcoex.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_mp.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_mcc.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/hal_hci/hal_usb.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/led/hal_led.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/led/hal_usb_led.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/HalPwrSeqCmd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/Hal8812PwrSeq.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/Hal8821APwrSeq.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_xmit.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_sreset.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_hal_init.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_phycfg.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_rf6052.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_dm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_rxdesc.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/rtl8812a_cmd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/usb/usb_halinit.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/usb/rtl8812au_led.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/usb/rtl8812au_xmit.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/usb/rtl8812au_recv.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/usb/usb_ops_linux.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/efuse/rtl8812a/HalEfuseMask8812A_USB.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/rtl8812a/hal8812a_fw.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_debug.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_antdiv.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_soml.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_smt_ant.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_antdect.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_interface.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_phystatus.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_hwconfig.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_dig.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_pathdiv.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_rainfo.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_dynamictxpower.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_adaptivity.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_cfotracking.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_noisemonitor.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_beamforming.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_direct_bf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_dfs.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/txbf/halcomtxbf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/txbf/haltxbfinterface.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/txbf/phydm_hal_txbf_api.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_adc_sampling.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_ccx.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_psd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_primary_cca.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_cck_pd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_rssi_monitor.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_auto_dbg.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_math_lib.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_api.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_pow_train.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_lna_sat.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_pmac_tx_setting.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_mp.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/phydm_cck_rx_pathdiv.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halrf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halrf_debug.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halphyrf_ce.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halrf_powertracking_ce.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halrf_powertracking.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halrf_kfree.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/halrf_psd.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/rtl8812a/halhwimg8812a_mac.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/rtl8812a/halhwimg8812a_bb.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/rtl8812a/halhwimg8812a_rf.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/halrf/rtl8812a/halrf_8812a_ce.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/rtl8812a/phydm_regconfig8812a.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/rtl8812a/phydm_rtl8812a.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/hal/phydm/txbf/haltxbfjaguar.o
  CC [M]  /var/lib/dkms/rtl8812au/5.13.6/build/platform/platform_ops.o
  LD [M]  /var/lib/dkms/rtl8812au/5.13.6/build/8812au.o
  MODPOST /var/lib/dkms/rtl8812au/5.13.6/build/Module.symvers
ERROR: modpost: module 8812au uses symbol kernel_write from namespace VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver, but does not import it.
ERROR: modpost: module 8812au uses symbol kernel_read from namespace VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver, but does not import it.
ERROR: modpost: module 8812au uses symbol filp_open from namespace VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver, but does not import it.
make[2]: *** [scripts/Makefile.modpost:169: /var/lib/dkms/rtl8812au/5.13.6/build/Module.symvers] Error 1
make[2]: *** Deleting file '/var/lib/dkms/rtl8812au/5.13.6/build/Module.symvers'
make[1]: *** [Makefile:1822: modules] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.10.110-rockchip-rk3588'
make: *** [Makefile:2504: modules] Error 2

 

Posted

HEY @m8kbv, I've tried to build the wifi module on orange pi 5 and ended up with the same issue. You need to update the code with new imports in it to resolve the issue. https://stackoverflow.com/questions/70504141/error-when-inserting-kernel-module-module-uses-symbol-from-namespace-but/70504142#70504142

 

You likely to use morrownr/8812au repo. In that repo, There are 2 files to be updated: os_dep/osdep_service.c and core/rtw_wlan_util.c. But after that, the build will be failed due to missing `modules.lds` file.

 

That's the furthest I could get building the usb wifi dongle driver.

Posted

I have an Asus USB-N10 Nano B1 (https://www.asus.com/networking-iot-servers/adapters/all-series/usb-n10-nano-b1/) which has a Realtek 8188EUS chip in it. I'm able to make it work with my custom built image.

What I did:

1. git clone https://github.com/armbian/build.git

2. cd into the folder and sudo ./compile.sh

3. select expert mode and select orange pi 5 (WIP)

4. go with jammy (supported) and xfce (supported)  , or you can probably use other desktop environment but I haven't tested

5. make sure you do not select 3d packages (forgot the name, but it's the first option among browser, editor, multimedia, etc...), otherwise it's black screen when you login to the desktop environment.

6. let it configure

7. it will prompt and ask you something, and make sure you say yes when usb 8188eu comes out, then it will continue configuring

8. select realtek 8188eu under staging drivers

9. build (took about 90 mins on my laptop) and get your custom image under the output folder

 

The module should load automatically. I'm currently on kernel 5.10.110.

Note that this build also solves the problem that usb-c and usb 2.0 ports aren't working as well.

Posted (edited)

Try the following:

$ sudo apt install build-essential bc dkms git
$ cd /usr/src/linux-headers-5.10.110-rockchip-rk3588/
$ sudo make modules_prepare -k -i
$ cd ~
$ mkdir 8812au_driver
$ cd 8812au_driver
$ git clone https://github.com/morrownr/8812au-20210629.git
$ cd 8812au-20210629/os_dep/
$ nano osdep_service.c

 

Each time you find a filp_open() function call (you can find it with Ctrl+W), add the following line before, save the file (Ctrl+O) and exit (Ctrl+X):

MODULE_IMPORT_NS(VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver);

 

After that, continue:

$ cd ..
$ sudo ./install-driver.sh

 

Restart computer...

 

 

 

If you don't want to edit the file manually, here is the DIFF file:

diff --git a/os_dep/osdep_service.c b/os_dep/osdep_service.c
index 42d8832..0228768 100644
--- a/os_dep/osdep_service.c
+++ b/os_dep/osdep_service.c
@@ -2393,6 +2393,7 @@ static int openFile(struct file **fpp, const char *path, int flag, int mode)
 {
        struct file *fp;
 
+       MODULE_IMPORT_NS(VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver);
        fp = filp_open(path, flag, mode);
        if (IS_ERR(fp)) {
                *fpp = NULL;
@@ -2505,6 +2506,7 @@ static int isFileReadable(const char *path, u32 *sz)
        #endif
        char buf;
 
+       MODULE_IMPORT_NS(VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver);
        fp = filp_open(path, O_RDONLY, 0);
        if (IS_ERR(fp))
                ret = PTR_ERR(fp);

 

It worked here like a charm...

Edited by Fabricio Biazzotto
Just a little fix...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines