Kernel upgrade for eee for Xandros from stock 2.6.21.4 to 2.6.27.10
#1
Posted 25 December 2008 - 11:53 PM
Kernel upgrade. A bit of patching, scripting, to get latest and greatest 2.6.27.10 (with btusb driver, amont others) run without scraping Xandros and going through the pain of 'doing the whole install from scratch'. Backwards compatibility (booting with old stock kernel) is of course there.
Why is this ?
For me it started with btusb driver for my nice tiny BT dongle and GPRS via mobile (yes, it indeed works :-). Plus ath5k driver delivers better performance in my case (too many networks around, win32 driver getting confused and reconnecting every couple of seconds, ath5k can be forced to do what I want).
So why not install new distro from scratch ?
I like what I got with eee. I would not put that distro on my normal PC, but on eee, it looks 'right'. I just wanted a new kernel, with some new drivers. Keeping all the working stuff. For example network connection management I find great. Superior to eee 'on' XP. Especially for the use case of switching between different networks daily ...
Can you do the same ?
Do not expect some nice & tidy howto here. It is not so easy. It took me quite some time, starting from booting new kernel, getting btusb working with my dongle, getting gprs working, etc .... Then a big decision, do I stick with dual boot, or will I get all the hardware working with *my* kernel ? L2 NIC was easy, web cam as well. Aufs and especially ath5k is pain in the neck. Plus as I've said, I wanted to keep network connection mgmt from Xandros, so I *had* my device to be ath0 and not wlan0, etc ...
Anyway - now it all works. Not worse then with the old kernel and original software. I guess it is better :-). And I have a loads of experience to start some cool hacks.
So the question you should ask is - 'Do I have some spare time and do I want to do the same ?'
This post is not a finalized list of instructions. I want to find out if there is anyone around to start some experience exchange / discussion / whatever in (from my point of view) following areas:
- Kernel configuration, boot performance, etc ...
- aufs patch - I took recent aufs kernel module and 'wired it' into the vanilla 2.6.27.10 kernel (had not balls to go with -mm tree) - so that I don't have to mess up with initrd (my eee is using original initrd !) - I did some 'guesses' there, may be good to verify if they are safe enough ...
- sound - vanilla 2.6.27 has some drivers which look like eee's - but they do not work. They offer 0x8330 and 0x831a, but my eee need 8337. I got a patch from Asus for 2.6.21.4 - but quite something changed in the kernel since then ... anyway - with some guesses I got it to compile, I got it to sing. Again, no idea how clean this patch is ...
- BT, mobiles, GPRS - I got mine working. Pairing is still a problem, workaround is BT applet but an easier solution would be great.
- Wifi - I replaced ath_pci with ath5k, with backwards compatibility. That means, I changed some scripts and now my Xandros is using ath5k in the same way as ath_pci. Basically I only touched the part dealing with kernel modules, and forced ath5k to look like ath_pci (device is called ath0 not wlan0, etc ...). From there on, it was a breeze. I put up some changes to make suspend/restore a bit more stable.
Really, if someone wants to try it, I offer answers to all the questions, even if not real time (I have a job guys :-)) -> and he can then write howto for everyone else. I find it really cool, as I stay with Xandros, only with 2.6.27.10, newest hardware drivers, completely opensource ath5k (and working !!!) and for free :-)
NOTE: I have no use for the modem, I have not used it at all, it will not work with my 2.6.27.10 - I can help with getting it running as well but someone has to take initiative here.
Anyway, if someone finds all what I written above interesting, let me know and I will start posting details.
#2
Posted 26 December 2008 - 09:51 PM
This would make a nice project to maintain for the sake of keeping the Xandros install alive. It looks like ASUS is done updating and supporting it. At least for the 701 series.
I do have a question: when you created your .config for the kernel, were you able to copy and keep the options from the existing one (make oldconfig/cloneconfig)?
Thanks,
-Ray
My Blog: http://rayhaque.blogspot.com
Eee Entries: http://rayhaque.blog...rch/label/eeepc
#3
Posted 27 December 2008 - 09:48 AM
http://forum.eeeuser...ic.php?id=48319
I guess I wouldn't try another time without a detailed tutorial ;)
#4
Posted 27 December 2008 - 02:03 PM
So I took 2.6.27.10 vanilla sources, did make oldconfig and took defaults for all the options - I revisited the configuration again later to tune it for my purposes. Compiled, installed tried to boot and it almost worked. Of course, the filesystems were not mounted properly as asus' initrd needs aufs (in original .config also unionfs has been enabled - no idea why as it seems not to be needed).
Subsequently I took aufs cvs sources (from 25.12.2008, you see when I had so much spare time, right :-)). Since I didn't wanted to mess around with aufs as a module and hack initrd as well, I decided to compile it directly into a kernel. After replacing fs/aufs with the new one, and a bit of fiddling with fs/Makefile and fs/Kconfig, I got it into compilable state.
In this moment, I got a kernel which was already bootable with initrd and Xandros on my EEE. Of course lots of hardware was not working yet properly so I went on:
- applied asus' snd_hda_intel patch. I had to resolve some conflicts, mainly in patch_realtek.c - it seems that stock 2.6.27.10 has already support for certain EEE models, but it didn't work for me (I needed 0x1043,0x8337 which was not there). I had to comment out certain dupe structures which has been added separately in vanilla sources and also by asus' patch. Finally I got it sorted (after reboot, I had to use alsamixer first as Xandros mini mixer is not controlling all volumes).
- applied atl2-2.6.26-4.patch, went quite well.
- took asus_acpi module sources, applied eeemodules-hal patch, compiled and installed it as a module.
- I spent quite some time trying to get new version of wireless (madwifi) stuff in - fighting with iwe_stream_add_* functions, finally realizing that it is not needed at all, as also the ath5k which is in vanilla 2.6.27.10 already works on my EEE - one only has to use 'new' Generic IEEE 802.11 stack, not the old deprecated one (!!!).
Having this, and fiddling with .config even more to get camera working, I was quite happy with the result. My current config can be found under:
http://hajduch.de/ee...config-20081227
(I used '-m' as local version)
Later on, I can publish full sources, but now I am limited to 115kbit connection via BT and my mobile (which was the main reason why I started all this :-)).
There are some things which could be done better - mainly merging asus' snd_hda_intel (patch_realtek) changes - I did it quite dirty, likely the other EEE modes would not be correctly supported with this version - if I find some more time, I will revisit it again and try to submit a kernel patch to save this bit with next kernel version :-).
#5
Posted 27 December 2008 - 03:08 PM
- chmod 000 /usr/sbin/xangetdevices (was 755) - I got quite some segfaults from xangetdevices in log. I 'disabled' it and found so far no problems. There is a reference to this binary in some scripts, listing USB devices - so I tested if USB key is recognized and action offered - and it still is. God knows what this is actually for - any ideas ? (I haven't tested if everything still works with old kernel though)
- I compiled kernel with cpufreq support, added handler for acpi ac_adapter event and a script which changes governor to 'ondemand' (together with p4 modulation it goes as far as 115mhz in idle status) - cannot say if it improves battery life yet though. The script is also called from startsimple.sh to set up proper governor on startup.
http://hajduch.de/ee..._acpi_events_ac
http://hajduch.de/eee/etc_acpi_ac.sh
http://hajduch.de/ee..._startsimple.sh
http://hajduch.de/eee/etc_modules
(added thermal & p4 modulation modules as well)
#6
Posted 27 December 2008 - 03:17 PM
NOTE: in this case, and also in some others, it is not enough to replace executable or config file in normal mode, as the change needs to go to /dev/sda1. I have been therefore constantly rsyncing parts of /dev/sda2 to /dev/sda1 (I have backup of /dev/sda1 for the case, but do not plan to go back anyway).
http://hajduch.de/eee/finit-mod.c
NOTE2: as I already mentioned, if you want to have console on tty2 accessible, you need to install openvt (package kbd I used) and modify xorg.conf - disable DontVTSwitch in ServerFlags section.
- I also compiled & installed wireless-tools.29, original distro had ver 28 and that was not compatible with new kernel any more. It looked working even without this, only complained about possible problems - but I did it just for sure.
#7
Posted 27 December 2008 - 03:23 PM
http://hajduch.de/eee/etc_acpi_wlan.sh
IMPORTANT: in my wlan.sh, I test for kernel version '2.6.27.10-m' - to load ath5k and do a few things differently. If you named your version differently, you need to adjust this. Or do it in a more clever way :-)
#8
Posted 27 December 2008 - 03:34 PM
The biggest problem I had was with pairing. Putting my pairing PIN didn't work - phone asked for PIN, I entered it and then it refused to pair. At last I found into a post tip with starting up bluetooth-applet - which I did - and that did the trick. After typing in passphrase into popup borught up by applet, I finally paired the phone with my BT adapter, and after setting up correct APN, everything suddenly worked :-)
http://hajduch.de/eee/usr_sbin_gprs
#9
Posted 27 December 2008 - 03:44 PM
As far as I can tell, everything works as it should, including suspend to ram, wireless, lan, bluetooth and gprs via BT, camera, sound - and everything based on 'default' Asus' Xandros distro.
If anyone wants to try it and has questions, you can also ask directly (faster response time) via email - martin at hajduch dot de. I will try to answer here in forum though, so that it can help more people.
Have fun :-)
#10
Posted 30 December 2008 - 11:32 PM
then you have it all :-)
#11
Posted 31 December 2008 - 12:11 PM
Quote
then you have it all :-)
#12
Posted 01 January 2009 - 07:42 AM
#13
Posted 01 January 2009 - 06:45 PM
Ubuntu 9.04 NBR on the 64GB SSD + Array.org kernel 2.6.28-12-netbook-eeepc + eee-control for Jaunty
Intel Core 2 Duo iMac Mountain Lion, PowerBook G4 Tiger, PowerBook 5300 Mac OS 8.6, Apple Airport WiFi network WPA/WPA2
#14
Posted 02 January 2009 - 07:34 AM
Quote
#15
Posted 02 January 2009 - 08:22 AM
The only piece of software I needed and hasn't been able to get sources for, was fastinit. And the original one was not able to shutdown my machine properly (I tried to unload all the modules, etc, no success). But there is a free alternative in finit, and it gives me even a chance to tweak it to my needs.
#16
Posted 02 January 2009 - 11:56 AM
Quote
Have you gotten the wireless lan to work on the new kernel build, and did you use the hsf driver?
#17
Posted 03 January 2009 - 10:27 PM
See post #7 for details.
Yes, I mean those patches you described - and as I've said, I actually used only two of them for the snd_intel_hda driver (post #4 has more details) and asus_acpi with additional changes from eeemodules-hal patch.
#18
Posted 04 January 2009 - 05:10 AM
Quote
...There are some things which could be done better - mainly merging asus' snd_hda_intel (patch_realtek) changes -
Edit: I now have sound working on the 2.6.28 kernel, without the ASUS patch. I used alsamixer with PCM and Front set to 100, then adjusted the volume on the speaker panel icon. Sound works!
Edited by lineeepc, 04 January 2009 - 05:32 AM.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












