Realtek RTL8192eu driver problem

Post here if you are a new Porteus member and you're looking for some help.
hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL8192eu driver problem

Post#1 by hope » 12 Jun 2023, 15:59

Hi,
I bought a Realtek RTL8219eu usb antenna and I tried to connect wifi modem but I had some trouble to connect. My Porteus's kernel version is 5.12.14.
I read the forum page : [Solved] NEED HELP!!! and Blaze's comments and suggestions and I did those (step by step) :
1. I checked that is there any wifi when I directly connect my usb antenna and I got wifi connections' list. No problem upto here. But when I tried to connect my wifi, it could not connect.
2. Then I checked which driver my porteus is using and saw that it is using rtl8xxxu for wlan0 connection.
3. In the forum pages, blaze suggested to remove it from modules and I did so and I used :

Code: Select all

su
toor
modprobe -r rtl8xxxu
modprobe rtl8192eu
but no success since there is no such module for my device on-the-shelf for porteus.
4. I did what blaze suggested again and I download the drive from git page https://github.com/Mange/rtl8192eu-linux-driver as zip file and extract it under the /tmp folder
5. I downloaded 05-devel.xzm and crippled-sources.xzm modules too and activate them
6. I entered into the folder I extracted and try to use command

Code: Select all

make && make install
7. It gives below error:

Code: Select all

/tmp/rtl8192eu-linux-driver-realtek-4.4.x# make && make install
make ARCH=i386 CROSS_COMPILE= -C /lib/modules/5.12.14-porteus/build M=/tmp/rtl8192eu-linux-driver-realtek-4.4.x  modules
make[1]: Entering directory '/usr/src/linux-5.18.8'
  CC [M]  /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o
In file included from /tmp/rtl8192eu-linux-driver-realtek-4.4.x/include/drv_types.h:60,
                 from /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:17:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/include/rtw_recv.h: In function ‘recvframe_put’:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/include/rtw_recv.h:704:24: warning: variable ‘prev_rx_tail’ set but not used [-Wunused-but-set-variable]
  704 |         unsigned char *prev_rx_tail;
      |                        ^~~~~~~~~~~~
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c: In function ‘rtw_cmd_thread’:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:518:23: warning: variable ‘prspbuf’ set but not used [-Wunused-but-set-variable]
  518 |         u8 *pcmdbuf, *prspbuf;
      |                       ^~~~~~~
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c: In function ‘rtw_joinbss_cmd’:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:1485:74: warning: taking address of packed member of ‘struct _WLAN_BSSID_EX’ may result in an unaligned pointer value [-Waddress-of-packed-member]
 1485 |                         pnetwork->network.IELength - 12, &psecnetwork->IELength,
      |                                                          ^~~~~~~~~~~~~~~~~~~~~~

/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:1504:64: warning: taking address of packed member of ‘struct _WLAN_BSSID_EX’ may result in an unaligned pointer value [-Waddress-of-packed-member]
 1504 |   rtw_append_exented_cap(padapter, &psecnetwork->IEs[0], &psecnetwork->IELength);
      |                                                          ^~~~~~~~~~~~~~~~~~~~~~

/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:1343:18: warning: variable ‘auth’ set but not used [-Wunused-but-set-variable]
 1343 |         u8      *auth, res = _SUCCESS;
      |                  ^~~~
as: error while loading shared libraries: libbfd-2.37-slack15.so: cannot open shared object file: No such file or directory
make[2]: *** [scripts/Makefile.build:288: /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o] Error 1
make[1]: *** [Makefile:1838: /tmp/rtl8192eu-linux-driver-realtek-4.4.x] Error 2
make[1]: Leaving directory '/usr/src/linux-5.18.8'
make: *** [Makefile:2287: modules] Error 2
8. I thought that newer package needed for blibfd and found and install it as :

Code: Select all

txz2xzm binutils-2.40-i586-1.txz binutils-2.40-i586-1.xzm
Verifying package binutils-2.40-i586-1.txz.
Installing package binutils-2.40-i586-1.txz:
PACKAGE DESCRIPTION:
# binutils (GNU binary development tools)
#
# Binutils is a collection of binary utilities. It includes "as" (the 
# portable GNU assembler), "ld" (the GNU linker), and other utilities
# for creating and working with binary programs.
#
# These utilities are REQUIRED to compile C, C++, Objective-C, Fortran,
# and most other programming languages.
#
Executing install script for binutils-2.40-i586-1.txz.
Package binutils-2.40-i586-1.txz installed.
Creating /tmp/binutils-2.40-i586-1.xzm
9. then I try to "make" again and this time I got :

Code: Select all

/tmp/rtl8192eu-linux-driver-realtek-4.4.x# make && make install
make ARCH=i386 CROSS_COMPILE= -C /lib/modules/5.12.14-porteus/build M=/tmp/rtl8192eu-linux-driver-realtek-4.4.x  modules
make[1]: Entering directory '/usr/src/linux-5.18.8'
  CC [M]  /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o
