Giter Club home page Giter Club logo

rtl8812bu's Introduction

Realtek RTL8812BU Driver for Linux

Build Status

Driver for 802.11ac USB adapter with RTL8812BU chipset, only STA/Monitor mode is supported, no AP mode.

A few known wireless cards that use this driver include:

  • Fastoe AC1200 USB Wi-Fi Adapter
  • Cudy WU1200 AC1200 High Gain USB Wi-Fi Adapter
  • TP-Link Archer T3U
  • TP-Link Archer T3U Plus
  • TP-Link Archer T4U V3
  • Linksys WUSB6400M
  • Dlink DWA-181
  • Dlink DWA-182

Currently tested with Linux kernel 4.12.14/4.15.0/5.3.0/5.15.0 on X86_64 platform only.

For Raspberry Pi

For kernel 5.11 or later, please clone the v5.13.1 branch:

sudo apt update
sudo apt install -y build-essential dkms git bc
git clone -b v5.13.1 https://github.com/fastoe/RTL8812BU.git
cd RTL8812BU
make
sudo make install
sudo reboot

For 5.10 kernel, please clone the v5.6.1 branch:

sudo apt update
sudo apt install -y build-essential dkms git bc
git clone -b v5.6.1 https://github.com/fastoe/RTL8812BU.git
cd RTL8812BU
make
sudo make install
sudo reboot

For 5.9 and previous versions:

sudo apt update
sudo apt install -y build-essential dkms git bc
git clone https://github.com/fastoe/RTL8812BU.git
cd RTL8812BU
make
sudo make install
sudo reboot

For setting monitor mode:

# configure for monitor mode
sed -i 's/CONFIG_80211W = n/CONFIG_80211W = y/' Makefile
sed -i 's/CONFIG_WIFI_MONITOR = n/CONFIG_WIFI_MONITOR = y/' Makefile

make
sudo make install
sudo ip link set wlx1cbfcea97791 down
sudo iw wlx1cbfcea97791 set monitor none
sudo ip link set wlx1cbfcea97791 up

image

Enjoy!

rtl8812bu's People

Contributors

aknoryx28 avatar fastoe 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

rtl8812bu's Issues

Make fails with kernel 5.17+

Running make on kernel 5.17 results in the following

fredrik@pop-os:~/RTL8812BU-5.8.7$ make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.17.5-76051705-generic/build M=/home/fredrik/RTL8812BU-5.8.7 modules
make[1]: Entering directory '/usr/src/linux-headers-5.17.5-76051705-generic'
CC [M] /home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.o
/home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.c: In function ‘thread_exit’:
/home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.c:1302:9: error: implicit declaration of function ‘complete_and_exit’ [-Werror=implicit-function-declaration]
1302 | complete_and_exit(comp, 0);
| ^~~~~~~~~~~~~~~~~
/home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.c: In function ‘rtw_change_ifname’:
/home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.c:2564:28: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
2564 | _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
| ~~~~~~~^~~~~~~~~~
/home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.c:922:24: note: expected ‘void *’ but argument is of type ‘const unsigned char *’
922 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
| ~~~~~~^~~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/fredrik/RTL8812BU-5.8.7/os_dep/osdep_service.o] Error 1
make[1]: *** [Makefile:1837: /home/fredrik/RTL8812BU-5.8.7] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.17.5-76051705-generic'
make: *** [Makefile:2390: modules] Error 2

Error during installation

Hello, For a long time this method works, although I had to repeat the installation of the drivers from time to time, the WiFi card stopped working.
But now, when I try to reinstall, an error pops up (I will only add that the WiFi card works under windows, so WiFi card is working)
a screenshot of the terminal

Module is not signed, so udev refuses to load without extra steps

I am running Ubuntu 20.04 with kernel 5.13.0-28-generic. If I insert the usb device I get the following log message,

[  608.093375] Lockdown: systemd-udevd: unsigned module loading is restricted; see man kernel_lockdown.7

I am using a "Dootoper AC 1200 Dual-Band USB 3.0 Adapter" with a Realtek 8812bu ic.
Otherwise everything worked.

Add Zoolan Wireless USB WiFi Adapter AC1200

Amazon site, vendor only sells here?
https://www.amazon.com/dp/B0995TNB3M?psc=1&ref=ppx_yo2ov_dt_b_product_details

Vendor site Zoolan claims only sold at Amazon.
https://www.zoolantech.com/product/html/138.html

Unit opened up and verified RTL8812BU has USB 3.0 interface and plug, however unit connects to and shows as a 2.0 device.

lsusb
Bus 002 Device 006: ID 0bda:b812 Realtek Semiconductor Corp. RTL88x2bu [AC1200 Techkey]

lsusb -t
/: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M
|__ Port 2: Dev 2, If 0, Class=Hub, Driver=hub/4p, 480M
|__ Port 3: Dev 4, If 3, Class=Human Interface Device, Driver=usbhid, 12M
|__ Port 3: Dev 4, If 1, Class=Audio, Driver=snd-usb-audio, 12M
|__ Port 3: Dev 4, If 2, Class=Audio, Driver=snd-usb-audio, 12M
|__ Port 3: Dev 4, If 0, Class=Audio, Driver=snd-usb-audio, 12M
|__ Port 4: Dev 6, If 0, Class=Vendor Specific Class, Driver=rtl88x2bu, 480M

lsusb -v -d 0bda:b812 | grep -i interface
bNumInterfaces 1
Interface Descriptor:
bInterfaceNumber 0
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 255 Vendor Specific Subclass
bInterfaceProtocol 255 Vendor Specific Protocol802.11ac NIC

USBView

Manufacturer: Realtek
Serial Number: 123456
Speed: 480Mb/s (high)
Bus: 2
Address: 6
USB Version: 2.10
Device Class: 00(>ifc )
Device Subclass: 00
Device Protocol: 00
Maximum Default Endpoint Size: 64
Number of Configurations: 1
Vendor Id: 0bda
Product Id: b812
Revision Number: 2.10

Config Number: 1
Number of Interfaces: 1
Attributes: 80
MaxPower Needed: 500mA

Interface Number: 0
	Name: rtl88x2bu
	Alternate Number: 0
	Class: ff(vend.) 
	Sub Class: ff
	Protocol: ff
	Number of Endpoints: 5

		Endpoint Address: 84
		Direction: in
		Attribute: 2
		Type: Bulk
		Max Packet Size: 512
		Interval: 0ms

		Endpoint Address: 05
		Direction: out
		Attribute: 2
		Type: Bulk
		Max Packet Size: 512
		Interval: 0ms

		Endpoint Address: 06
		Direction: out
		Attribute: 2
		Type: Bulk
		Max Packet Size: 512
		Interval: 0ms

		Endpoint Address: 87
		Direction: in
		Attribute: 3
		Type: Int.
		Max Packet Size: 64
		Interval: 500us

		Endpoint Address: 08
		Direction: out
		Attribute: 2
		Type: Bulk
		Max Packet Size: 512
		Interval: 0ms
  iInterface              2 802.11ac NIC

USBView

Can't run dkms build command!

I receive this error when applying "sudo dkms build -m rtl88x2bu -v ${VER}" command:

Error! echo
Your kernel headers for kernel 5.5.0-kali2-amd64 cannot be found at /lib/modules/5.5.0-kali2-amd64/build or /lib/modules/5.5.0-kali2-amd64/source.

I'm running this on a Kali2020.2 VM as guest on a Win10 host machine.

Mode monitor not work

Hello,

I am testing the controller but monitor mode is not working.

He activated the parameter:

CONFIG_WIFI_MONITOR = y

But running airodump doesn't show any network.

