Hello to everybody. I'm trying to virtualize Linaro-Android 4 with qemu-linaro on two different kind of machines :
1) Pandaboard ES running Ubuntu with this kernel :
Linux arm 3.7.2-x6 #1 SMP Sat Jan 12 07:16:37 UTC 2013 armv7l armv7l armv7l GNU/Linux
2) Samsung XE303C12-A01US Chromebook running CHR Ubuntu with this kernel :
Linux localhost.localdomain 3.4.0-5-chromebook #5-Ubuntu SMP Fri Feb 8 14:54:53 UTC 2013 armv7l armv7l armv7l GNU/Linux
To accomplish the goal I made the experiments with two versions of qemu-linaro :
1) qemu-linaro-1.3.0-2012.12
2) qemu-linaro 1.4 from the GIT rep
In both cases I configured qemu-linaro with these parameters :
--disable-kvm --disable-tcg-interpreter --enable-curses --enable-sdl --enable-vnc --disable-debug-tcg --enable-vhost-net
I tried to follow two different kind of tutorials :
On the TUTORIAL n. 1:
1) Created a small test program, test.c, with the basic “Hello world”:
#include<stdio.h>
int main(){
printf("Welcome to Open World\n");
}
# gcc test.c -o test
2) Built the Linux kernel for ARM
# tar -jxvf linux-2.6.37.tar.bz2 (but I tried with a lot of other kernel versions)
# cd linux-2.6.37
# make menuconfig ARCH=arm
# make ARCH=arm uImage -s
# qemu-system-arm -M versatilepb -m 128M -kernel /home/user/Desktop/linux-2.6.37/arch/arm/boot/uImage
RESULT = black screen inside the qemu-linaro window without error messages
3) Developed a dummy filesystem (hello.c) for testing
#include<stdio.h>
int main(){
while(1){
printf("Hello Open World\n");
getchar();
}
}
# gcc hello.c -static -o hello
4) Created a root filesystem
# echo hello | cpio -o --format=newc > rootfs
5) Testing :
qemu-system-arm -M versatilepb -m 128M -kernel /home/user/Desktop/
linux-2.6.37/arch/arm/boot/uImage -initrd rootfs -append "root=/dev/ram rdinit=/hello"
RESULT = black screen inside the qemu-linaro window without error messages
On the TUTORIAL n. 2 :
1) Patched :
qemu-linaro-1.3.0-2012.12
with :
sed -i "s/#define INITRD_LOAD_ADDR 0x00d00000/#define INITRD_LOAD_ADDR 0x01d00000/" qemu-linaro-1.3.0-2012.12/hw/arm_boot.c
and also qemu-linaro 1.4 from the GIT rep
with the same patch:
sed -i "s/#define INITRD_LOAD_ADDR 0x00d00000/#define INITRD_LOAD_ADDR 0x01d00000/" qemu-linaro/hw/arm_boot.c
gunzip vexpress-ics-gcc47-armlt-tracking-open.img.gz
sudo kpartx -a vexpress-ics-gcc47-armlt-tracking-open.img
sudo mount /dev/mapper/loop0p1 /mnt -o loop,ro
cp /mnt/uImage /mnt/uInitrd .
sudo umount /mnt
sudo kpartx -d /dev/mapper/loop0p*
dd if=uImage of=vmlinuz skip=64 bs=1
dd if=uInitrd of=initrd.gz skip=64 bs=1
3) Tried to boot Linaro Android 12.05 using qemu-linaro-1.3.0-2012.12 and also qemu-linaro 1.4 from the GIT rep
on the Pandaboard ES with this :
qemu-system-arm -M vexpress-a9 -m 1024 -smp 1 -snapshot -serial stdio -no-reboot -kernel vmlinuz -initrd initrd.gz -drive file=vexpress-ics-gcc47-armlt-tracking-open.img,if=sd,cache=writeback --append "console=tty0 console=ttyAMA0,38400n8 rootwait ro init=/init androidboot.console=ttyAMA0"
and on the Samsung XE303C12-A01US Chromebook with this :
qemu-system-arm -M vexpress-a15 -cpu-cortex-a15 -m 1024 -smp 1 -snapshot -serial stdio -no-reboot -kernel vmlinuz -initrd initrd.gz -drive file=vexpress-ics-gcc47-armlt-tracking-open.img,if=sd,cache=writeback --append "console=tty0 console=ttyAMA0,38400n8 rootwait ro init=/init androidboot.console=ttyAMA0"
I've also tried wth :
qemu-system-arm -M vexpress-a15 -cpu cortex-a15 -m 1024 -smp 1 -snapshot -serial stdio -no-reboot -kernel uImage -initrd uInitrd -drive file=vexpress-ics-gcc47-armlt-tracking-open.img,if=sd,cache=writeback --append "console=tty0 console=ttyAMA0,38400n8 rootwait ro init=/init androidboot.console=ttyAMA0"
Also tried with different kind of combinations,like :
-M versatilepb ; -M vexpress-a9 ; -cpu cortex-a9 ; -m 512 ;
but the RESULT is still the smae = black screen inside the qemu-linaro window without error messages. Any help ?
Instead,debian_lenny_armel_desktop is virtualized very well with qemu-linaro following this procedure :
a) wget vmlinuz-2.6.32-5-versatile,initrd.img-2.6.32-5-versatile and debian_lenny_armel_desktop from here :
b) tried to virtualize debian_lenny_armel_desktop with :
qemu-system-arm -M versatilepb -kernel vmlinuz-2.6.32-5-versatile -initrd initrd.img-2.6.32-5-versatile -hda debian_lenny_armel_desktop.qcow2 -append "root=/dev/sda1"
and it works....
--
Mario.