In file included from /tmp/rtl8192eu-linux-driver-realtek-4.4.x/include/drv_types.h:60,
                 from /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:17:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/include/rtw_recv.h: In function ‘recvframe_put’:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/include/rtw_recv.h:704:24: warning: variable ‘prev_rx_tail’ set but not used [-Wunused-but-set-variable]
  704 |         unsigned char *prev_rx_tail;
      |                        ^~~~~~~~~~~~
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c: In function ‘rtw_cmd_thread’:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:518:23: warning: variable ‘prspbuf’ set but not used [-Wunused-but-set-variable]
  518 |         u8 *pcmdbuf, *prspbuf;
      |                       ^~~~~~~
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c: In function ‘rtw_joinbss_cmd’:
/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:1485:74: warning: taking address of packed member of ‘struct _WLAN_BSSID_EX’ may result in an unaligned pointer value [-Waddress-of-packed-member]
 1485 |                         pnetwork->network.IELength - 12, &psecnetwork->IELength,
      |                                                          ^~~~~~~~~~~~~~~~~~~~~~

/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:1504:64: warning: taking address of packed member of ‘struct _WLAN_BSSID_EX’ may result in an unaligned pointer value [-Waddress-of-packed-member]
 1504 |   rtw_append_exented_cap(padapter, &psecnetwork->IEs[0], &psecnetwork->IELength);
      |                                                          ^~~~~~~~~~~~~~~~~~~~~~

/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.c:1343:18: warning: variable ‘auth’ set but not used [-Wunused-but-set-variable]
 1343 |         u8      *auth, res = _SUCCESS;
      |                  ^~~~
as: /lib/libc.so.6: version `GLIBC_2.34' not found (required by as)
as: /lib/libc.so.6: version `GLIBC_2.34' not found (required by /usr/lib/libbfd-2.40-slack151.so)
make[2]: *** [scripts/Makefile.build:288: /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o] Error 1
make[1]: *** [Makefile:1838: /tmp/rtl8192eu-linux-driver-realtek-4.4.x] Error 2
make[1]: Leaving directory '/usr/src/linux-5.18.8'
make: *** [Makefile:2287: modules] Error 2


10. this time I downloaded and installed(activated module) of glibc-2.37 package :

Code: Select all

txz2xzm glibc-2.37-i586-2.txz glibc-2.37-i586-2.xzm
Verifying package glibc-2.37-i586-2.txz.
Installing package glibc-2.37-i586-2.txz:
PACKAGE DESCRIPTION:
# glibc (GNU C libraries)
#
# This package contains the GNU C libraries and header files. You'll
# need this package to compile programs.https://packages.slackware.com/
#
# The GNU C library was originally authored by Roland McGrath.
#
# Homepage: https://www.gnu.org/software/libc/
#
Executing install script for glibc-2.37-i586-2.txz.
Package glibc-2.37-i586-2.txz installed.
Creating /tmp/glibc-2.37-i586-2.xzm
11. Then I try to "make" again but this time it completely failed :

Code: Select all

/tmp/rtl8192eu-linux-driver-realtek-4.4.x# make && make install
make ARCH=i386 CROSS_COMPILE= -C /lib/modules/5.12.14-porteus/build M=/tmp/rtl8192eu-linux-driver-realtek-4.4.x  modules
make[1]: Entering directory '/usr/src/linux-5.18.8'
  CC [M]  /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o
