Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Plugging in devices such as LAN adapters, Wi-Fi cards, printers, etc. to Arch Linux ARM.

Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby encima » Thu Jul 05, 2012 7:06 am

Hello All,
I have used Arch for a bit before (on ARM) and decided to slap it on the RPi. Doing that, and running some upgrades, I am left with the kernel stated in the post title.

However, in order to get my Edimax adapter working I need the sources of the kernel, which do not seem to be available?

I have checked in my /var/cache/pacman/pkg folder for the older kernel to downgrade to but no such luck.

The solution outlined here http://archlinuxarm.org/forum/viewtopic.php?f=6&t=1129 seems like it should work but I need the sources, outlined by the following error:
$this->bbcode_second_pass_code('', 'make[1]: Entering directory `/usr/src/linux-3.1.9-27-ARCH+'
Makefile:567: /usr/src/linux-3.1.9-27-ARCH+/arch/armv6l/Makefile: No such file or directory
make[1]: *** No rule to make target `/usr/src/linux-3.1.9-27-ARCH+/arch/armv6l/Makefile'. Stop.
make[1]: Leaving directory `/usr/src/linux-3.1.9-27-ARCH+'
make: *** [modules] Error 2')

I have an arm directory and I tried specifying the makefile dir within that (figured it may be generic?) and I got this:
$this->bbcode_second_pass_code('', 'make: *** No rule to make target `vmlinux', needed by `zImage'. Stop.')

Does anyone know where I can get the sources for armv6, or have any other ideas?

Thanks!
encima
 
Posts: 4
Joined: Thu Jul 05, 2012 6:54 am

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby pepedog » Thu Jul 05, 2012 10:01 am

Which arm device is this for?
If it were me, and drivers existed but not for those ID's, I would hack then in kernel source, rebuild entire kernel package, then create patch and ask for it to be included in kernel builds.
This is an example of a video adapter being added to our kernel package
https://github.com/archlinuxarm/PKGBUILDs/blob/master/core/linux/support.patch
Complicated but better in the long run, you would have to find the file to be changed

This might be easier
http://www.ctrl-alt-del.cc/2012/05/raspberry-pi-meets-edimax-ew-7811un-wireless-ada.html
but start from "Now the wireless part"
pepedog
Developer
 
Posts: 2431
Joined: Mon Jun 07, 2010 3:30 pm
Location: London UK

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby encima » Thu Jul 05, 2012 12:25 pm

I am using the RPi, which is armv6.

Using the blog post you mentioned gives an $this->bbcode_second_pass_code('', 'exec format error') on modprobe, I assume because it is for an older kernel.

I have little knowledge of compiling kernels but I am happy to give it a go. My issue is that I cannot find the sources for the kernel I need. Any ideas where to find them? I only have the binaries from pacman.
encima
 
Posts: 4
Joined: Thu Jul 05, 2012 6:54 am

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby pepedog » Thu Jul 05, 2012 1:04 pm

If you install these
$this->bbcode_second_pass_code('', 'pacman -S git file base-devel abs')
Search this forum for swapon to get a swap file, in /boot directory copy arm224_ to start.elf to get more ram
Download the source to build packages for the kernel
$this->bbcode_second_pass_code('', 'git clone git://github.com/archlinuxarm/PKGBUILDs.git')
enter the folder
$this->bbcode_second_pass_code('', 'cd PKGBUILDs/core/linux-raspberrypi')
uncomment make menuconfig in PKGBUILD file
Suggest you install webmin so you can edit things later
Start build
$this->bbcode_second_pass_code('', 'makepkg -As --asroot')
It will pause at a menu system, this is where webmin comes in handy to edit things
Once finished, the kernel source will be left behind
pepedog
Developer
 
Posts: 2431
Joined: Mon Jun 07, 2010 3:30 pm
Location: London UK

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby encima » Tue Jul 10, 2012 8:21 am

OK, apologies for the delay in replying but I had some issues with available SD space.

After various new builds, and now running the $this->bbcode_second_pass_quote('', '3').1.9-28-ARCH+
kernel. I got the sources from PKGBUILDS and I have the driver source from the Realtek website (8188CUS).

OK, the obvious error, when I do not use the retrieved kernel source is as follows:
$this->bbcode_second_pass_code('', 'make ARCH=armv6l CROSS_COMPILE= -C /lib/modules/3.1.9-28-ARCH+/build M=/home/root/Downloads/RTL8188C_8192C_USB_linux_v3.4.3_4369.20120622/driver/rtl8188C_8192C_usb_linux_v3.4.3_4369.20120622 modules
make[1]: Entering directory `/usr/src/linux-3.1.9-28-ARCH+'
Makefile:567: /usr/src/linux-3.1.9-28-ARCH+/arch/armv6l/Makefile: No such file or directory
make[1]: *** No rule to make target `/usr/src/linux-3.1.9-28-ARCH+/arch/armv6l/Makefile'. Stop.
make[1]: Leaving directory `/usr/src/linux-3.1.9-28-ARCH+'
make: *** [modules] Error 2
##################################################
Compile make driver error: 2
Please check error Mesg
')

As it happens, I do now have the kernel source in that directory but, unsurprisingly, the script is right. Even puling the sources down does not give me an armv6l folder, only arm.

So, my question is: Do I need the armv6l folder (and if so, how do I find it) or can I redirect it to use the Makefile in the arm folder?

Thanks!
encima
 
Posts: 4
Joined: Thu Jul 05, 2012 6:54 am

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby pepedog » Tue Jul 10, 2012 8:44 am

Can you say where you got the edimax drivers from? I never had this problem.
http://archlinuxarm.org/forum/viewtopic.php?f=31&t=3192#p18506
Someone with same hardware has tested this
pepedog
Developer
 
Posts: 2431
Joined: Mon Jun 07, 2010 3:30 pm
Location: London UK

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby encima » Tue Jul 10, 2012 9:16 am

I got this working through the use of various sources, many thanks to Pepedog on here, for the kernel help!

I slapped it into a blog, for future reference. Here it is:http://christopher-gwilliams.com/blog/?p=22
encima
 
Posts: 4
Joined: Thu Jul 05, 2012 6:54 am

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby pepedog » Tue Jul 10, 2012 1:15 pm

You don't have to download kernel sources or build kernel, I tried this on new install so I know it works
Also pacman -S unzip is needed
Download right source
http://www.realtek.com.tw/downloads/downloadsView.aspx?Langid=1&PNid=48&PFid=48&Level=5&Conn=4&DownTypeID=3&GetDown=false&Downloads=true#RTL8188CUS
You can't wget the driver
$this->bbcode_second_pass_code('', 'unzip RTL819xCU__USB_linux_v3.4.3_4369.20120622.zip
cd RTL8188C_8192C_USB_linux_v3.4.3_4369.20120622/driver/
tar xzf rtl8188C_8192C_usb_linux_v3.4.3_4369.20120622.tar.gz
cd rtl8188C_8192C_usb_linux_v3.4.3_4369.20120622
')
Now edit the Makefile
$this->bbcode_second_pass_code('', '
CONFIG_PLATFORM_I386_PC = y
becomes
CONFIG_PLATFORM_I386_PC = n
CONFIG_PLATFORM_ARM_BCM2708 = y

ifeq ($(CONFIG_PLATFORM_I386_PC), y)
becomes
ifeq ($(CONFIG_PLATFORM_ARM_BCM2708), y)
EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN
ARCH := arm
CROSS_COMPILE :=
KVER := 3.1.9-28-ARCH+
KSRC := /lib/modules/$(KVER)/build
endif [/b]

ifeq ($(CONFIG_PLATFORM_I386_PC), y)

')
Now make and follow the rest of your instructions. Will save many hours, takes only 5 minutes of compiling, no symlinks needed
(psst, arch has headers)
pepedog
Developer
 
Posts: 2431
Joined: Mon Jun 07, 2010 3:30 pm
Location: London UK

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby devacc12 » Fri Jul 20, 2012 5:43 pm

I've tried this today as I have an 8192cu driver problem since a pacman -Syu update yesterday but I get warnings about smp_lock.h.
I tried editing a few .h .c files to smp.h as indicated in another archlinux post but no joy.
Anyone else been able to compile on the latest Kernel 3.1.9-31?
devacc12
 
Posts: 13
Joined: Thu Jul 05, 2012 9:20 pm

Re: Latest Arch Kernel (3.1.9-27) and Edimax EW-7811Un

Postby pepedog » Sat Jul 21, 2012 3:18 pm

You have an old driver source.
There is version magic with the previous module, it doesn't match kernel version, tried to make rebuild easy on the rpi, it takes 10 minutes to do
$this->bbcode_second_pass_code('', 'wget http://myplugbox.com/rtl8188C_8192C_usb_linux_v3.4.3_4369.20120622.tar.gz
tar xzf rtl8188C_8192C_usb_linux_v3.4.3_4369.20120622.tar.gz
nano Makefile')
Change KVER to what the current version is (there must be a way of automating, but feeling lazy)
It's currently set to-
KVER := 3.1.9-31-ARCH+
$this->bbcode_second_pass_code('', 'make
cp 8192cu.ko /usr/lib/modules/extramodules-3.1.9--raspberrypi/
depmod -a
modprobe 8192cu')
pepedog
Developer
 
Posts: 2431
Joined: Mon Jun 07, 2010 3:30 pm
Location: London UK

Next

Return to Hardware

Who is online

Users browsing this forum: No registered users and 5 guests