Unable to use RTL8191SU wifi dongle 8712u.ko

Started by Thomas, December 27, 2012, 11:49:08 PM

Previous topic - Next topic

Thomas

Hi,
I'm trying to use RTL8191SU with A13 as a USB Dongle.
I downloaded the driver sources and compiled successfully against kernel 3.0.52+. 8712u.ko is generated

root@debian:~/rtl8712_8188_8191_8192SU_usb_linux_v2.6.6.0.20120405/driver/rtl8712_8188_8191_8192SU_usb_linux_v2.6.6.0.20120405# ls
8712u.ko                      config       include   modules.order   rf
8712u.mod.c                   crypto       io        Module.symvers  runwpa
8712u.mod.o                   debug        ioctl     mp              sta_mgt
8712u.o                       eeprom       Kconfig   os_dep          wlan0dhcp
autoconf_rtl8712_usb_linux.h  efuse        led       os_intf         wpa1.conf
clean                         hal          Makefile  pwrctrl         xmit
cmd                           ifcfg-wlan0  mlme      recv


make install is successful :

root@debian:~/rtl8712_8188_8191_8192SU_usb_linux_v2.6.6.0.20120405/driver/rtl8712_8188_8191_8192SU_usb_linux_v2.6.6.0.20120405# make install
install -p -m 644 8712u.ko  /lib/modules/3.0.52+/kernel/drivers/net/wireless/rtl8192cu
/sbin/depmod -a 3.0.52+


But the driver insmod fails !
root@debian:~/rtl8712_8188_8191_8192SU_usb_linux_v2.6.6.0.20120405/driver/rtl8712_8188_8191_8192SU_usb_linux_v2.6.6.0.20120405# insmod 8712u.ko
<4>8712u: no symbol version for module_layout
[ 3259.640000] 8712u: no symbol version for module_layout
Error: could not insert module 8712u.ko: Invalid module format


What am I doing wrong ?

Driver download for RTL8191SU :
http://www.realtek.com.tw/downloads/downloadsView.aspx?Langid=1&PFid=48&Level=5&Conn=4&ProdID=229&DownTypeID=3&GetDown=false&Downloads=true


davidefa


Thomas

It does not work :
could not insert '8712u': Exec format error

Any other idea ?

Thomas

I think it's a kernel version incompatibility (8712u.ko is for kernel 3.0.2), but I'm not sure.
Anyway, I do not understand the following (could help me):

A13-Olinuxino-Wifi uses RTL8188CU (8192cu.ko). The doc (Reaktek website) says RTL8188CU is for Kernel 3.0.8.
I'm running on 3.0.52+ and this works ! How ?

The following could explain :
root@debian:~# ls /lib/modules
3.0.52+  3.0.8+
root@debian:~# ls /lib/modules/3.0.8+/81*
/lib/modules/3.0.8+/8192cu.ko
root@debian:~# lsmod
Module                  Size  Used by
8192cu                585740  0


Can someone explain me how this 8192cu.ko designed for kernel 3.0.8 can run on my 3.0.52+ ?

Thomas

Ok I found a solution : directly enable "r8712u" as a module in .config and recompile the kernel.

vinifr

#5
"A stand-alone driver compiled for a given version may no longer compile or work on a more recent one"

So, you must compile the driver against the same version of kernel you are running. No problem compiling a driver made ​​in 3.0.8 to 3.0.52, once the internal API is the same. But a driver i2c done for the 2.6.23 kernel will not compile on kernel 3.0.52, because the API I2C changed.

Make sure that your Makefile points to kernel version used. KDIR := /PathToYourKernel/linux-sunxi


INCDIR = -I ${PRJROOT}/kernel/linux-sunxi/include

ifneq ($(KERNELRELEASE),)
obj-m := eep.o
else
KDIR := ${PRJROOT}/kernel/linux-sunxi
PWD := $(shell pwd)

all:
$(MAKE) -C $(KDIR) $(INCDIR) M=$(PWD) modules
clean:
$(MAKE) -C $(KDIR) M=$(PWD) clean
endif


Compile:
# make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi-