Need help building/running kernel/firmware


MotE

Still Fresh
Joined
Mar 28, 2011
Messages
12
Hello everyone,


so since I'm mostly a noob in the kernel/firmware building thing, I've decided to educate myself.


I followed a few wikis, and managed to cross-compile (with CodeSourcery 2007q3) kernel 2.6.27-omap1.


Installed it in a rootfs on SD Card (with make modules_install firmware_install && cp uImage <SD>/boot)


When I first ran it, it reached XFCE then restarted.


Found out it was apparently a config problem with battery managment, tried defconfig from openpandora.oe/recipes/linux/omap3-pandora-kernel/defconfig, to no avail.


Finally I tried with the config file from my pandora running HF5 (/proc/config.gz) and finally it worked fine !


(Don't understand why however, since the defconfig from openpandora.oe seems to enable the same option battery-wise)


However now I'm trying to build kernels pandora-37 and pandora-39, with omap3_pandora_[debug_]defconfig.


Compilation seems to work fine, but when booting from SD, U-Boot hangs after "Starting kernel..."


I found out it was most likely a problem between the MACH value given by U-Boot to the kernel, and the builtin MACH value of the kernel (but couldn't confirm it).


The references I found about MACH in config files seem to indicate the value used is the same for my working 2.6.27 kernel and my not-booting 2.6.39 kernel...


So now I'm stuck, I must admit I don't even know how I could get U-Boot/Kernel to spit out more info about the problem (tried to enable some debug option in the kernel - to no avail) since I'm a noob :p


See something I could have missed ?


Should I try to compile U-Boot and fiddle with it (debug option, MACH value) ?


Firmware-wise, I tried to follow the wiki, set-up an OE-environment with the help of pandora-oe-environment.git scripts.


Everything seems to work fine, except anoncvs.handhelds.org is no longer available.


It first posed a problem with update-rc.d which I managed to fix with a mirror.


Now I'm stuck with ipkg-utils(-native) since I can't seem to find a mirror for version 1.6+cvs20050404


Is there a simpler/general way to fix the problem with handhelds.org ?


I also tried to setup the OE envirronment from github/openpandora, but I'm still working on setting everything up to run bitbake...


How are Hotfixes built ? from git.openpandora.org or github/openpandora ?


So, if any kind soul could improve my wisdom on those matters, I would greatly appreciate it.


I tried to do as much as I could on my own, however I seem to be stalling a bit now...
 
Heiho,


well, i had the same problem in the past. For me it was the problem that i compile with a wrong kernel option.


There is the option for the MMC-Card TI OMAP High Speed Multimedia Card Interface support (MMC_OMAP_HS) but i configure also the TI OMAP Multimedia Card Interface support (MMC_OMAP).


If you boot from sd-card take care of this option. Use only one MMC-Card Interface.


But neverless, i compile and boot pandora-37


which compiler do you use?
 
thanks for your answer,

If you boot from sd-card take care of this option. Use only one MMC-Card Interface.

I checked and only the OMAP_HS was activated. I switched to MMC_OMAP and activated a few debug option for MMC,


but nothing changed.

But neverless, i compile and boot pandora-37

nice to know it's worth the pain :) guess I'm just unlucky or missing something obvious...


did you more or less follow the instructions from the pandora wiki ?


on my side I just do this :


mrproper


make omap3_pandora_defconfig


make uImage modules


INSTALL_MOD_PATH=/path/to/SDCard make modules_install firmware_install


cp ./arch/arm/boot/uImage /path/to/SDcard/boot/uImage-2.6.39


ln -s /path/to/SDcard/boot/uImage-2.6.39 /path/to/SDcard/boot/uImage


missed anything ?

which compiler do you use?

I'm using CodeSourcery 2007q3 cross-compiling toolchain.
 
The MACH value hasn't changed and default u-boot can load .37 and .39 kernels just fine, don't waste your time on that.


What are your bootargs (contents of [auto]boot.txt/boot.scr)?


What's the filesystem on your SD card?
 
Last edited by a moderator:
The MACH value hasn't changed and default u-boot can load .37 and .39 kernels just fine, don't waste your time on that.

ok, thanks.

What are your bootargs (contents of [auto]boot.txt/boot.scr)?


What's the filesystem on your SD card?

my SDcard is ext2.


I use the same boot.txt as for standard rootfs/kernel, as I'm still not sure what all the args mean (lot of things to learn) :



Code:
setenv bootargs debug root=/dev/mmcblk0p1 rw rootdelay=2 console=ttyS0,115200n8 vram=6272K omapfb.vram=0:3000K

ext2load mmc 0 0x80030000 /boot/uImage

bootm 0x80030000


If I just change the uImage link to point to standard 2.6.27 kernel, or a 2.6.27 I built myself, it works.


So I may be wrong, but I think it's a problem coming from the way I build kernel 2.6.39 (I'm using standard config obtained by "make omap3_pandora_[debug_]defconfig")


I'll have to compare the config files but many names have changed between 27 et 39 so the diff isn't very helpfull.


ps : it's my first occasion to say this : THANK YOU NOTAZ FOR ALL YOUR HARD WORK !


and still finding time to answer noobs on forums ;)
 