CH 9 ][ Elapsed: 6 s ][ 2020-04-29 12:03

BSSID PWR Beacons #Data, #/s CH MB ENC CIPHER AUTH ESSID

BSSID STATION PWR Rate Lost Frames Notes Probes

system lockup on interface deletion/addition

branch v5.8.7
kernel 5.14.0
ubuntu 20.04


T:  Bus=03 Lev=01 Prnt=01 Port=01 Cnt=01 Dev#=  6 Spd=480 MxCh= 0
D:  Ver= 2.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=0bda ProdID=b812 Rev=02.10
S:  Manufacturer=Realtek
S:  Product=USB3.0 802.11ac 1200M Adapter
S:  SerialNumber=123456
C:  #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=500mA
I:  If#=0x0 Alt= 0 #EPs= 5 Cls=ff(vend.) Sub=ff Prot=ff Driver=rtl88x2bu

Attempt to
iw dev wlan1 del
iw phy phy1 interface add type monitor
lead to command hang and then many other processes also hang so reboot is required
for example :
iw phy (hang)
rmmod 88x2bu (hang)
ping 1.1.1.1 (hang)

Is the TP Link Archer T4U V3 supports AP mode???

I'm having doubt since I bought this device and was testing Evil Twin attack but DHCP service was not getting started. I searched and somewhere written its a driver issue and somewhere that adapter might not support AP mode.

I'm giving output of iw list command. please check and let me know if it support AP mode.?

PS: Phy1 is TP link archer V3 and Phy0 is my laptop internal wireless card.

└─# iw list
Wiphy phy2
wiphy index: 2
max # scan SSIDs: 9
max scan IEs length: 2304 bytes
max # sched scan SSIDs: 0
max # match sets: 0
Retry short limit: 7
Retry long limit: 4
Coverage class: 0 (up to 0m)
Supported Ciphers:
* WEP40 (00-0f-ac:1)
* WEP104 (00-0f-ac:5)
* TKIP (00-0f-ac:2)
* CCMP-128 (00-0f-ac:4)
* CMAC (00-0f-ac:6)
Available Antennas: TX 0 RX 0
Supported interface modes:
* IBSS
* managed
* AP
* monitor
* P2P-client
* P2P-GO
Band 1:
Capabilities: 0x1963
RX LDPC
HT20/HT40
Static SM Power Save
RX HT20 SGI
RX HT40 SGI
RX STBC 1-stream
Max AMSDU length: 7935 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 16 usec (0x07)
HT Max RX data rate: 300 Mbps
HT TX/RX MCS rate indexes supported: 0-15
Bitrates (non-HT):
* 1.0 Mbps
* 2.0 Mbps
* 5.5 Mbps
* 11.0 Mbps
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 2412 MHz [1] (30.0 dBm)
* 2417 MHz [2] (30.0 dBm)
* 2422 MHz [3] (30.0 dBm)
* 2427 MHz [4] (30.0 dBm)
* 2432 MHz [5] (30.0 dBm)
* 2437 MHz [6] (30.0 dBm)
* 2442 MHz [7] (30.0 dBm)
* 2447 MHz [8] (30.0 dBm)
* 2452 MHz [9] (30.0 dBm)
* 2457 MHz [10] (30.0 dBm)
* 2462 MHz [11] (30.0 dBm)
* 2467 MHz [12] (disabled)
* 2472 MHz [13] (disabled)
* 2484 MHz [14] (disabled)
Band 2:
Capabilities: 0x1863
RX LDPC
HT20/HT40
Static SM Power Save
RX HT20 SGI
RX HT40 SGI
No RX STBC
Max AMSDU length: 7935 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 16 usec (0x07)
HT Max RX data rate: 300 Mbps
HT TX/RX MCS rate indexes supported: 0-15
VHT Capabilities (0x03d071b2):
Max MPDU length: 11454
Supported Channel Width: neither 160 nor 80+80
RX LDPC
short GI (80 MHz)
TX STBC
SU Beamformee
MU Beamformee
+HTC-VHT
VHT RX MCS set:
1 streams: MCS 0-9
2 streams: MCS 0-9
3 streams: not supported
4 streams: not supported
5 streams: not supported
6 streams: not supported
7 streams: not supported
8 streams: not supported
VHT RX highest supported: 867 Mbps
VHT TX MCS set:
1 streams: MCS 0-9
2 streams: MCS 0-9
3 streams: not supported
4 streams: not supported
5 streams: not supported
6 streams: not supported
7 streams: not supported
8 streams: not supported
VHT TX highest supported: 867 Mbps
Bitrates (non-HT):
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 5180 MHz [36] (23.0 dBm)
* 5200 MHz [40] (23.0 dBm)
* 5220 MHz [44] (23.0 dBm)
* 5240 MHz [48] (23.0 dBm)
* 5260 MHz [52] (23.0 dBm) (radar detection)
* 5280 MHz [56] (23.0 dBm) (radar detection)
* 5300 MHz [60] (23.0 dBm) (radar detection)
* 5320 MHz [64] (23.0 dBm) (radar detection)
* 5500 MHz [100] (23.0 dBm) (radar detection)
* 5520 MHz [104] (23.0 dBm) (radar detection)
* 5540 MHz [108] (23.0 dBm) (radar detection)
* 5560 MHz [112] (23.0 dBm) (radar detection)
* 5580 MHz [116] (23.0 dBm) (radar detection)
* 5600 MHz [120] (disabled)
* 5620 MHz [124] (disabled)
* 5640 MHz [128] (disabled)
* 5660 MHz [132] (23.0 dBm) (radar detection)
* 5680 MHz [136] (23.0 dBm) (radar detection)
* 5700 MHz [140] (23.0 dBm) (radar detection)
* 5720 MHz [144] (disabled)
* 5745 MHz [149] (30.0 dBm)
* 5765 MHz [153] (30.0 dBm)
* 5785 MHz [157] (30.0 dBm)
* 5805 MHz [161] (30.0 dBm)
* 5825 MHz [165] (30.0 dBm)
* 5845 MHz [169] (disabled)
* 5865 MHz [173] (disabled)
* 5885 MHz [177] (disabled)
Supported commands:
* new_interface
* set_interface
* new_key
* start_ap
* new_station
* set_bss
* join_ibss
* set_pmksa
* del_pmksa
* flush_pmksa
* remain_on_channel
* frame
* set_wiphy_netns
* set_channel
* connect
* disconnect
WoWLAN support:
* wake up on anything (device continues operating normally)
software interface modes (can always be added):
* monitor
interface combinations are not supported
Device supports SAE with AUTHENTICATE command
Device supports scan flush.
max # scan plans: 1
max scan plan interval: -1
max scan plan iterations: 0
Supported TX frame types:
* IBSS: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* AP/VLAN: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
Supported RX frame types:
* IBSS: 0xd0
* managed: 0x40 0xb0 0xd0
* AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* AP/VLAN: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* P2P-client: 0x40 0xd0
* P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
Supported extended features:
Wiphy phy0
wiphy index: 0
max # scan SSIDs: 4
max scan IEs length: 2243 bytes
max # sched scan SSIDs: 0
max # match sets: 0
Retry short limit: 7
Retry long limit: 4
Coverage class: 0 (up to 0m)
Device supports T-DLS.
Supported Ciphers:
* WEP40 (00-0f-ac:1)
* WEP104 (00-0f-ac:5)
* TKIP (00-0f-ac:2)
* CCMP-128 (00-0f-ac:4)
* CCMP-256 (00-0f-ac:10)
* GCMP-128 (00-0f-ac:8)
* GCMP-256 (00-0f-ac:9)
* CMAC (00-0f-ac:6)
* CMAC-256 (00-0f-ac:13)
* GMAC-128 (00-0f-ac:11)
* GMAC-256 (00-0f-ac:12)
Available Antennas: TX 0x3 RX 0x3
Configured Antennas: TX 0x3 RX 0x3
Supported interface modes:
* IBSS
* managed
* AP
* AP/VLAN
* monitor
* mesh point
Band 1:
Capabilities: 0x196f
RX LDPC
HT20/HT40
SM Power Save disabled
RX HT20 SGI
RX HT40 SGI
RX STBC 1-stream
Max AMSDU length: 7935 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 16 usec (0x07)
HT Max RX data rate: 300 Mbps
HT TX/RX MCS rate indexes supported: 0-15, 32
Bitrates (non-HT):
* 1.0 Mbps
* 2.0 Mbps
* 5.5 Mbps
* 11.0 Mbps
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 2412 MHz [1] (30.0 dBm)
* 2417 MHz [2] (30.0 dBm)
* 2422 MHz [3] (30.0 dBm)
* 2427 MHz [4] (30.0 dBm)
* 2432 MHz [5] (30.0 dBm)
* 2437 MHz [6] (30.0 dBm)
* 2442 MHz [7] (30.0 dBm)
* 2447 MHz [8] (30.0 dBm)
* 2452 MHz [9] (30.0 dBm)
* 2457 MHz [10] (30.0 dBm)
* 2462 MHz [11] (30.0 dBm)
* 2467 MHz [12] (30.0 dBm)
* 2472 MHz [13] (30.0 dBm)
* 2484 MHz [14] (disabled)
Band 2:
Capabilities: 0x196f
RX LDPC
HT20/HT40
SM Power Save disabled
RX HT20 SGI
RX HT40 SGI
RX STBC 1-stream
Max AMSDU length: 7935 bytes
DSSS/CCK HT40
Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
Minimum RX AMPDU time spacing: 16 usec (0x07)
HT Max RX data rate: 300 Mbps
HT TX/RX MCS rate indexes supported: 0-15, 32
VHT Capabilities (0x03d071b2):
Max MPDU length: 11454
Supported Channel Width: neither 160 nor 80+80
RX LDPC
short GI (80 MHz)
TX STBC
SU Beamformee
MU Beamformee
+HTC-VHT
VHT RX MCS set:
1 streams: MCS 0-9
2 streams: MCS 0-9
3 streams: not supported
4 streams: not supported
5 streams: not supported
6 streams: not supported
7 streams: not supported
8 streams: not supported
VHT RX highest supported: 780 Mbps
VHT TX MCS set:
1 streams: MCS 0-9
2 streams: MCS 0-9
3 streams: not supported
4 streams: not supported
5 streams: not supported
6 streams: not supported
7 streams: not supported
8 streams: not supported
VHT TX highest supported: 780 Mbps
Bitrates (non-HT):
* 6.0 Mbps
* 9.0 Mbps
* 12.0 Mbps
* 18.0 Mbps
* 24.0 Mbps
* 36.0 Mbps
* 48.0 Mbps
* 54.0 Mbps
Frequencies:
* 5180 MHz [36] (23.0 dBm)
* 5200 MHz [40] (23.0 dBm)
* 5220 MHz [44] (23.0 dBm)
* 5240 MHz [48] (23.0 dBm)
* 5260 MHz [52] (23.0 dBm) (radar detection)
* 5280 MHz [56] (23.0 dBm) (radar detection)
* 5300 MHz [60] (23.0 dBm) (radar detection)
* 5320 MHz [64] (23.0 dBm) (radar detection)
* 5500 MHz [100] (23.0 dBm) (radar detection)
* 5520 MHz [104] (23.0 dBm) (radar detection)
* 5540 MHz [108] (23.0 dBm) (radar detection)
* 5560 MHz [112] (23.0 dBm) (radar detection)
* 5580 MHz [116] (23.0 dBm) (radar detection)
* 5600 MHz [120] (23.0 dBm) (radar detection)
* 5620 MHz [124] (23.0 dBm) (radar detection)
* 5640 MHz [128] (23.0 dBm) (radar detection)
* 5660 MHz [132] (23.0 dBm) (radar detection)
* 5680 MHz [136] (23.0 dBm) (radar detection)
* 5700 MHz [140] (23.0 dBm) (radar detection)
* 5745 MHz [149] (30.0 dBm)
* 5765 MHz [153] (30.0 dBm)
* 5785 MHz [157] (30.0 dBm)
* 5805 MHz [161] (30.0 dBm)
* 5825 MHz [165] (30.0 dBm)
Supported commands:
* new_interface
* set_interface
* new_key
* start_ap
* new_station
* new_mpath
* set_mesh_config
* set_bss
* authenticate
* associate
* deauthenticate
* disassociate
* join_ibss
* join_mesh
* remain_on_channel
* set_tx_bitrate_mask
* frame
* frame_wait_cancel
* set_wiphy_netns
* set_channel
* set_wds_peer
* tdls_mgmt
* tdls_oper
* probe_client
* set_noack_map
* register_beacons
* start_p2p_device
* set_mcast_rate
* connect
* disconnect
* set_qos_map
* set_multicast_to_unicast
software interface modes (can always be added):
* AP/VLAN
* monitor
interface combinations are not supported
HT Capability overrides:
* MCS: ff ff ff ff ff ff ff ff ff ff
* maximum A-MSDU length
* supported channel width
* short GI for 40 MHz
* max A-MPDU length exponent
* min MPDU start spacing
Device supports TX status socket option.
Device supports HT-IBSS.
Device supports SAE with AUTHENTICATE command
Device supports low priority scan.
Device supports scan flush.
Device supports AP scan.
Device supports per-vif TX power setting
Driver supports full state transitions for AP/GO clients
Driver supports a userspace MPM
Device supports configuring vdev MAC-addr on create.
Device supports randomizing MAC-addr in scans.
max # scan plans: 1
max scan plan interval: -1
max scan plan iterations: 0
Supported TX frame types:
* IBSS: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* AP/VLAN: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* mesh point: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
* P2P-device: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
Supported RX frame types:
* IBSS: 0x40 0xb0 0xc0 0xd0
* managed: 0x40 0xb0 0xd0
* AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* AP/VLAN: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* mesh point: 0xb0 0xc0 0xd0
* P2P-client: 0x40 0xd0
* P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
* P2P-device: 0x40 0xd0
Supported extended features:
* [ RRM ]: RRM
* [ FILS_STA ]: STA FILS (Fast Initial Link Setup)
* [ CONTROL_PORT_OVER_NL80211 ]: control port over nl80211
* [ TXQS ]: FQ-CoDel-enabled intermediate TXQs
* [ SCAN_RANDOM_SN ]: use random sequence numbers in scans
* [ SCAN_MIN_PREQ_CONTENT ]: use probe request with only rate IEs in scans
* [ CAN_REPLACE_PTK0 ]: can safely replace PTK 0 when rekeying
* [ CONTROL_PORT_NO_PREAUTH ]: disable pre-auth over nl80211 control port support
* [ DEL_IBSS_STA ]: deletion of IBSS station support
* [ SCAN_FREQ_KHZ ]: scan on kHz frequency support
* [ CONTROL_PORT_OVER_NL80211_TX_STATUS ]: tx status for nl80211 control port support

After Driver installation: Monitor Mode Error -95

Device: T3U AC1300 mini V1 RTL8812BU
I am using Kernel 5.16 and after successfully installing your driver, i was not able to start monitor mode. When i use airmon-ng i can start it but it will show managed mode with iwconfig! When i start monitor mode via sudo, it shows an error -95 (not supported)...
That should be a driver issue?

Trouble compiling on fedora 34 (linux kernel 5.11)

I'm getting several issues here. The most obvious is

  |                                 ^~~~~~

/usr/src/rtl88x2bu-5.6.1/os_dep/osdep_service.c:2247:32: error: ‘KERNEL_DS’ undeclared (first use in this function); did you mean ‘KERNFS_NS’?
2247 | set_fs(KERNEL_DS);
| ^~~~~~~~~
| KERNFS_NS
/usr/src/rtl88x2bu-5.6.1/os_dep/osdep_service.c: In function ‘storeToFile’:
/usr/src/rtl88x2bu-5.6.1/os_dep/osdep_service.c:2284:33: error: incompatible types when assigning to type ‘mm_segment_t’ from type ‘int’
2284 | oldfs = get_fs();
| ^~~~~~
/usr/src/rtl88x2bu-5.6.1/core/efuse/rtw_efuse.c: In function ‘rtw_efuse_analyze’:

I,m happy to mod the code if I know what you want here. Clearly the kernel interface has chaned.

Please add a LICENSE

Could you please add an open source friendly license like MIT or GPL to this repo? Thanks

Error while running the make command on Arch Linux Kernel version 5.18.10

when i try to run the make command i get this back

Xavier% make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.18.10-arch1-1/build M=/home/xavier/RTL8812BU modules
make[1]: Entering directory '/usr/lib/modules/5.18.10-arch1-1/build'
CC [M] /home/xavier/RTL8812BU/os_dep/osdep_service.o
/home/xavier/RTL8812BU/os_dep/osdep_service.c: In function ‘thread_exit’:
/home/xavier/RTL8812BU/os_dep/osdep_service.c:1302:9: error: implicit declaration of function ‘complete_and_exit’ [-Werror=implicit-function-declaration]
1302 | complete_and_exit(comp, 0);
| ^~~~~~~~~~~~~~~~~
/home/xavier/RTL8812BU/os_dep/osdep_service.c: In function ‘isFileReadable’:
/home/xavier/RTL8812BU/os_dep/osdep_service.c:2224:9: error: unknown type name ‘mm_segment_t’
2224 | mm_segment_t oldfs;
| ^~~~~~~~~~~~
/home/xavier/RTL8812BU/os_dep/osdep_service.c: In function ‘retriveFromFile’:
/home/xavier/RTL8812BU/os_dep/osdep_service.c:2269:9: error: unknown type name ‘mm_segment_t’
2269 | mm_segment_t oldfs;
| ^~~~~~~~~~~~
/home/xavier/RTL8812BU/os_dep/osdep_service.c: In function ‘storeToFile’:
/home/xavier/RTL8812BU/os_dep/osdep_service.c:2312:9: error: unknown type name ‘mm_segment_t’
2312 | mm_segment_t oldfs;
| ^~~~~~~~~~~~
/home/xavier/RTL8812BU/os_dep/osdep_service.c: In function ‘rtw_change_ifname’:
/home/xavier/RTL8812BU/os_dep/osdep_service.c:2564:28: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
2564 | _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
| ~~~~~~~^~~~~~~~~~
/home/xavier/RTL8812BU/os_dep/osdep_service.c:922:24: note: expected ‘void *’ but argument is of type ‘const unsigned char *’
922 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
| ~~~~~~^~~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:288: /home/xavier/RTL8812BU/os_dep/osdep_service.o] Error 1
make[1]: *** [Makefile:1838: /home/xavier/RTL8812BU] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.18.10-arch1-1/build'
make: *** [Makefile:2390: modules] Error 2

