Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: compiling/building the driver fails on Arch 6.13.1-arch1-1 at os_dep/linux/os_intfs.o: error: expected ‘,’ or ‘;’ before ‘VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver’ #49

Open
3 tasks done
BusterLundgaard opened this issue Feb 4, 2025 · 3 comments
Labels
bug Something isn't working

Comments

@BusterLundgaard
Copy link

Checklist

  • I am not using this driver from inside a Virtual Machine.
  • I performed all of the installation steps as written.
  • I have read the FAQ and my question is not answered there.

Is Secure Boot enabled?

No

uname

Linux buster 6.13.1-arch1-1 #1 SMP PREEMPT_DYNAMIC Sun, 02 Feb 2025 01:02:29 +0000 x86_64 GNU/Linux

lsusb

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 001 Device 003: ID 046d:c08b Logitech, Inc. G502 SE HERO Gaming Mouse Bus 001 Device 004: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode) Bus 001 Device 005: ID 2357:0101 TP-Link RTL8812AU Archer T4U 802.11ac Bus 001 Device 006: ID 1a2c:497a China Resource Semico Co., Ltd AFFFA0319 Bus 001 Device 008: ID 2717:ff80 Xiaomi Inc. Mi/Redmi series (RNDIS) Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

rfkill

0: hci0: Bluetooth Soft blocked: no Hard blocked: no

dkms

(none, i have nothing installed)

iw

(none)

git status

Your branch is up to date with 'origin/main'.

Untracked files:
  (use "git add <file>..." to include in what will be committed)
	.8812au.mod.cmd
	8812au.mod
	core/.rtw_ap.o.cmd
	core/.rtw_beamforming.o.cmd
	core/.rtw_br_ext.o.cmd
	core/.rtw_btcoex.o.cmd
	core/.rtw_btcoex_wifionly.o.cmd
	core/.rtw_chplan.o.cmd
	core/.rtw_cmd.o.cmd
	core/.rtw_debug.o.cmd
	core/.rtw_ft.o.cmd
	core/.rtw_ieee80211.o.cmd
	core/.rtw_io.o.cmd
	core/.rtw_ioctl_query.o.cmd
	core/.rtw_ioctl_set.o.cmd
	core/.rtw_iol.o.cmd
	core/.rtw_mbo.o.cmd
	core/.rtw_mi.o.cmd
	core/.rtw_mlme.o.cmd
	core/.rtw_mlme_ext.o.cmd
	core/.rtw_odm.o.cmd
	core/.rtw_p2p.o.cmd
	core/.rtw_pwrctrl.o.cmd
	core/.rtw_recv.o.cmd
	core/.rtw_rf.o.cmd
	core/.rtw_rm.o.cmd
	core/.rtw_rm_fsm.o.cmd
	core/.rtw_rm_util.o.cmd
	core/.rtw_roch.o.cmd
	core/.rtw_rson.o.cmd
	core/.rtw_security.o.cmd
	core/.rtw_sreset.o.cmd
	core/.rtw_sta_mgt.o.cmd
	core/.rtw_swcrypto.o.cmd
	core/.rtw_tdls.o.cmd
	core/.rtw_vht.o.cmd
	core/.rtw_wlan_util.o.cmd
	core/.rtw_wnm.o.cmd
	core/.rtw_xmit.o.cmd
	core/crypto/.aes-ccm.o.cmd
	core/crypto/.aes-ctr.o.cmd
	core/crypto/.aes-gcm.o.cmd
	core/crypto/.aes-internal-enc.o.cmd
	core/crypto/.aes-internal.o.cmd
	core/crypto/.aes-omac1.o.cmd
	core/crypto/.aes-siv.o.cmd
	core/crypto/.ccmp.o.cmd
	core/crypto/.gcmp.o.cmd
	core/crypto/.rtw_crypto_wrap.o.cmd
	core/crypto/.sha256-internal.o.cmd
	core/crypto/.sha256-prf.o.cmd
	core/crypto/.sha256.o.cmd
	core/crypto/aes-ccm.o
	core/crypto/aes-ctr.o
	core/crypto/aes-gcm.o
	core/crypto/aes-internal-enc.o
	core/crypto/aes-internal.o
	core/crypto/aes-omac1.o
	core/crypto/aes-siv.o
	core/crypto/ccmp.o
	core/crypto/gcmp.o
	core/crypto/rtw_crypto_wrap.o
	core/crypto/sha256-internal.o
	core/crypto/sha256-prf.o
	core/crypto/sha256.o
	core/efuse/.rtw_efuse.o.cmd
	core/efuse/rtw_efuse.o
	core/mesh/.rtw_mesh.o.cmd
	core/mesh/.rtw_mesh_hwmp.o.cmd
	core/mesh/.rtw_mesh_pathtbl.o.cmd
	core/mesh/rtw_mesh.o
	core/mesh/rtw_mesh_hwmp.o
	core/mesh/rtw_mesh_pathtbl.o
	core/monitor/.rtw_radiotap.o.cmd
	core/monitor/rtw_radiotap.o
	core/rtw_ap.o
	core/rtw_beamforming.o
	core/rtw_br_ext.o
	core/rtw_btcoex.o
	core/rtw_btcoex_wifionly.o
	core/rtw_chplan.o
	core/rtw_cmd.o
	core/rtw_debug.o
	core/rtw_ft.o
	core/rtw_ieee80211.o
	core/rtw_io.o
	core/rtw_ioctl_query.o
	core/rtw_ioctl_set.o
	core/rtw_iol.o
	core/rtw_mbo.o
	core/rtw_mi.o
	core/rtw_mlme.o
	core/rtw_mlme_ext.o
	core/rtw_odm.o
	core/rtw_p2p.o
	core/rtw_pwrctrl.o
	core/rtw_recv.o
	core/rtw_rf.o
	core/rtw_rm.o
	core/rtw_rm_fsm.o
	core/rtw_rm_util.o
	core/rtw_roch.o
	core/rtw_rson.o
	core/rtw_security.o
	core/rtw_sreset.o
	core/rtw_sta_mgt.o
	core/rtw_swcrypto.o
	core/rtw_tdls.o
	core/rtw_vht.o
	core/rtw_wlan_util.o
	core/rtw_wnm.o
	core/rtw_xmit.o
	core/wds/.rtw_wds.o.cmd
	core/wds/rtw_wds.o
	os_dep/.osdep_service.o.cmd
	os_dep/linux/.os_intfs.o.d
	os_dep/osdep_service.o

