Hello everybody,
I'm struggling to find a way of booting an armv7 fs compiled with poky / yocto. I found some resources on the internet but none proved to be successful for me. Would you be so kind and provide me some infos upon this topic?
I would be so grateful if anybody could explain me the boot process, and if anybody managed to boot an armv7, what kernel did he use, how did he compiled it and so on. Is there a simply way to boot this? Something like: qemu-system-arm -kernel /home/xxx/work/yyy/yocto/2012-01-08-14-57/tmp/deploy/images/zImage-qemuarmv7.bin -net nic,vlan=0 -net tap,vlan=0,ifname=tap0,script=no,downscript=no -M vexpress-a9 -hda /home/xxx/work/yyy/yocto/2012-01-08-14-57/tmp/deploy/images/image-qemuarmv7.ext3 -no-reboot -show-cursor -usb -cpu cortex-a8 -no-reboot -m 128 --append "root=/dev/sda rw console=ttyAMA0,115200 console=tty ip=192.168.7.2::192.168.7.1:255.255.255.0 mem=128M highres=off "
What defconfig to use for the kernel? Do i need a modified kernel? Do i need somthing special in the file-system? Any help would be great.
ag
Hey
On Wed, Jan 11, 2012, Andrei Gherzan wrote:
I'm struggling to find a way of booting an armv7 fs compiled with poky / yocto. I found some resources on the internet but none proved to be successful for me. Would you be so kind and provide me some infos upon this topic?
There are a couple of HowTos on the wiki linked from https://wiki.linaro.org/Resources/HowTo/Qemu but the instructions might not be fully up-to-date; perhaps they provide enough guidance for you to overcome your issues? Would you fix or point out the issues in the HowTos if they fail you?
Thanks!
On 01/11/2012 05:21 PM, Loïc Minier wrote:
Hey
On Wed, Jan 11, 2012, Andrei Gherzan wrote:
I'm struggling to find a way of booting an armv7 fs compiled with poky / yocto. I found some resources on the internet but none proved to be successful for me. Would you be so kind and provide me some infos upon this topic?
There are a couple of HowTos on the wiki linked from https://wiki.linaro.org/Resources/HowTo/Qemu but the instructions might not be fully up-to-date; perhaps they provide enough guidance for you to overcome your issues? Would you fix or point out the issues in the HowTos if they fail you?
Thanks!
I know that wiki. But ... are detailed enough only for pre-compiled images and so on. Want to compile my own kernel and boot it in qemu linaro - My kernel and my filesystem.
ag
Hi,
I've used this script (http://wiki.gumstix.org/index.php?title=Overo_qemu_script) to package binary bootloaders, kernels and a rootfs into a qemu-bootable format. I tweaked it specifically for the Cortex-A8 based Gumstix Overo but it should also work for Beagleboard and should be a good starting point for other system. More generically: http://wiki.gumstix.org/index.php?title=Overo_emulation_in_qemu
HTH, -Ash
On Wed, Jan 11, 2012 at 7:46 AM, Andrei Gherzan andrei@gherzan.ro wrote:
On 01/11/2012 05:21 PM, Loïc Minier wrote:
Hey
On Wed, Jan 11, 2012, Andrei Gherzan wrote:
I'm struggling to find a way of booting an armv7 fs compiled with poky / yocto. I found some resources on the internet but none proved to be successful for me. Would you be so kind and provide me some infos upon this topic
There are a couple of HowTos on the wiki linked from https://wiki.linaro.org/Resources/HowTo/Qemu but the instructions might not be fully up-to-date; perhaps they provide enough guidance for you to overcome your issues? Would you fix or point out the issues in the HowTos if they fail you?
Thanks!
I know that wiki. But ... are detailed enough only for pre-compiled images and so on. Want to compile my own kernel and boot it in qemu linaro - My kernel and my filesystem.
ag
linaro-dev mailing list linaro-dev@lists.linaro.org http://lists.linaro.org/mailman/listinfo/linaro-dev
On 01/11/2012 07:44 PM, Ash Charles wrote:
Hi,
I've used this script (http://wiki.gumstix.org/index.php?title=Overo_qemu_script) to package binary bootloaders, kernels and a rootfs into a qemu-bootable format. I tweaked it specifically for the Cortex-A8 based Gumstix Overo but it should also work for Beagleboard and should be a good starting point for other system. More generically: http://wiki.gumstix.org/index.php?title=Overo_emulation_in_qemu
HTH, -Ash
Ash,
You pointed me to the right place where i could find the need infos. Thank you very much. Anyway, i do have a problem now. Qemu is not booting. It fails with:
--------------------> Booting from mmc ... ## Booting kernel from Legacy Image at 82000000 ... Image Name: Linux-3.0.14-yocto-standard-0007 Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 786208 Bytes = 767.8 KiB Load Address: 00008000 Entry Point: 00008000 Verifying Checksum ... OK Loading Kernel Image ... OK OK
Starting kernel ...
qemu: fatal: Trying to execute code outside RAM or ROM at 0x00008000
R00=00000000 R01=0000060a R02=80000100 R03=00000083 R04=00000000 R05=9ff0ffe0 R06=0000060a R07=9ffb1320 R08=9ff0ff68 R09=80000120 R10=00008000 R11=9ff14510 R12=00000007 R13=9ff0fb40 R14=9ff7335c R15=00008000 PSR=600001d3 -ZC- A svc32 Aborted <--------------------
It seems that my conf: #UBOOT_ENTRYPOINT = "0x80008000" #UBOOT_LOADADDRESS = "0x80008000"
are not correct. Am i right? Need some more help.
On 01/11/2012 07:44 PM, Ash Charles wrote:
Hi,
I've used this script (http://wiki.gumstix.org/index.php?title=Overo_qemu_script) to package binary bootloaders, kernels and a rootfs into a qemu-bootable format. I tweaked it specifically for the Cortex-A8 based Gumstix Overo but it should also work for Beagleboard and should be a good starting point for other system. More generically: http://wiki.gumstix.org/index.php?title=Overo_emulation_in_qemu
HTH, -Ash
I used linux-yocto kernel for beagleboard and got over my last problem: KMACHINE_qemuarmv7 = "yocto/standard/beagleboard" SRCREV_machine_qemuarmv7 ?= "6b4bf6173b0bd2d1619a8218bac66ebc4681dd35" COMPATIBLE_MACHINE_qemuarmv7 = "qemuarmv7"
Now my boot process is looping in:
omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214 omap_i2c_write: Bad register 0x00000214
Any ideas?
@g
On 01/12/2012 02:04 PM, Andrei Gherzan wrote:
I used linux-yocto kernel for beagleboard and got over my last problem: KMACHINE_qemuarmv7 = "yocto/standard/beagleboard" SRCREV_machine_qemuarmv7 ?= "6b4bf6173b0bd2d1619a8218bac66ebc4681dd35" COMPATIBLE_MACHINE_qemuarmv7 = "qemuarmv7"
Now my boot process is looping in:
omap_i2c_write: Bad register 0x00000214
Any ideas?
@g
This was because i used beaglexm and not beagle as -M. Now my whole thing can boot successfully with one down point: cannot see kernel boot messages... i can review them with dmesg.
#qemu-system-arm -M beagle -m 256 -sd sd.img -clock unix -serial stdio
U-Boot 2011.06 (Jan 12 2012 - 15:21:35)
OMAP35XX-GP ES3.1, CPU-OPP2, L3-165MHz, Max CPU Clock 600 mHz OMAP3 Beagle board + LPDDR/NAND I2C: ready DRAM: 256 MiB NAND: 256 MiB MMC: OMAP SD/MMC: 0 *** Warning - bad CRC, using default environment
ERROR : Unsupport USB mode Check that mini-B USB cable is attached to the device In: serial Out: serial Err: serial Beagle Rev C4 No EEPROM on expansion board Die ID #51454d5551454d555400000051454d55 Hit any key to stop autoboot: 0 SD/MMC found on device 0 reading uEnv.txt
** Unable to read "uEnv.txt" from mmc 0:1 ** reading uImage
3106596 bytes read Booting from mmc ... ## Booting kernel from Legacy Image at 82000000 ... Image Name: Linux-3.0.12-yocto-standard+ Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 3106532 Bytes = 3 MiB Load Address: 80008000 Entry Point: 80008000 Verifying Checksum ... OK Loading Kernel Image ... OK OK
Starting kernel ...
Uncompressing Linux... done, booting the kernel. omap2_inth_read: Bad register 0x00000020
Yocto (Built by Poky 6.0) 1.1+snapshot-20120112 beagleboard ttyO2
beagleboard login:
-----------------------------------------------
Does anybody know why these boot messages are not printed on serial in qemu?
@g
On Thu, Jan 12, 2012 at 8:30 AM, Andrei Gherzan andrei@gherzan.ro wrote:
Does anybody know why these boot messages are not printed on serial in qemu?
What are the kernel boot parameters? I.e. if you 'cat /proc/cmdline' after the system is booted, do you see a 'console=ttyO2,115200n8'? Equally, the word 'quiet' shouldn't be included in the boot parameters if you want to see everything.
-Ash
No quiet in it but console is ttyS2. On Jan 12, 2012 7:05 PM, "Ash Charles" ash@gumstix.com wrote:
On Thu, Jan 12, 2012 at 8:30 AM, Andrei Gherzan andrei@gherzan.ro wrote:
Does anybody know why these boot messages are not printed on serial in
qemu? What are the kernel boot parameters? I.e. if you 'cat /proc/cmdline' after the system is booted, do you see a 'console=ttyO2,115200n8'? Equally, the word 'quiet' shouldn't be included in the boot parameters if you want to see everything.
-Ash
Try interrupting u-boot on boot and typing 'setenv console ttyO2,115200n8' then 'boot'
A 'saveenv' would normally make this permanent but I suspect this will fail on qemu (nand flash emulation?) so a boot.scr could do the trick.
-Ash
On Thu, Jan 12, 2012 at 11:20 AM, Andrei Gherzan andrei@gherzan.ro wrote:
No quiet in it but console is ttyS2.
On Jan 12, 2012 7:05 PM, "Ash Charles" ash@gumstix.com wrote:
On Thu, Jan 12, 2012 at 8:30 AM, Andrei Gherzan andrei@gherzan.ro wrote:
Does anybody know why these boot messages are not printed on serial in qemu?
What are the kernel boot parameters? I.e. if you 'cat /proc/cmdline' after the system is booted, do you see a 'console=ttyO2,115200n8'? Equally, the word 'quiet' shouldn't be included in the boot parameters if you want to see everything.
-Ash
On 01/12/2012 09:25 PM, Ash Charles wrote:
Try interrupting u-boot on boot and typing 'setenv console ttyO2,115200n8' then 'boot'
A 'saveenv' would normally make this permanent but I suspect this will fail on qemu (nand flash emulation?) so a boot.scr could do the trick.
-Ash
On Thu, Jan 12, 2012 at 11:20 AM, Andrei Gherzanandrei@gherzan.ro wrote:
No quiet in it but console is ttyS2.
On Jan 12, 2012 7:05 PM, "Ash Charles"ash@gumstix.com wrote:
On Thu, Jan 12, 2012 at 8:30 AM, Andrei Gherzanandrei@gherzan.ro wrote:
Does anybody know why these boot messages are not printed on serial in qemu?
What are the kernel boot parameters? I.e. if you 'cat /proc/cmdline' after the system is booted, do you see a 'console=ttyO2,115200n8'? Equally, the word 'quiet' shouldn't be included in the boot parameters if you want to see everything.
-Ash
This worked for me as well but still these messages are printed only in terminal and not in qemu window. Dunno why...
console=ttyO2,115200n8 mpurate=auto vram=12M omapfb.mode=dvi:1024x768MR-16@60 omapfb.debug=y omapdss.def_disp=dvi root=/dev/mmcblk0p2 rw rootfstype=ext3 rootwait
I just cannot make it (qemu) print all serial messages in in default qemu windows and not in the terminal. If i don't use the argument -serial, i still have to CTRL+3 in the qemu window to see serial messages. Any ideas? How can i have all serial messages in the default qemu window?
@g
On Tue, Jan 17, 2012 at 12:06 AM, Andrei Gherzan andrei@gherzan.ro wrote:
I just cannot make it (qemu) print all serial messages in in default qemu windows and not in the terminal. If i don't use the argument -serial, i still have to CTRL+3 in the qemu window to see serial messages. Any ideas? How can i have all serial messages in the default qemu window?
Did you try using the -serial stdio option when starting the VM, that should help to get the serial console messages.
@g
______________________________**_________________ linaro-dev mailing list linaro-dev@lists.linaro.org http://lists.linaro.org/**mailman/listinfo/linaro-devhttp://lists.linaro.org/mailman/listinfo/linaro-dev
On 01/17/2012 07:41 AM, Deepti Kalakeri wrote:
On Tue, Jan 17, 2012 at 12:06 AM, Andrei Gherzan <andrei@gherzan.ro mailto:andrei@gherzan.ro> wrote:
I just cannot make it (qemu) print all serial messages in in default qemu windows and not in the terminal. If i don't use the argument -serial, i still have to CTRL+3 in the qemu window to see serial messages. Any ideas? How can i have all serial messages in the default qemu window?
Did you try using the -serial stdio option when starting the VM, that should help to get the serial console messages.
This is not what i want to have. I tried this and the serial messages are printed only in terminal and not in qemu window. I want to have these messages in Qemu window as it should.
@g
On 11 January 2012 15:12, Andrei Gherzan andrei@gherzan.ro wrote:
-M vexpress-a9 -hda /home/xxx/work/yyy/yocto/2012-01-08-14-57/tmp/deploy/images/image-qemuarmv7.ext3
vexpress-a9 does not support hard disks, so -hda won't work. Use -drive if=sd,cache=writeback,filename=/path/to/disk.img instead, to set up an SD card image. You'll need to fiddle with the root= kernel parameter too (and make sure your kernel has the relevant drivers).
-cpu cortex-a8
You can't boot a vexpress-a9 board model with a Cortex-A8 CPU, this will not work. Just don't pass any cpu argument.
-m 128
This is a tiny amount of memory, and very few images will boot in it I suspect. -m 1024 is probably more sensible (and adjust the mem= argument to the console).
If you want something that Just Works, you can use the wiki documentation to boot one of the linaro prebuilt images.
-- PMM
On 01/11/2012 05:25 PM, Peter Maydell wrote:
On 11 January 2012 15:12, Andrei Gherzanandrei@gherzan.ro wrote:
-M vexpress-a9 -hda /home/xxx/work/yyy/yocto/2012-01-08-14-57/tmp/deploy/images/image-qemuarmv7.ext3
vexpress-a9 does not support hard disks, so -hda won't work. Use -drive if=sd,cache=writeback,filename=/path/to/disk.img instead, to set up an SD card image. You'll need to fiddle with the root= kernel parameter too (and make sure your kernel has the relevant drivers).
-cpu cortex-a8
You can't boot a vexpress-a9 board model with a Cortex-A8 CPU, this will not work. Just don't pass any cpu argument.
-m 128
This is a tiny amount of memory, and very few images will boot in it I suspect. -m 1024 is probably more sensible (and adjust the mem= argument to the console).
If you want something that Just Works, you can use the wiki documentation to boot one of the linaro prebuilt images.
-- PMM
Thank you very much Peter. What i really need is to compile a kernel by my self, armv7 and boot it in qemu linaro. Don't bother the arguments for now. That was just an example for armv5 modified a little to clearly state my problem. I just need a kernel source and defconfig that can be emulated successfully in Linaro Qemu.