ive tried to fix this by installing the correct linux headers but that did not fix it and i did clone the v5.8.7 branch
Thanks for taking a look at this.

Compatibility & Build Report -- Raspberry Pi 4, kernel 6.1.0-rpi7-rpi-v8 aarch64

This is a report on a successful build for Raspberry Pi 4 / Raspberry Pi OS . I attempted a build of the other "raspbian" repo that would not build.

The RTL8812BU device is being used for network security scanning.

Build info

Hardware = Raspberry Pi 4,
OS = Raspberry PI OS Lite 64bit
kernel = kernel 6.1.0-rpi7-rpi-v8 aarch64
debian_version = 12.4
branch = v5.13.1

Build Steps

$ git checkout v5.13.1
# apply patch to wifi_regd.c (see bove)
$ make
$ make install 
# follow remaining instructions in readme

Commit info

 git log --graph -5
* cfad3d6 - (HEAD -> raspberry-pi-linux-6.1) builds on raspberry pi linux 6.1 .  driver loads (2 hours ago) <Anthony Metzidis>
* 36deb90 - (origin/v5.13.1, v5.13.1) Update rtl8812bu.yml (11 months ago) <Fastoe>
* fae227a - Realtek RTL8812BU Driver(5.13.1) for Linux (11 months ago) <fastoe>
* 5a77dc7 - (origin/v5.8.7) Realtek RTL8812BU Driver for Linux (11 months ago) <fastoe>
* f5972a7 - CI (11 months ago) <fastoe>
* 