/bin/sh: line 1: scripts/basic/fixdep: cannot execute binary file: Exec format error
make[2]: *** [scripts/Makefile.build:288: /tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o] Error 126
make[2]: *** Deleting file '/tmp/rtl8192eu-linux-driver-realtek-4.4.x/core/rtw_cmd.o'
make[1]: *** [Makefile:1838: /tmp/rtl8192eu-linux-driver-realtek-4.4.x] Error 2
make[1]: Leaving directory '/usr/src/linux-5.18.8'
make: *** [Makefile:2287: modules] Error 2
After this journey, I have to ask these questions :
1. Where did I do wrong?
2. Do I have to find(I searched but I only can find https://packages.slackware.com/ for getting slackware packages web page) the exact package number? Isn't there any back compatibility for packages?
3. Is there any ready RTL8192EU device driver for slackware, if so, where can I find those device drivers(I have searched in https://packages.slackware.com/, nothing in there)?
At the end any help is appreciated. Thanks.
Last edited by hope on 12 Jun 2023, 16:53, edited 2 times in total.
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL3192eu driver problem

Post#2 by hope » 12 Jun 2023, 16:33

Update : I found binutils-2.37 exact vesion in : https://ftp.slackware.com/pub/slackware ... ackware/d/, but no success for glibc-2.34 yet...
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

beny
Full of knowledge
Full of knowledge
Posts: 2098
Joined: 02 Jan 2011, 11:33
Location: italy

Realtek RTL8192eu driver problem

Post#3 by beny » 12 Jun 2023, 17:42

hi hope you have two different version of modules in your system one in lib with the /lib/modules/5.12.14-porteus but you have in /usr/src another kernel version /usr/src/linux-5.18.8 when you build a driver make check the kernel version in /usr/src after you have build it with insmod you can install the driver into the lib modules but have to be the same version.
blaze have built also a 32 bit version of the last kernel try it

hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL8192eu driver problem

Post#4 by hope » 13 Jun 2023, 11:45

Hi, beny, thanks for answer.

When I did not understand something please give it to my illiteracy about Linux terms and processes. :happy62: In git page of the driver they said that "we could give no support, just code !" :shock:

My porteus's "kernel version numbers of lib modules" is 5.12.14 which is older than kernel number in the Linux's source code which is 5.18.8, did I understand it correctly?
What I did was that looking the erros given during insallation and getting the packages accordingly. For instance, when I found a driver source in the internet, is there any readme file or something that I can look so that I can undestand whether it is suitable for my linux kernel(5.18.8) or not? So, I think that that is where I did mistake , right? If you do not mind, can you please explain it a little bit more, since I am a little bit confused.

Also you wrote that :

"...after you have build it with insmod..."

I do not know how to use insmod :D I searched and found that, it is requied to insert the module into kernel, do I have to do it? Instead of using it, can I do that :
1. compile driver from source for my own porteus's kernel,
2. convert driver to xzm module,
3. copy it to a convenient folder,
4. after "alyways refresh" start, I can right click it and activate it like a module?
Thanks.
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

beny
Full of knowledge
Full of knowledge
Posts: 2098
Joined: 02 Jan 2011, 11:33
Location: italy

Realtek RTL8192eu driver problem

Post#5 by beny » 13 Jun 2023, 14:09

hi hope the driver of your device are out of the kernel driver build,so if you use the last kernel 32 bit of blaze with the crippled-source activated you have a good base to work with download the git packages and you can,well i have do this with mine cd inside the driver directory: make clean and make if you have the system ok driver build when ready make install now you have to use the insmod like this: the module.ko is loaded at boot so the message of error in my system but this is how to work, in porteus you have to load also the
/lib/modules/6.4.0-rc6-beny/kernel/net/wireless/cfg80211.ko
insmod '/lib/modules/6.4.0-rc6-beny/kernel/drivers/net/wireless/realtek/rtw88/rtw88_8822bu.ko'
insmod: ERROR: could not insert module /lib/modules/6.4.0-rc6-beny/kernel/drivers/net/wireless/realtek/rtw88/rtw88_8822bu.ko: File exists
insmod that mean insert module you have to find the right path of a module and you can load with this in terminal,ok

hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL8192eu driver problem

Post#6 by hope » 13 Jun 2023, 14:40

Thanks beny,
Where can I find blaze's last kernel? Do you have a link?
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

beny
Full of knowledge
Full of knowledge
Posts: 2098
Joined: 02 Jan 2011, 11:33
Location: italy

Realtek RTL8192eu driver problem

Post#7 by beny » 13 Jun 2023, 15:11


hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL8192eu driver problem

Post#8 by hope » 13 Jun 2023, 16:05

Thanks beny, now t I got the file and I will try to change the kernel and will write back my results here.
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL8192eu driver problem

Post#9 by hope » 14 Jun 2023, 21:14

Hi, I could not succeed to load even a new kernel since I could not find where I will insert the new kernel files in my old porteus :
1.I am not sure just a copying the new kernel files into usb's boot (or other folders since I I could not find all files' locations : I looked under "boot" folders in my usb and found only vmlinuz, "newkernel".xzm file, could not find others' possible locations) folders are enough to update porteus. If so, is there any forum post or web page to explain how it is done
2. Since I could not update to new kernel, I just tried to compile again my device's own driver (which is in https://www.desteksegment.com/segmentde ... driver.rar ) but this time with binutils-2.37(not 2.40) and glibc-2.37 for i586 but got the same "Exec format error" like thing and some c file errors.

So I want to go to a shortcut and asked whether Porteus Kiosk(which has rtl8192eu driver in its kernel and that seems more suitable for internet usage) has 32 bit support. Thanks to fanthom, answered my question. :)

Maybe I do not need to compile the driver either, today I am not sure because I noticed that existed rtl8xxxu driver sees my device and all wifi networks but I could not connect to "my wifi network", maybe problem was in my connection settings? So I will focus there from now on. Thanks for every help.
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

User avatar
Ed_P
Contributor
Contributor
Posts: 8374
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Realtek RTL8192eu driver problem

Post#10 by Ed_P » 14 Jun 2023, 23:49

hope the vmlinuz file replaces the one in the /boot/syslinux/ folder, the "newkernel"'s 000-kernel.xzm replaces the one in the /porteus/base/ folder. Any other files in the kernel download can be placed in the /porteus/optional/ folder for use only when you need them. If you can create a driver module put it in the /porteus/modules/ folder.
Ed

hope
Black ninja
Black ninja
Posts: 64
Joined: 04 Jul 2020, 12:07
Distribution: porteus 5.0rc1 KDE desktop

Realtek RTL8192eu driver problem

Post#11 by hope » 15 Jun 2023, 09:45

Ed_P, thanks for answer :happy62:
Newbie to Linux-Unix systems, try to read,learn, apply, modify and create.

Post Reply