nothing added to commit but untracked files present (use "git add" to track)

install-driver.sh

: ---------------------------
: install-driver.sh v20241003
: x86_64 (kernel architecture)
: x86_64 (architecture to send to gcc)
: 12/12 (in-use/total processing units)
: 32714260 (total system memory)
: 6.13.1-arch1-1 (kernel version)
: gcc (version of gcc used to compile the kernel)
: gcc (GCC) 14.2.1 20250128
: dkms-3.1.5
: SecureBoot disabled
: ---------------------------

Checking for previously installed drivers...
Finished checking for and uninstalling previously installed drivers.
: ---------------------------

Starting installation.
Copying 8812au.conf to /etc/modprobe.d
The dkms installation routines are in use.
Copying source files to /usr/src/rtl8812au-5.13.6-23
Creating symlink /var/lib/dkms/rtl8812au/5.13.6-23/source -> /usr/src/rtl8812au-5.13.6-23
The driver was added to dkms successfully.
: ---------------------------

Sign command: /usr/lib/modules/6.13.1-arch1-1/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Cleaning build area... done.
Building module(s).....(bad exit status: 2)
Failed command:
kernelver=6.13.1-arch1-1 ./dkms-make.sh

Error! Bad return status for module build on kernel: 6.13.1-arch1-1 (x86_64)
Consult /var/lib/dkms/rtl8812au/5.13.6-23/build/make.log for more information.
An error occurred. dkms build error:  10
Please report this error.
Please copy all screen output and paste it into the problem report.
Run the following before reattempting installation.
$ sudo ./remove-driver.sh

What happened?

Hi! Since i couldn't connect to the internet after a recent update, i did what i usually do and:

-Tried to remove the rtl8812au driver using the uninstall script
-Uinstalled everything else in DKMS
-Updated everything with sudo pacman -Syu
-Reinstalled DKMS
-Tried to install rtl8812au with the install script again