Diff

diff --git a/os_dep/linux/wifi_regd.c b/os_dep/linux/wifi_regd.c
index 81e1dc7..c4dc645 100644
--- a/os_dep/linux/wifi_regd.c
+++ b/os_dep/linux/wifi_regd.c
@@ -405,7 +405,7 @@ int rtw_regd_init(struct wiphy *wiphy)
        wiphy->regulatory_flags &= ~REGULATORY_DISABLE_BEACON_HINTS;
 #endif

-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0))
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 19, 0) && (LINUX_VERSION_CODE < KERNEL_VERSION(6, 1, 0)))
        wiphy->regulatory_flags |= REGULATORY_IGNORE_STALE_KICKOFF;
 #endif

Testing

sudo iw dev INTERFACE  scan > scan-2023-12-14.txt

build wrong on arch

/include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_mlme_ext.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_wlan_util.c:17:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_wlan_util.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_ap.c:17:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_ap.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_xmit.c:17:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_xmit.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_security.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_rf.c:17:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_rf.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_ioctl_query.o] Error 1
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_p2p.c:17:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_p2p.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_sta_mgt.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_chplan.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_ieee80211.o] Error 1
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_tdls.c:17:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_tdls.c:17:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_br_ext.c:27:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/net/inet_sock.h:22,
                 from ./include/net/ip.h:28,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_br_ext.c:19:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_iol.c:16:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_iol.c:16:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:79,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_rson.c:22:
/usr/src/rtl88x2bu-5.6.1/include/rtw_security.h:252:8: error: redefinition of ‘struct sha256_state’
  252 | struct sha256_state {
      |        ^~~~~~~~~~~~
In file included from ./include/linux/filter.h:24,
                 from ./include/net/sock.h:59,
                 from ./include/linux/tcp.h:19,
                 from ./include/linux/ipv6.h:88,
                 from ./include/net/addrconf.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service_linux.h:48,
                 from /usr/src/rtl88x2bu-5.6.1/include/osdep_service.h:50,
                 from /usr/src/rtl88x2bu-5.6.1/include/drv_types.h:27,
                 from /usr/src/rtl88x2bu-5.6.1/core/rtw_rson.c:22:
./include/crypto/sha.h:84:8: note: originally defined here
   84 | struct sha256_state {
      |        ^~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_p2p.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_iol.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_ioctl_set.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_br_ext.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_rson.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_pwrctrl.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_vht.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_mi.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_io.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_mlme.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_wlan_util.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_cmd.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_rf.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_recv.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_tdls.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_xmit.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_debug.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_ap.o] Error 1
make[2]: *** [scripts/Makefile.build:283: /var/lib/dkms/rtl88x2bu/5.6.1/build/core/rtw_mlme_ext.o] Error 1
make[1]: *** [Makefile:1784: /var/lib/dkms/rtl88x2bu/5.6.1/build] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.9.1-arch1-1/build'
make: *** [Makefile:2284: modules] Error2

WiFi not connecting

After installation I can see the wifi networks but I can't connect. The field to enter the network password appears several times but it does not connect. What should I do?

Errors when using make

Hi ! I am trying to install the driver, but I have some errors when using make command. Can somebody help me ?

root@user-MS-7B79:/home/user/Downloads/RTL8812BU# sudo apt install -y build-essential dkms git bc
Reading package lists... Done
Building dependency tree       
Reading state information... Done
bc is already the newest version (1.07.1-2build1).
build-essential is already the newest version (12.8ubuntu1.1).
dkms is already the newest version (2.8.1-5ubuntu2).
git is already the newest version (1:2.25.1-1ubuntu3.11).
The following packages were automatically installed and are no longer required:
  adwaita-qt coinor-libcbc3 coinor-libcgl1 coinor-libclp1 coinor-libcoinmp1v5
  coinor-libcoinutils3v5 coinor-libosi1v5 libdouble-conversion3 libfuse3-3
  libpcre2-16-0 libqt5core5a libqt5dbus5 libqt5gui5 libqt5network5 libqt5svg5
  libqt5widgets5 libxmlsec1 libxmlsec1-nss qt5-gtk-platformtheme
  qttranslations5-l10n
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
root@user-MS-7B79:/home/user/Downloads/RTL8812BU# make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.15.0-76-generic/build M=/home/user/Downloads/RTL8812BU  modules
make[1]: Entering directory '/usr/src/linux-headers-5.15.0-76-generic'
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_cmd.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_cmd.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_security.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_security.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_debug.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_debug.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_io.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_io.c:47:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_ioctl_query.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_ioctl_query.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_ioctl_set.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_ioctl_set.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_ieee80211.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_ieee80211.c:20:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_mlme.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/include/../hal/phydm/phydm_types.h:215,
                 from /home/user/Downloads/RTL8812BU/include/../hal/phydm/phydm_precomp.h:29,
                 from /home/user/Downloads/RTL8812BU/include/hal_data.h:20,
                 from /home/user/Downloads/RTL8812BU/core/rtw_mlme.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_mlme_ext.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_mlme_ext.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
/home/user/Downloads/RTL8812BU/core/rtw_mlme_ext.c: In function ‘mgt_dispatcher’:
/home/user/Downloads/RTL8812BU/core/rtw_mlme_ext.c:1335:17: warning: this statement may fall through [-Wimplicit-fallthrough=]
 1335 |    ptable->func = &OnAuthClient;
      |    ~~~~~~~~~~~~~^~~~~~~~~~~~~~~
/home/user/Downloads/RTL8812BU/core/rtw_mlme_ext.c:1337:2: note: here
 1337 |  case WIFI_ASSOCREQ:
      |  ^~~~
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_mi.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_mi.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_wlan_util.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_wlan_util.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_vht.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_vht.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_pwrctrl.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_pwrctrl.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_rf.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_rf.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_chplan.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_chplan.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_recv.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_recv.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_sta_mgt.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_sta_mgt.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_ap.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_ap.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/mesh/rtw_mesh.o
  CC [M]  /home/user/Downloads/RTL8812BU/core/mesh/rtw_mesh_pathtbl.o
  CC [M]  /home/user/Downloads/RTL8812BU/core/mesh/rtw_mesh_hwmp.o
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_xmit.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_xmit.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_p2p.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_p2p.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_rson.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_rson.c:22:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_tdls.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_tdls.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_br_ext.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_br_ext.c:30:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_iol.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_iol.c:16:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_sreset.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_sreset.c:16:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_btcoex_wifionly.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_btcoex_wifionly.c:15:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_btcoex.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_btcoex.c:15:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_beamforming.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_beamforming.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_odm.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/include/rtw_odm.h:18,
                 from /home/user/Downloads/RTL8812BU/core/rtw_odm.c:16:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_rm.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_rm.c:16:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/rtw_rm_fsm.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/rtw_rm_fsm.c:16:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/core/efuse/rtw_efuse.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/core/efuse/rtw_efuse.c:17:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
  CC [M]  /home/user/Downloads/RTL8812BU/os_dep/osdep_service.o
In file included from /home/user/Downloads/RTL8812BU/include/drv_conf.h:17,
                 from /home/user/Downloads/RTL8812BU/include/drv_types.h:25,
                 from /home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:19:
/home/user/Downloads/RTL8812BU/include/autoconf.h:183: warning: "CONFIG_RTW_SW_LED" redefined
  183 |  #define CONFIG_RTW_SW_LED
      | 
<command-line>: note: this is the location of the previous definition
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c: In function ‘isFileReadable’:
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2203:11: error: implicit declaration of function ‘get_fs’; did you mean ‘get_sa’? [-Werror=implicit-function-declaration]
 2203 |   oldfs = get_fs();
      |           ^~~~~~
      |           get_sa
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2203:11: error: incompatible types when assigning to type ‘mm_segment_t’ {aka ‘struct <anonymous>’} from type ‘int’
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2205:3: error: implicit declaration of function ‘set_fs’; did you mean ‘sget_fc’? [-Werror=implicit-function-declaration]
 2205 |   set_fs(KERNEL_DS);
      |   ^~~~~~
      |   sget_fc
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2205:10: error: ‘KERNEL_DS’ undeclared (first use in this function); did you mean ‘KERNFS_NS’?
 2205 |   set_fs(KERNEL_DS);
      |          ^~~~~~~~~
      |          KERNFS_NS
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2205:10: note: each undeclared identifier is reported only once for each function it appears in
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c: In function ‘retriveFromFile’:
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2245:12: error: incompatible types when assigning to type ‘mm_segment_t’ {aka ‘struct <anonymous>’} from type ‘int’
 2245 |    oldfs = get_fs();
      |            ^~~~~~
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2247:11: error: ‘KERNEL_DS’ undeclared (first use in this function); did you mean ‘KERNFS_NS’?
 2247 |    set_fs(KERNEL_DS);
      |           ^~~~~~~~~
      |           KERNFS_NS
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c: In function ‘storeToFile’:
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2284:12: error: incompatible types when assigning to type ‘mm_segment_t’ {aka ‘struct <anonymous>’} from type ‘int’
 2284 |    oldfs = get_fs();
      |            ^~~~~~
/home/user/Downloads/RTL8812BU/os_dep/osdep_service.c:2286:11: error: ‘KERNEL_DS’ undeclared (first use in this function); did you mean ‘KERNFS_NS’?
 2286 |    set_fs(KERNEL_DS);
      |           ^~~~~~~~~
      |           KERNFS_NS
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:297: /home/user/Downloads/RTL8812BU/os_dep/osdep_service.o] Error 1
make[1]: *** [Makefile:1914: /home/user/Downloads/RTL8812BU] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-76-generic'
make: *** [Makefile:2288: modules] Error 2
root@user-MS-7B79:/home/user/Downloads/RTL8812BU# sudo make install
install -p -m 644 88x2bu.ko  /lib/modules/5.15.0-76-generic/kernel/drivers/net/wireless/
install: cannot stat '88x2bu.ko': No such file or directory
make: *** [Makefile:2294: install] Error 1
root@user-MS-7B79:/home/user/Downloads/RTL8812BU# 

Add signed module.

Please sign the module so it can work with Secure Boot enabled. Disabling Secure Boot is not an option when you are dual booting with Windows 11.

usb 1-4: new high-speed USB device number 12 using xhci_hcd
usb 1-4: New USB device found, idVendor=0bda, idProduct=b812, bcdDevice= 2.10
usb 1-4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-4: Product: USB3.0 802.11ac 1200M Adapter
usb 1-4: Manufacturer: Realtek
usb 1-4: SerialNumber: 123456
Lockdown: systemd-udevd: unsigned module loading is restricted; see man kernel_lockdown.7
Lockdown: systemd-logind: hibernation is restricted; see man kernel_lockdown.7

"prandom_u32_max" build failure under Linux 6.1.0

/home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU/os_dep/osdep_service.c: In function ‘rtw_change_ifname’:
/home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU/os_dep/osdep_service.c:2574:28: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
 2574 |         _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN);
      |                     ~~~~~~~^~~~~~~~~~
/home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU/os_dep/osdep_service.c:922:24: note: expected ‘void *’ but argument is of type ‘const unsigned char *’
  922 | void _rtw_memcpy(void *dst, const void *src, u32 sz)
      |                  ~~~~~~^~~
/home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU/os_dep/osdep_service.c: In function ‘rtw_random32’:
/home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU/os_dep/osdep_service.c:2698:16: error: implicit declaration of function ‘prandom_u32’; did you mean ‘prandom_u32_max’? [-Werror=implicit-function-declaration]
 2698 |         return prandom_u32();
      |                ^~~~~~~~~~~
      |                prandom_u32_max
cc1: some warnings being treated as errors
make[2]: *** [/usr/src/linux-headers-6.1.0-0-common/scripts/Makefile.build:255: /home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU/os_dep/osdep_service.o] Error 1
make[1]: *** [/usr/src/linux-headers-6.1.0-0-common/Makefile:2017: /home/lamby/temp/cdt.20221221115757.cmvTwmdtNA/RTL8812BU] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-6.1.0-0-amd64'
make: *** [Makefile:2390: modules] Error 2

not working

this method is not working for me. i have kernel version 5.18.0-kali7-amd64. I have tried each and everything but my adapter is not connecting at all. Please advise what can i do. I am stuck in the same spot for one week.

Driver folder

I installed your driver, it is working (thank you), however I have now folder named
RTL8812BU inside my HOME folder in Linux. It's a little distracting for me, as
I often see it.

Could I delete this folder and driver would still work?
Is it possible to hide this folder?

make failed

OS: Arch Linux x86_64
Kernel: 6.8.9-arch1-2
Shell: bash 5.2.26

i cloned the v5.13.1 branch
this is the error when running make