The serial driver has changed in .37, so you need to specify correct console= argument (see here) or not specify it at all. I'm guessing you don't have serial cable so just remove console=... arg completely.


I'm not 100% sure but I think the new OMAP kernels hang if you specify wrong serial.
 
The serial driver has changed in .37, so you need to specify correct console= argument (see here) or not specify it at all. I'm guessing you don't have serial cable so just remove console=... arg completely.


I'm not 100% sure but I think the new OMAP kernels hang if you specify wrong serial.

I saw this console argument thing some time ago and tried the new argument too.


Anyway, I just re-did the test, both with tty02 and without the console=... altogether => same result


Here is exactly what I see when the boot hangs :



Code:
Loading file "boot.txt" from mmc1 device 0:1 (xxa1)

168 bytes read

## Executing plain script at 82000000

Loading file "/boot/uImage" from mmc device 0:1 (xxa1)

2929816 bytes read

## Booting kernel from Legacy Image at 80030000 ...

   Image Name: Linux-2.6.39.1-00030-gd8b37c1

   Image Type: ARM Linux Kernel Image (uncompressed)

   Data Size: 2929752 Bytes = 2.8 MB

   Load Address: 80008000

   Entry Point: 80008000

   Verifying Checksum ... OK

   Loading Kernel Image ... OK

OK


Starting kernel ...


If I compare this with the output I get when booting 2.6.27 kernel, everything looks the same.


Any flag I could set to enable more verbose output ?
 
on the firmware issue (git.openpandora.org vs github/openpandora + handhelds.org down), advice anyone ?
 
Last edited by a moderator:
Give me your uImage and I'll give you it's serial output.

on the firmware issue (git.openpandora.org vs github/openpandora + handhelds.org down), advice anyone ?
We have a source mirror at http://www.openpandora.org/firmware/sources/


You'll need to add this to some OE source list (not sure how to do that or if it's possible at all), or just download missing file manually where failing wget tries to download it.
 
ok, got your uImage and I get no output even on serial, something goes wrong really early.. I think I've read somewhere CS 2007q3-51 miscompiles newer kernels, you should try newer compiler. I use 2009q1 and it compiles new and old kernels fine.
 
Last edited by a moderator:
Yup, that was it. Thanks. Used 2009-q1-203 and it's now going past the "starting kernel" stage (only to fail a little later of course).


Maybe you read about this problem with 2007-q3 on the beagleboard wiki page which is linked in the pandora wiki, and which I should have read myself <_<


Shall I update the pandora wiki as penitence ? (it stills refers to 2007q3 as recommended)


Now the boot hangs at "starting PVR", apparently missing omaplfb and bufferclass_ti modules...


anyway, I'll continue to post update on my progress with kernel and firmware, might help another noob in the future.
 
Back
Top