But already when i was uninstalling i had issues. DKMS status said that the rtl8812au was "broken" and running the uninstall script i was told that it was missing the symbolic link. I then had to purge/remove rtl8812au.ko from /lib/modules/$(uname -r)/kernel/drivers/net/wireless/realtek/rtl8xxxu directly, and after running sudo depmod -a the driver seemed to be succesfully removed when i ran DKMS status.

As you can see, running the install-driver.sh script says that the build failed. I then ran make clean and make directly to have a more detailed look.

make clean gives me:

#make -C /lib/modules/6.13.1-arch1-1/build M=/home/buster/src/8812au-20210820 clean
cd hal ; rm -fr */*/*/*.mod.c */*/*/*.mod */*/*/*.o */*/*/.*.cmd */*/*/*.ko
cd hal ; rm -fr */*/*.mod.c */*/*.mod */*/*.o */*/.*.cmd */*/*.ko
cd hal ; rm -fr */*.mod.c */*.mod */*.o */.*.cmd */*.ko
cd hal ; rm -fr *.mod.c *.mod *.o .*.cmd *.ko
cd core ; rm -fr */*.mod.c */*.mod */*.o */.*.cmd */*.ko
cd core ; rm -fr *.mod.c *.mod *.o .*.cmd *.ko
cd os_dep/linux ; rm -fr *.mod.c *.mod *.o .*.cmd *.ko
cd os_dep ; rm -fr *.mod.c *.mod *.o .*.cmd *.ko
cd platform ; rm -fr *.mod.c *.mod *.o .*.cmd *.ko
rm -fr Module.symvers ; rm -fr Module.markers ; rm -fr modules.order
rm -fr *.mod.c *.mod *.o .*.cmd *.ko *~
rm -fr .tmp_versions
rm -fr MOK.der MOK.priv

make gives me:

make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/6.13.1-arch1-1/build M=/home/buster/src/8812au-20210820  modules
make[1]: Entering directory '/usr/lib/modules/6.13.1-arch1-1/build'
make[2]: Entering directory '/home/buster/src/8812au-20210820'
  CC [M]  core/rtw_cmd.o
  CC [M]  core/rtw_security.o
  CC [M]  core/rtw_debug.o
  CC [M]  core/rtw_io.o
  CC [M]  core/rtw_ioctl_query.o
  CC [M]  core/rtw_ioctl_set.o
  CC [M]  core/rtw_ieee80211.o
  CC [M]  core/rtw_mlme.o
  CC [M]  core/rtw_mlme_ext.o
  CC [M]  core/rtw_mi.o
  CC [M]  core/rtw_wlan_util.o
  CC [M]  core/rtw_vht.o
  CC [M]  core/rtw_pwrctrl.o
  CC [M]  core/rtw_rf.o
  CC [M]  core/rtw_chplan.o
  CC [M]  core/monitor/rtw_radiotap.o
  CC [M]  core/rtw_recv.o
  CC [M]  core/rtw_sta_mgt.o
  CC [M]  core/rtw_ap.o
  CC [M]  core/wds/rtw_wds.o
  CC [M]  core/mesh/rtw_mesh.o
  CC [M]  core/mesh/rtw_mesh_pathtbl.o
  CC [M]  core/mesh/rtw_mesh_hwmp.o
  CC [M]  core/rtw_xmit.o
  CC [M]  core/rtw_p2p.o
  CC [M]  core/rtw_rson.o
  CC [M]  core/rtw_tdls.o
  CC [M]  core/rtw_br_ext.o
  CC [M]  core/rtw_iol.o
  CC [M]  core/rtw_sreset.o
  CC [M]  core/rtw_btcoex_wifionly.o
  CC [M]  core/rtw_btcoex.o
  CC [M]  core/rtw_beamforming.o
  CC [M]  core/rtw_odm.o
  CC [M]  core/rtw_rm.o
  CC [M]  core/rtw_rm_fsm.o
  CC [M]  core/rtw_ft.o
  CC [M]  core/rtw_wnm.o
  CC [M]  core/rtw_mbo.o
  CC [M]  core/rtw_rm_util.o
  CC [M]  core/efuse/rtw_efuse.o
  CC [M]  core/rtw_roch.o
  CC [M]  core/crypto/aes-internal.o
  CC [M]  core/crypto/aes-internal-enc.o
  CC [M]  core/crypto/aes-gcm.o
  CC [M]  core/crypto/aes-ccm.o
  CC [M]  core/crypto/aes-omac1.o
  CC [M]  core/crypto/ccmp.o
  CC [M]  core/crypto/gcmp.o
  CC [M]  core/crypto/aes-siv.o
  CC [M]  core/crypto/aes-ctr.o
  CC [M]  core/crypto/sha256-internal.o
  CC [M]  core/crypto/sha256.o
  CC [M]  core/crypto/sha256-prf.o
  CC [M]  core/crypto/rtw_crypto_wrap.o
  CC [M]  core/rtw_swcrypto.o
  CC [M]  os_dep/osdep_service.o
  CC [M]  os_dep/linux/os_intfs.o
In file included from /usr/lib/modules/6.13.1-arch1-1/build/include/linux/module.h:22,
                 from ././include/basic_types.h:76,
                 from ././include/drv_types.h:26,
                 from os_dep/linux/os_intfs.c:17:
os_dep/linux/os_intfs.c:35:26: error: expected ‘,’ or ‘;’ before ‘VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver’
   35 |         MODULE_IMPORT_NS(VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver);
      |                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/lib/modules/6.13.1-arch1-1/build/include/linux/moduleparam.h:26:61: note: in definition of macro ‘__MODULE_INFO’
   26 |                 = __MODULE_INFO_PREFIX __stringify(tag) "=" info
      |                                                             ^~~~
/usr/lib/modules/6.13.1-arch1-1/build/include/linux/module.h:299:33: note: in expansion of macro ‘MODULE_INFO’
  299 | #define MODULE_IMPORT_NS(ns)    MODULE_INFO(import_ns, ns)
      |                                 ^~~~~~~~~~~
os_dep/linux/os_intfs.c:35:9: note: in expansion of macro ‘MODULE_IMPORT_NS’
   35 |         MODULE_IMPORT_NS(VFS_internal_I_am_really_a_filesystem_and_am_NOT_a_driver);
      |         ^~~~~~~~~~~~~~~~
make[4]: *** [/usr/lib/modules/6.13.1-arch1-1/build/scripts/Makefile.build:194: os_dep/linux/os_intfs.o] Error 1
make[3]: *** [/usr/lib/modules/6.13.1-arch1-1/build/Makefile:1989: .] Error 2
make[2]: *** [/usr/lib/modules/6.13.1-arch1-1/build/Makefile:251: __sub-make] Error 2
make[2]: Leaving directory '/home/buster/src/8812au-20210820'
make[1]: *** [Makefile:251: __sub-make] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.13.1-arch1-1/build'
make: *** [Makefile:2516: modules] Error 2

This seems like a bug no? But maybe i messed something up by trying to uninstall directly. I don't quite know where to go from here though.

Kind regards, and thanks for the amazing work!

@BusterLundgaard BusterLundgaard added the bug Something isn't working label Feb 4, 2025
@morrownr
Copy link
Owner

morrownr commented Feb 4, 2025

Hi @BusterLundgaard

This seems like a bug no?

We can call it a bug. It is just the periodic updates to kernel APIs that require maintenance to this driver to continue to work. You are out on the bleeding edge I see.

I have merged a patch that should take care of the problem but I need you to test and report back.

To apply the changes:

$ git pull

$ sudo sh install-driver.sh

FYI: When you get to kernel 6.14, a new in-kernel driver will be there so your adapter should be plug and play. Hopefully your distro adds the firmware and turns on the compilation of the driver. If you have problems, let me know.

@BusterLundgaard
Copy link
Author

It works! Thanks so much!
Also, the plug and play sounds like a great thing to look forward to haha.

@morrownr
Copy link
Owner

morrownr commented Feb 4, 2025

Thanks for the report.

Also, the plug and play sounds like a great thing to look forward to haha.

It is a very good thing. The new driver is much better than this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants