Hi all, I want to run Android using Genode foc on Pandaboard referencing to "http://sourceforge.net/p/genode/mailman/message/30642833/"
Now, I compile and get a image. When I run the image, I only get a black window with a penguin on it.
This my operation: 1) Format my SD card to 3 partitions. 2) Copy the system-ginger.img via "dd" to the second partition: sudo dd if=system-ginger of=/dev/sdb2 bs=1M 3) Build the image using the run script blew 4) Copy the image to the first partition of the SD card
This is my run script:
# # Build #
if {[have_spec foc] == 0} { puts "Runs on Fiasco.OC only" exit 0 }
# generic components set build_components { core init drivers/timer drivers/framebuffer drivers/sd_card drivers/usb drivers/gpio server/nitpicker server/nit_fb server/nic_bridge server/part_blk server/terminal server/terminal_log l4android }
build $build_components create_boot_directory
# # Config #
set config { <config prio_levels="2"> <parent-provides> <service name="ROM"/> <service name="RAM"/> <service name="IRQ"/> <service name="IO_MEM"/> <service name="IO_PORT"/> <service name="CAP"/> <service name="PD"/> <service name="RM"/> <service name="CPU"/> <service name="LOG"/> <service name="SIGNAL"/> </parent-provides> <default-route> <any-service> <parent/> <any-child/> </any-service> </default-route> <start name="timer"> <resource name="RAM" quantum="1M"/> <provides><service name="Timer"/></provides> </start> <start name="fb_drv"> <binary name="fb_drv"/> <resource name="RAM" quantum="4M"/> <provides><service name="Framebuffer"/></provides> </start> <start name="sd_card_drv"> <resource name="RAM" quantum="4M"/> <provides><service name="Block"/></provides> </start> <start name="gpio_drv"> <resource name="RAM" quantum="4M"/> <provides><service name="Gpio"/></provides> <config/> </start> <start name="usb_drv"> <resource name="RAM" quantum="12M"/> <provides> <service name="Input"/> <service name="Nic"/> </provides> <config ehci="yes"> <hid/> <nic mac="2e:60:90:0c:4e:01" /> </config> </start> <start name="part_blk"> <resource name="RAM" quantum="2M"/> <provides><service name="Block"/></provides> <config> <policy label="l4android -> sda" partition="3" /> </config> <route> <service name="Block"> <child name="sd_card_drv"/> </service> <any-service> <parent/> <any-child/> </any-service> </route> </start> <start name="nic_bridge" priority="-1"> <resource name="RAM" quantum="2M"/> <provides><service name="Nic"/></provides> <route> <service name="Nic"> <child name="usb_drv"/> </service> <any-service> <parent/> <any-child/> </any-service> </route> </start> <start name="nitpicker"> <resource name="RAM" quantum="2M"/> <provides><service name="Nitpicker"/></provides> <route> <service name="Input"> <child name="usb_drv"/> </service> <service name="Framebuffer"> <child name="fb_drv"/> </service> <any-service> <parent/> <any-child/> </any-service> </route> </start> <start name="android_fb"> <binary name="nit_fb"/> <resource name="RAM" quantum="4M"/> <provides> <service name="Framebuffer"/> <service name="Input"/> </provides> <config xpos="0" ypos="0" width="640" height="480"/> </start> <start name="l4android"> <resource name="RAM" quantum="512M"/> <config args="mem=128M console=ttyS0 l4x_rd=root-ginger.gz"> <block label="sda"/> </config> <route> <service name="Input"> <child name="android_fb"/> </service> <service name="Framebuffer"> <child name="android_fb"/> </service> <service name="Block"> <child name="part_blk"/> </service> <service name="Nic"> <child name="nic_bridge"/> </service> <any-service> <parent/> <any-child/> </any-service> </route> </start> </config>}
install_config $config
# # Boot modules #
set boot_modules { core init timer nitpicker nit_fb nic_bridge terminal terminal_log fb_drv part_blk sd_card_drv gpio_drv usb_drv l4android root-ginger.gz ld.lib.so }
lappend_if [have_spec x86] boot_modules nic_drv lappend_if [have_spec x86] boot_modules atapi_drv lappend_if [have_spec pci] boot_modules pci_drv lappend_if [have_spec ps2] boot_modules ps2_drv lappend_if [have_spec pl11x] boot_modules pl11x_drv lappend_if [have_spec lan9118] boot_modules nic_drv lappend_if [have_spec pl180] boot_modules sd_card_drv lappend_if [have_spec vesa] boot_modules vesa_drv
if {[have_spec x86]} { set initrd_uri "http://genode.org/files/release-11.11/l4lx/root-ia32-ginger.gz" set system_uri "http://genode.org/files/release-11.11/l4lx/system-ia32-ginger.img" } elseif {[have_spec arm]} { set initrd_uri "http://genode.org/files/release-11.11/l4lx/root-arm-ginger.gz" set system_uri "http://genode.org/files/release-11.11/l4lx/system-arm-ginger.img" } if {![file exists bin/root-ginger.gz]} { puts "Download initramfs ..." exec curl $initrd_uri > bin/root-ginger.gz 2> /dev/null } if {![file exists bin/system-ginger.img]} { puts "Download system image ..." exec curl $system_uri > bin/system-ginger.img 2> /dev/null }
build_boot_image [join $boot_modules " "]
append qemu_args " -m 512 " append qemu_args " -serial mon:stdio " append_if [have_spec x86] qemu_args " -hda bin/system-ginger.img " append_if [have_spec x86] qemu_args " -net nic,model=e1000 " append_if [have_spec pl180] qemu_args " -drive file=bin/system-ginger.img,if=sd,cache=writeback " append_if [have_spec lan9118] qemu_args " -net nic,model=lan9118 " append qemu_args " -net user -redir tcp:5555::5555 " run_genode_until forever ---------------------------------------------------------------------
This is the log: ... Genode 14.11 int main(): --- create local services --- int main(): --- start init --- int main(): transferred 997 MB to init int main(): --- init created, waiting for exit condition --- Quota exceeded! amount=28672, size=4096, consumed=28672 [init] upgrading quota donation for Env::CPU (8192 bytes) [init -> gpio_drv] --- omap4 gpio driver --- Insufficient quota for transfer: init -> part_blk have 1564672, need 4206592 [init] not enough quota for a donation of 4206592 bytes [init -> part_blk] resource_request: ram_quota=4206592 [init -> part_blk] virtual void Genode::Platform_env::release(): used before freeing emergency=290816 [init -> part_blk] virtual void Genode::Platform_env::release(): used after freeing emergency=286720 [init] child "part_blk" requests resources: ram_quota=4206592 [init -> fb_drv] Could not open file "config" [init -> fb_drv] Could not obtain config file [init -> sd_card_drv] --- OMAP4 SD card driver --- [init -> fb_drv] int main(int, char**): using default configuration: HDMI@...311... [init -> gpio_drv] No GPIO config [init -> l4android] Booting L4Linux ... [init -> usb_drv] Services::Services(): Could not read screen resolution in config node [init -> usb_drv] Services::Services(): No <storage> config node found - not starting the USB Storage (Block) service [init -> usb_drv] Services::Services(): No <raw> config node found - not starting external USB service [init -> usb_drv] Enabled EHCI (USB 2.0) support [init -> l4android] ======> L4Linux starting... <======== [init -> l4android] Linux version 3.5.0-l4-gcea6e7a (czzcz@...306...) (gcc version 4.7.4 (GCC) ) #18 SMP Thu Mar 12 10:52:16 CST 2015 [init -> l4android] Binary name: vmlinux [init -> l4android] This is an AEABI build. [init -> l4android] Linux kernel command line (3 args): mem=128M console=ttyS0 l4x_rd=root-ginger.gz [init -> l4android] CPU mapping (l:p)[0]: Image: 01000000 - 01400000 [4096 KiB] [init -> l4android] Areas: Text: 01000000 - 0135e000 [3448kB] [init -> l4android] Data: 0135e000 - 0138b1b8 [180kB] [init -> l4android] Initdata: 01337000 - 0135c4c0 [149kB] [init -> l4android] BSS: 0138c000 - 013c96e8 [245kB] [init -> usb_drv] Using configured mac: 2e:60:90:0c:4e:01 [init -> l4android] l4io_get_root_device: Not implemented yet! [init -> l4android] Device scan: [init -> sd_card_drv] CID: 0x97009861 0x38caa862 0x44303847 0x02544d53 [init -> l4android] l4io_iterate_devices: Not implemented yet! [init -> sd_card_drv] RCA: 0x895a [init -> l4android] Device scan done. [init -> usb_drv] void platform_hcd_init(Services*): register platform device [init -> sd_card_drv] SD card detected [init -> sd_card_drv] capacity: 7600 MiB [init -> usb_drv] dev_info: EHCI Host Controller [init -> usb_drv] dev_info: new USB bus registered, assigned bus number 1 [init -> part_blk] Partition 1: LBA 63 (144522 blocks) type: c [init -> part_blk] Partition 2: LBA 144585 (15149295 blocks) type: c [init -> part_blk] Partition 3: LBA 15293880 (257040 blocks) type: c [init -> usb_drv] dev_info: irq 109, io mem 0x4a064c00 [init -> l4android] main thread will be c [init -> l4android] l4x_register_pointer_section: addr = 01000000 size = 4194304 [init -> l4android] section-with-init: virt: 1000000 to 13fffff [4096 KiB] [init -> l4android] Cannot determine physical address for dataspace Binary! [init -> l4android] error: failed to get physical address for 1000000. [init -> l4android] Main thread running, waiting... [init -> l4android] thread=c000 cpu=0 [init -> l4android] l4x_setup_memory: Forcing superpages for main memory [init -> l4android] l4re_global_env: 0 [init -> l4android] Main memory size: 128MB unmapping of managed dataspaces not yet supported [init -> l4android] Main memory: virt: 8000000 to fffffff [131072 KiB] [init -> l4android] Main memory: Phys: 0x00000000 to 0x08000000, Size: 134217728 [init -> l4android] Filling lower ptabs... [init -> l4android] Done (0 entries). [init -> l4android] l4x_register_pointer_section: addr = 01000000 size = 4194304 [init -> l4android] text: virt: 1000000 to 13fffff [4096 KiB] [init -> l4android] Cannot determine physical address for dataspace Binary! [init -> l4android] error: failed to get physical address for 1000000. [init -> usb_drv] dev_info: USB 2.0 started, EHCI 1.00 [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 1000000 [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 1336fcb [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 135e000 [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 13c96e7 [init -> usb_drv] dev_info: USB hub found [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 1000000 [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 13fffff [init -> l4android] l4x_rd_path: root-ginger.gz [init -> usb_drv] dev_info: 3 ports detected [init -> l4android] Loading: root-ginger.gz [init -> l4android] INITRD: Size of RAMdisk is 224KiB [init -> l4android] RAMdisk from 00005000 to 0003d000 [224KiB] [init -> l4android] l4timer: Using IRQ210 [init -> nitpicker] Could not open file "config" [init -> nitpicker] Could not obtain config file [init] l4android: no route to service "Terminal" [init -> nitpicker] create session with args: label="android_fb", ram_quota=28672 [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 12359a0 [init -> l4android] l4x_virt_to_phys: Could not translate virt. address 12359a0 [init -> l4android] l4io_get_root_device: Not implemented yet! [init -> l4android] l4io_iterate_devices: Not implemented yet! [init -> usb_drv] dev_info: new high-speed USB device number 2 using ehci-omap [init -> android_fb] using xywh=(0,0,640,480) [init -> nic_bridge] Could not open file "config" [init -> nic_bridge] Could not obtain config file Insufficient quota for transfer: init -> nic_bridge have 1564672, need 3301376 [init] not enough quota for a donation of 3301376 bytes [init -> nic_bridge] resource_request: ram_quota=3301376 [init -> nic_bridge] virtual void Genode::Platform_env::release(): used before freeing emergency=278528 [init -> nic_bridge] virtual void Genode::Platform_env::release(): used after freeing emergency=274432 [init] child "nic_bridge" requests resources: ram_quota=3301376 [init -> usb_drv] dev_info: USB hub found [init -> usb_drv] dev_info: 5 ports detected [init -> nic_bridge] Invalid session request, no matching policy [init -> usb_drv] dev_info: new high-speed USB device number 3 using ehci-omap [init -> usb_drv] Using configured mac: 2e:60:90:0c:4e:01 [init -> usb_drv] netif_info: open: enable queueing (rx 4, tx 60) mtu 1500 simple framing [init -> usb_drv] nedev_info: hardware isn't capable of remote wakeup [init -> usb_drv] netif_info: register 'smsc95xx' at usb-ehci-omap-1.1, smsc95xx USB 2.0 Ethernet, 10c4e04M ------------------------------------------------------------------ so, 1)Is there anything wrong with my run script? What should I do to make Android run perfectly on pandaboard? 2)Is "ld.lib.so" necessary? The run script of longjks include the component, but I can't compile it successfully using this script.
Best, Zachary
I add the kdb_uart to the image, and I get more information:
... [init -> nic_bridge] virtual void Genode::Platform_env::release(): used before freeing emergency=278528 Console: switching to colour frame buffer device 8[init -> usb_drv] dev_info: new high-speed USB device0 input: Genode input key as /devices/virtual/input/input0
input: Genode input mouse as /devices/virtual/input/input1
ehci-omap
sda: unknown partition table
Genode blk-file driver initialized
[init -> nic_bridge] virtual void Genode::Platform_env::release(): used after freeing emergency=274432 [init] child "nic_bridge" requests resources: ram_quota=3301376
[init -> nic_bridge] Invalid session request, no matching policy
TCP: cubic registered
NET: Registered protocol family 17
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
rtc-genode rtc-genode.0: setting system clock to 1970-01-01 00:00:01 UTC (1)
ALSA device list:
#0: Dummy 1
[init -> usb_drv] __wait_completion_timeout(): Timeout
[init -> usb_drv] dev_error: device descriptor read/all, error -30
[init -> usb_drv] dev_info: new high-speed USB device number 4 using ehci-omap [init -> usb_drv] __wait_completion_timeout(): Timeout
[init -> usb_drv] __wait_completion_timeout(): Timeout
[init -> usb_drv] dev_error: cannot reset port 1 (err = -30) ...
I compare it to long's log, I find the correct log would be: [init -> l4android] [32mupgrading quota donation for SIGNAL session[0m sda: unknown partition table Genode blk-file driver initialized [init -> usb_drv] dev_info: OMAP-EHCI Host Controller [init -> usb_drv] dev_info: new USB bus registered, assigned bus number 1 [34mQuota exceeded! amount=4096, size=4096, consumed=4096[0m [init -> usb_drv] [32mupgrading quota donation for SIGNAL session[0m [init -> usb_drv] dev_info: irq 109, io mem 0x4a064c00 [init -> usb_drv] dev_info: USB 2.0 started, EHCI 1.00 [init -> usb_drv] dev_info: New USB device found, idVendor=1d6b, idProduct=0002 [init -> usb_drv] dev_info: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [init -> usb_drv] dev_info: USB hub found [init -> usb_drv] dev_info: 3 ports detected [init -> usb_drv] dev_info: new high-speed USB device number 2 using ehci-omap [init -> usb_drv] dev_info: New USB device found, idVendor=0424, idProduct=9514 [init -> usb_drv] dev_info: New USB device strings: Mfr=0, Product=0, SerialNumber=0 [init -> usb_drv] dev_info: USB hub found