[speckles@speckly RTL8812BU]$ make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/6.8.9-arch1-2/build M=/home/speckles/Downloads/RTL8812BU  modules
make[1]: Entering directory '/usr/lib/modules/6.8.9-arch1-2/build'
  CC [M]  /home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.o
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:1087:6: warning: no previous prototype for ‘rtw_regsty_load_target_tx_power’ [-Wmissing-prototypes]
 1087 | void rtw_regsty_load_target_tx_power(struct registry_priv *regsty)
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:1703:14: warning: no previous prototype for ‘rtw_classify8021d’ [-Wmissing-prototypes]
 1703 | unsigned int rtw_classify8021d(struct sk_buff *skb)
      |              ^~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:1839:5: warning: no previous prototype for ‘rtw_ndev_init’ [-Wmissing-prototypes]
 1839 | int rtw_ndev_init(struct net_device *dev)
      |     ^~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:1852:6: warning: no previous prototype for ‘rtw_ndev_uninit’ [-Wmissing-prototypes]
 1852 | void rtw_ndev_uninit(struct net_device *dev)
      |      ^~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:1912:6: warning: no previous prototype for ‘rtw_hook_if_ops’ [-Wmissing-prototypes]
 1912 | void rtw_hook_if_ops(struct net_device *ndev)
      |      ^~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:1994:5: warning: no previous prototype for ‘rtw_os_ndev_alloc’ [-Wmissing-prototypes]
 1994 | int rtw_os_ndev_alloc(_adapter *adapter)
      |     ^~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c: In function ‘rtw_ethtool_get_drvinfo’:
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:2050:17: error: implicit declaration of function ‘strlcpy’; did you mean ‘strscpy’? [-Wimplicit-function-declaration]
 2050 |                 strlcpy(info->driver, wiphy_dev(wdev->wiphy)->driver->name,
      |                 ^~~~~~~
      |                 strscpy
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c: At top level:
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:2149:5: warning: no previous prototype for ‘rtw_os_ndev_register’ [-Wmissing-prototypes]
 2149 | int rtw_os_ndev_register(_adapter *adapter, const char *name)
      |     ^~~~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:2300:5: warning: no previous prototype for ‘rtw_os_ndevs_alloc’ [-Wmissing-prototypes]
 2300 | int rtw_os_ndevs_alloc(struct dvobj_priv *dvobj)
      |     ^~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:2352:6: warning: no previous prototype for ‘rtw_os_ndevs_free’ [-Wmissing-prototypes]
 2352 | void rtw_os_ndevs_free(struct dvobj_priv *dvobj)
      |      ^~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:2484:4: warning: no previous prototype for ‘rtw_init_default_value’ [-Wmissing-prototypes]
 2484 | u8 rtw_init_default_value(_adapter *padapter)
      |    ^~~~~~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:3721:5: warning: no previous prototype for ‘rtw_os_ndevs_register’ [-Wmissing-prototypes]
 3721 | int rtw_os_ndevs_register(struct dvobj_priv *dvobj)
      |     ^~~~~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:3838:6: warning: no previous prototype for ‘netdev_br_init’ [-Wmissing-prototypes]
 3838 | void netdev_br_init(struct net_device *netdev)
      |      ^~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:4155:6: warning: no previous prototype for ‘ips_netdrv_open’ [-Wmissing-prototypes]
 4155 | int  ips_netdrv_open(_adapter *padapter)
      |      ^~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:4348:5: warning: no previous prototype for ‘pm_netdev_open’ [-Wmissing-prototypes]
 4348 | int pm_netdev_open(struct net_device *pnetdev, u8 bnormal)
      |     ^~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:4476:5: warning: no previous prototype for ‘pm_netdev_close’ [-Wmissing-prototypes]
 4476 | int pm_netdev_close(struct net_device *pnetdev, u8 bnormal)
      |     ^~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:5174:5: warning: no previous prototype for ‘rtw_suspend_normal’ [-Wmissing-prototypes]
 5174 | int rtw_suspend_normal(_adapter *padapter)
      |     ^~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:5587:6: warning: no previous prototype for ‘rtw_mi_resume_process_normal’ [-Wmissing-prototypes]
 5587 | void rtw_mi_resume_process_normal(_adapter *padapter)
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.c:5620:5: warning: no previous prototype for ‘rtw_resume_process_normal’ [-Wmissing-prototypes]
 5620 | int rtw_resume_process_normal(_adapter *padapter)
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~
make[3]: *** [scripts/Makefile.build:243: /home/speckles/Downloads/RTL8812BU/os_dep/linux/os_intfs.o] Error 1
make[2]: *** [/usr/lib/modules/6.8.9-arch1-2/build/Makefile:1921: /home/speckles/Downloads/RTL8812BU] Error 2
make[1]: *** [Makefile:240: __sub-make] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.8.9-arch1-2/build'
make: *** [Makefile:2506: modules] Error 2
[speckles@speckly RTL8812BU]$

Debian 6.3.7-1 (2023-06-12) x86_64 GNU/Linux - make encounter an error

Linux 6.3.0-1-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.3.7-1 (2023-06-12) x86_64 GNU/Linux

make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/6.3.0-1-amd64/build M=/root/RTL8812BU modules
make[1]: Entering directory '/usr/src/linux-headers-6.3.0-1-amd64'
CC [M] /root/RTL8812BU/os_dep/linux/ioctl_cfg80211.o
/root/RTL8812BU/os_dep/linux/ioctl_cfg80211.c: In function ‘rtw_cfg80211_ch_switch_notify’:
/root/RTL8812BU/os_dep/linux/ioctl_cfg80211.c:468:17: error: too few arguments to function ‘cfg80211_ch_switch_started_notify’
468 | cfg80211_ch_switch_started_notify(adapter->pnetdev, &chdef, 0, 0, false);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /root/RTL8812BU/include/osdep_service_linux.h:98,
from /root/RTL8812BU/include/osdep_service.h:54,
from /root/RTL8812BU/include/drv_types.h:27,
from /root/RTL8812BU/os_dep/linux/ioctl_cfg80211.c:17:
/usr/src/linux-headers-6.3.0-1-common/include/net/cfg80211.h:8392:6: note: declared here
8392 | void cfg80211_ch_switch_started_notify(struct net_device *dev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/RTL8812BU/os_dep/linux/ioctl_cfg80211.c:483:9: error: too few arguments to function ‘cfg80211_ch_switch_notify’
483 | cfg80211_ch_switch_notify(adapter->pnetdev, &chdef, 0);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/usr/src/linux-headers-6.3.0-1-common/include/net/cfg80211.h:8375:6: note: declared here
8375 | void cfg80211_ch_switch_notify(struct net_device *dev,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
make[2]: *** [/usr/src/linux-headers-6.3.0-1-common/scripts/Makefile.build:257: /root/RTL8812BU/os_dep/linux/ioctl_cfg80211.o] Error 1
make[1]: *** [/usr/src/linux-headers-6.3.0-1-common/Makefile:2050: /root/RTL8812BU] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-6.3.0-1-amd64'
make: *** [Makefile:2506: modules] Error 2

Missing Files

Running Kali 5.16 I get the error:

"install: cannot stat '88x2bu.ko': No such file or directory"

Failed DKMS Installation

Linux pop-os 5.17.5-76051705-generic #202204271406165150484022.04~63e51bd SMP PREEMPT Mon May 2 15: x86_64 x86_64 x86_64 GNU/Linux

DKMS make.log for rtl88x2bu-5.8.7.1 for kernel 5.17.5-76051705-generic (x86_64) Monday 16 May 2022 02:57:16 PM IST make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.17.5-76051705-generic/build M=/var/lib/dkms/rtl88x2bu/5.8.7.1/build modules make[1]: Entering directory '/usr/src/linux-headers-5.17.5-76051705-generic' CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_cmd.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_security.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_debug.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_io.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_ioctl_query.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_ioctl_set.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_ieee80211.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_mlme.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_mlme_ext.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_mi.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_wlan_util.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_vht.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_pwrctrl.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_rf.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_chplan.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_recv.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_sta_mgt.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_ap.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/mesh/rtw_mesh.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/mesh/rtw_mesh_pathtbl.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/mesh/rtw_mesh_hwmp.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_xmit.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_p2p.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_rson.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_tdls.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_br_ext.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_iol.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_sreset.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_btcoex_wifionly.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_btcoex.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_beamforming.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_odm.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_rm.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_rm_fsm.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/rtw_rm_util.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/core/efuse/rtw_efuse.o CC [M] /var/lib/dkms/rtl88x2bu/5.8.7.1/build/os_dep/osdep_service.o /usr/src/rtl88x2bu-5.8.7.1/os_dep/osdep_service.c: In function ‘thread_exit’: /usr/src/rtl88x2bu-5.8.7.1/os_dep/osdep_service.c:1302:9: error: implicit declaration of function ‘complete_and_exit’ [-Werror=implicit-function-declaration] 1302 | complete_and_exit(comp, 0); | ^~~~~~~~~~~~~~~~~ /usr/src/rtl88x2bu-5.8.7.1/os_dep/osdep_service.c: In function ‘rtw_change_ifname’: /usr/src/rtl88x2bu-5.8.7.1/os_dep/osdep_service.c:2564:28: warning: passing argument 1 of ‘_rtw_memcpy’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] 2564 | _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN); | ~~~~~~~^~~~~~~~~~ /usr/src/rtl88x2bu-5.8.7.1/os_dep/osdep_service.c:922:24: note: expected ‘void *’ but argument is of type ‘const unsigned char *’ 922 | void _rtw_memcpy(void *dst, const void *src, u32 sz) | ~~~~~~^~~ cc1: some warnings being treated as errors make[2]: *** [scripts/Makefile.build:288: /var/lib/dkms/rtl88x2bu/5.8.7.1/build/os_dep/osdep_service.o] Error 1 make[1]: *** [Makefile:1837: /var/lib/dkms/rtl88x2bu/5.8.7.1/build] Error 2 make[1]: Leaving directory '/usr/src/linux-headers-5.17.5-76051705-generic' make: *** [Makefile:2390: modules] Error 2

Error! Bad return status for module build on kernel: 5.9.0-kali2-amd64 (x86_64)

I get the following error trying to compile on Kali :

make -j8 KERNELRELEASE=5.9.0-kali2-amd64 KVER=5.9.0-kali2-amd64 src=/usr/src/rtl88x2bu-5.3.1....(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.9.0-kali2-amd64 (x86_64)

make.log

Config :

  • Linux kali 5.9.0-kali2-amd64 #1 SMP Debian 5.9.6-1kali1 (2020-11-11) x86_64 GNU/Linux

  • GNU Make 4.3

  • gcc version 10.2.0 (Debian 10.2.0-16)

Error! Bad return status for module build on kernel: 5.8.0-45-generic (x86_64)

I use these command to install my usb wifi device:

VER=$(sed -n 's/\PACKAGE_VERSION="\(.*\)"/\1/p' dkms.conf)
sudo rsync -rvhP ./ /usr/src/rtl88x2bu-${VER}
sudo dkms add -m rtl88x2bu -v ${VER}
sudo dkms build -m rtl88x2bu -v ${VER}
sudo dkms install -m rtl88x2bu -v ${VER}
sudo modprobe 88x2bu

got some error message:

...
DKMS: add completed.

Kernel preparation unnecessary for this kernel.  Skipping...

Building module:
cleaning build area...
make -j4 KERNELRELEASE=5.8.0-45-generic KVER=5.8.0-45-generic src=/usr/src/rtl88x2bu-5.6.1......(bad exit status: 2)
ERROR (dkms apport): binary package for rtl88x2bu: 5.6.1 not found
Error! Bad return status for module build on kernel: 5.8.0-45-generic (x86_64)
Consult /var/lib/dkms/rtl88x2bu/5.6.1/build/make.log for more information.

Kernel preparation unnecessary for this kernel.  Skipping...

Building module:
cleaning build area...
make -j4 KERNELRELEASE=5.8.0-45-generic KVER=5.8.0-45-generic src=/usr/src/rtl88x2bu-5.6.1....(bad exit status: 2)
ERROR (dkms apport): binary package for rtl88x2bu: 5.6.1 not found
Error! Bad return status for module build on kernel: 5.8.0-45-generic (x86_64)
Consult /var/lib/dkms/rtl88x2bu/5.6.1/build/make.log for more information.
modprobe: FATAL: Module 88x2bu not found in directory /lib/modules/5.8.0-45-generic

$ dkms status
rtl88x2bu, 5.6.1: added

but I can't found any wifi devices.

$ iwconfig
lo        no wireless extensions.

enp1s0    no wireless extensions.

system info:

$ cat /etc/issue
Ubuntu 20.04.2 LTS \n \l

$ uname -a
Linux baofeng-nas 5.8.0-45-generic #51~20.04.1-Ubuntu SMP Tue Feb 23 13:46:31 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

$ lspci
00:00.0 Host bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Host Bridge (rev 0b)
00:02.0 VGA compatible controller: Intel Corporation HD Graphics 500 (rev 0b)
00:0e.0 Audio device: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Audio Cluster (rev 0b)
00:0f.0 Communication controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Trusted Execution Engine (rev 0b)
00:12.0 SATA controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SATA AHCI Controller (rev 0b)
00:13.0 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #1 (rev fb)
00:13.1 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #2 (rev fb)
00:13.2 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #3 (rev fb)
00:13.3 PCI bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series PCI Express Port A #4 (rev fb)
00:15.0 USB controller: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series USB xHCI (rev 0b)
00:1f.0 ISA bridge: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series Low Pin Count Interface (rev 0b)
00:1f.1 SMBus: Intel Corporation Celeron N3350/Pentium N4200/Atom E3900 Series SMBus Controller (rev 0b)
01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 11)
03:00.0 SATA controller: ASMedia Technology Inc. ASM1062 Serial ATA Controller (rev 02)

no such file or directory

(kali㉿root)-[~]
└─$ sudo apt install -y dkms git bc
[sudo] password for kali:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
dctrl-tools git-man linux-compiler-gcc-10-x86 linux-headers-5.14.0-kali2-amd64
linux-headers-5.14.0-kali2-common linux-headers-amd64 linux-kbuild-5.14
Suggested packages:
menu git-daemon-run | git-daemon-sysvinit git-doc git-email git-gui gitk gitweb
git-cvs git-mediawiki git-svn
The following NEW packages will be installed:
bc dctrl-tools dkms linux-compiler-gcc-10-x86 linux-headers-5.14.0-kali2-amd64
linux-headers-5.14.0-kali2-common linux-headers-amd64 linux-kbuild-5.14
The following packages will be upgraded:
git git-man
2 upgraded, 8 newly installed, 0 to remove and 765 not upgraded.
Need to get 12.7 MB/21.6 MB of archives.
After this operation, 63.1 MB of additional disk space will be used.
Get:1 http://ftp.harukasan.org/kali kali-rolling/main amd64 linux-headers-5.14.0-kali2-common all 5.14.9-2kali1 [9,774 kB]
Get:2 http://ftp.harukasan.org/kali kali-rolling/main amd64 linux-kbuild-5.14 amd64 5.14.9-2kali1 [1,323 kB]
Get:3 http://ftp.harukasan.org/kali kali-rolling/main amd64 linux-headers-5.14.0-kali2-amd64 amd64 5.14.9-2kali1 [1,590 kB]
Get:4 http://ftp.harukasan.org/kali kali-rolling/main amd64 linux-headers-amd64 amd64 5.14.9-2kali1 [1,148 B]
Fetched 12.7 MB in 4min 14s (49.9 kB/s)
Selecting previously unselected package dctrl-tools.
(Reading database ... 267021 files and directories currently installed.)
Preparing to unpack .../0-dctrl-tools_2.24-3+b1_amd64.deb ...
Unpacking dctrl-tools (2.24-3+b1) ...
Selecting previously unselected package dkms.
Preparing to unpack .../1-dkms_2.8.7-2_all.deb ...
Unpacking dkms (2.8.7-2) ...
Selecting previously unselected package bc.
Preparing to unpack .../2-bc_1.07.1-3+b1_amd64.deb ...
Unpacking bc (1.07.1-3+b1) ...
Preparing to unpack .../3-git_1%3a2.33.0-1_amd64.deb ...
Unpacking git (1:2.33.0-1) over (1:2.32.0-1) ...
Preparing to unpack .../4-git-man_1%3a2.33.0-1_all.deb ...
Unpacking git-man (1:2.33.0-1) over (1:2.32.0-1) ...
Selecting previously unselected package linux-compiler-gcc-10-x86.
Preparing to unpack .../5-linux-compiler-gcc-10-x86_5.14.9-2kali1_amd64.deb ...
Unpacking linux-compiler-gcc-10-x86 (5.14.9-2kali1) ...
Selecting previously unselected package linux-headers-5.14.0-kali2-common.
Preparing to unpack .../6-linux-headers-5.14.0-kali2-common_5.14.9-2kali1_all.deb ...
Unpacking linux-headers-5.14.0-kali2-common (5.14.9-2kali1) ...
Selecting previously unselected package linux-kbuild-5.14.
Preparing to unpack .../7-linux-kbuild-5.14_5.14.9-2kali1_amd64.deb ...
Unpacking linux-kbuild-5.14 (5.14.9-2kali1) ...
Selecting previously unselected package linux-headers-5.14.0-kali2-amd64.
Preparing to unpack .../8-linux-headers-5.14.0-kali2-amd64_5.14.9-2kali1_amd64.deb ...
Unpacking linux-headers-5.14.0-kali2-amd64 (5.14.9-2kali1) ...
Selecting previously unselected package linux-headers-amd64.
Preparing to unpack .../9-linux-headers-amd64_5.14.9-2kali1_amd64.deb ...
Unpacking linux-headers-amd64 (5.14.9-2kali1) ...
Setting up linux-compiler-gcc-10-x86 (5.14.9-2kali1) ...
Setting up bc (1.07.1-3+b1) ...
Setting up linux-kbuild-5.14 (5.14.9-2kali1) ...
Setting up linux-headers-5.14.0-kali2-common (5.14.9-2kali1) ...
Setting up git-man (1:2.33.0-1) ...
Setting up dctrl-tools (2.24-3+b1) ...
Setting up dkms (2.8.7-2) ...
Setting up linux-headers-5.14.0-kali2-amd64 (5.14.9-2kali1) ...
/etc/kernel/header_postinst.d/dkms:
dkms: running auto installation service for kernel 5.14.0-kali2-amd64:.
Setting up git (1:2.33.0-1) ...
Setting up linux-headers-amd64 (5.14.9-2kali1) ...
Processing triggers for kali-menu (2021.3.3) ...
Processing triggers for man-db (2.9.4-2) ...

┌──(kali㉿root)-[~]
└─$ git clone -b v5.6.1 https://github.com/fastoe/RTL8812BU.git
Cloning into 'RTL8812BU'...
remote: Enumerating objects: 1982, done.
remote: Counting objects: 100% (506/506), done.
remote: Compressing objects: 100% (488/488), done.
remote: Total 1982 (delta 135), reused 58 (delta 15), pack-reused 1476
Receiving objects: 100% (1982/1982), 96.93 MiB | 4.84 MiB/s, done.
Resolving deltas: 100% (981/981), done.

┌──(kali㉿root)-[~]
└─$ cd RTL8812BU

┌──(kali㉿root)-[~/RTL8812BU]
└─$ make
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.10.0-kali9-amd64/build M=/home/kali/RTL8812BU modules
make[1]: *** /lib/modules/5.10.0-kali9-amd64/build: No such file or directory. Stop.
make: *** [Makefile:2284: modules] Error 2

┌──(kali㉿root)-[~/RTL8812BU]
└─$ sudo make install 2 ⨯
install -p -m 644 88x2bu.ko /lib/modules/5.10.0-kali9-amd64/kernel/drivers/net/wireless/
install: cannot stat '88x2bu.ko': No such file or directory
make: *** [Makefile:2290: install] Error 1

┌──(kali㉿root)-[~/RTL8812BU]
└─$

Error: can not make on arch linux

Hello,
Maybe i noob, but why i can't make on my arch linux
I make these:

sudo apt update
sudo apt install -y dkms git bc
git clone https://github.com/fastoe/RTL8812BU.git
cd RTL8812BU
VER=$(sed -n 's/\PACKAGE_VERSION="\(.*\)"/\1/p' dkms.conf)
sudo rsync -rvhP ./ /usr/src/rtl88x2bu-${VER}
sudo dkms add -m rtl88x2bu -v ${VER}
sudo dkms build -m rtl88x2bu -v ${VER}
sudo dkms install -m rtl88x2bu -v ${VER}
sudo modprobe 88x2bu
sudo reboot

sed -i 's/CONFIG_80211W = n/CONFIG_80211W = y/' Makefile
sed -i 's/CONFIG_WIFI_MONITOR = n/CONFIG_WIFI_MONITOR = y/' Makefile
make

And i see error:

make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.9.16-1-MANJARO/build M=/home/superustam/RTL8812BU  modules
make[1]: Entering directory '/usr/lib/modules/5.9.16-1-MANJARO/build'
make[1]: *** No rule to make target 'modules'.  Stop.
make[1]: Leaving directory '/usr/lib/modules/5.9.16-1-MANJARO/build'
make: *** [Makefile:2288: modules] Error 2

How i can solve my problem?
Setup:
OS: Manjaro linux
Adapter: Asus USB-AC54-b1 (Realtek RTL8812BU)

I REALLY what use my internet via adapter wifi 📶
Thank you!

increase TX-Power from 12 dBm

Hello! I am looking for a way to reduce the signal strength of the WiFi adapter.

Linux pi 4.19.118-Re4son-v8l+ #1 SMP PREEMPT Thu May 7 02:54:03 UTC 2020 aarch64 GNU/Linux
Interface wlan1
                ifindex 4
                wdev 0x100000001
                addr aa:31:ab:06:6d:94
                type managed
                txpower 12.00 dBm

NEED HELP(((

Hi!Can someone help me to install this driver on fedora 36? I'm new here and doing something wrong for shure(

[eugene@fedora RTL8812BU]$ make make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.18.13-200.fc36.x86_64/build M=/home/eugene/RTL8812BU modules make[1]: вход в каталог «/usr/src/kernels/5.18.13-200.fc36.x86_64» CC [M] /home/eugene/RTL8812BU/os_dep/osdep_service.o /home/eugene/RTL8812BU/os_dep/osdep_service.c: В функции «thread_exit»: /home/eugene/RTL8812BU/os_dep/osdep_service.c:1302:9: ошибка: неявная декларация функции «complete_and_exit» [-Werror=implicit-function-declaration] 1302 | complete_and_exit(comp, 0); | ^~~~~~~~~~~~~~~~~ /home/eugene/RTL8812BU/os_dep/osdep_service.c: В функции «isFileReadable»: /home/eugene/RTL8812BU/os_dep/osdep_service.c:2224:9: ошибка: неизвестное имя типа «mm_segment_t» 2224 | mm_segment_t oldfs; | ^~~~~~~~~~~~ /home/eugene/RTL8812BU/os_dep/osdep_service.c: В функции «retriveFromFile»: /home/eugene/RTL8812BU/os_dep/osdep_service.c:2269:9: ошибка: неизвестное имя типа «mm_segment_t» 2269 | mm_segment_t oldfs; | ^~~~~~~~~~~~ /home/eugene/RTL8812BU/os_dep/osdep_service.c: В функции «storeToFile»: /home/eugene/RTL8812BU/os_dep/osdep_service.c:2312:9: ошибка: неизвестное имя типа «mm_segment_t» 2312 | mm_segment_t oldfs; | ^~~~~~~~~~~~ /home/eugene/RTL8812BU/os_dep/osdep_service.c: В функции «rtw_change_ifname»: /home/eugene/RTL8812BU/os_dep/osdep_service.c:2564:28: предупреждение: передача аргумента 1 «_rtw_memcpy» отменяет квалификатор «const» указуемого типа [-Wdiscarded-qualifiers] 2564 | _rtw_memcpy(pnetdev->dev_addr, adapter_mac_addr(padapter), ETH_ALEN); | ~~~~~~~^~~~~~~~~~ /home/eugene/RTL8812BU/os_dep/osdep_service.c:922:24: замечание: ожидался тип «void *», но аргумент имеет тип «const unsigned char *» 922 | void _rtw_memcpy(void *dst, const void *src, u32 sz) | ~~~~~~^~~ cc1: некоторые предупреждения считаются ошибками make[2]: *** [scripts/Makefile.build:289: /home/eugene/RTL8812BU/os_dep/osdep_service.o] Ошибка 1 make[1]: *** [Makefile:1842: /home/eugene/RTL8812BU] Ошибка 2 make[1]: выход из каталога «/usr/src/kernels/5.18.13-200.fc36.x86_64» make: *** [Makefile:2390: modules] Ошибка 2 [eugene@fedora RTL8812BU]$

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.