[KVM-ARM] Question of installation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ehh, this error I cannot really understand.

First, your should know that we're aggressively targeting ARMv6 and have a
stable environment based on the ARM Fast models. We are also close to having
something running on ARMv6 hardware. Therefore, the emulator-based version
that you're trying is already kind of legacy and I won't spend much time on
it.

That said, I recommend you try the following:

Forget about building the entire Android environment. Just pick the Android
1.6 SDK and use the emulator/disk images from there. You may want to hack
the ramdisk.img file (just a gzipped cpio archive) so that your environment
doesn't load the entire android system (leaving you with very little memory
left) and perhaps also adds a path to busybox utilities, use a better shell
than the built-in android one etc.

The compile the android-goldfish-2.6.27-kvm-upstream_qemu kernel and use
that with the emulator.

Subsequently compile the armkvm-upstream branch of QEMU. (Actually, using
the wrong branch of QEMU may give you the error below). Also compile the
guest kernel. Move the binaries of QEMU and the guest kernel along with the
initrd file system image inside the emulator and try again.

If you are interested, there is a person (Yifan Zhang) trying to setup an
ARMv6 based QEMU emulation environment for the work. It may be a better
solution to talk to him and try to wrap that up (shouldn't be too difficult)
and run the latest ARMv6 sources on such a platform.

Let me know if I can somehow help any further.

FYI: I've cc'ed this mail to the mailing list so other people interested in
a good QEMU emulation environment can pitch in. Unfortunately I don't have
time to fix such an environment right now, as I am focused on real hardware
support.

-Christoffer

On Wed, Oct 27, 2010 at 12:26 PM, Jui-Hao Chiang <juihaochiang at gmail.com>wrote:

> Sorry that I made a mistake, the android platform must be build.
> But after booting the guest, I got the following error
>
> <3>kvm_arch_vm_ioctl: Unsupported ioctl (1075359296)
> <7>    switching vectors from handle_shadow_perm
> <7>       switched to low vectors
> <7>    Privileged mode cannot access vector page.  Guest must be broken or
> we have a bug!
>
> I wander which step I did wrong.
>
> Thanks,
> Jui-Hao
>
>
> ---------- Forwarded message ----------
> From: Jui-Hao Chiang <j-chiang at cs.sunysb.edu>
> Date: Wed, Oct 27, 2010 at 11:02 AM
> Subject: [KVM-ARM] Question of installation
> To: cdall at cs.columbia.edu
>
>
> Hi, Christoffer:
>
> This is Jui-Hao Chiang, phd student from Stony Brook University.
> I am currently installing the kvm-arm based on your wiki tutorial but got
> some problem
> The exact steps are as the following, and the problem happens at my step 8
> (make Android system) and 10 (booting the emulator).
> Of course the adb can't find connected device later on.
>
> Appreciate any help, and we all think this is a pretty cool project, and
> want to try it out.
>
> Many Thanks,
> Jui-Hao
>
>
> My Installation steps
>  Based on
> https://wiki.ncl.cs.columbia.edu/wiki/AndroidVirt:Guides:Development_Environment#Repositories
>
>    1. Get Android SDK Release 1.0 r2 from
>    http://developer.android.com/sdk/older_releases.html
>    2. Install Sourcery G++ (Installer but not TAR package) from
>    http://www.codesourcery.com/sgpp/lite/arm/portal/package6490/public/arm-none-linux-gnueabi/arm-2010q1-202-arm-none-linux-gnueabi.bin
>    3. Clone all sources (under ~/kvmarm/) with ?git clone git://
>    git.ncl.cs.columbia.edu/pub/git/? including
>       1. linux-kvm-arm: A standard Linux kernel tree with a KVM branch
>       from v2.6.27
>       2. linux-android-common: The common Android kernel tree with a KVM
>       branch based on linux-kvm-arm
>       3. linux-android-msm: The MSM processer version of the Android
>       kernel tree with a KVM branch based on linux-kvm-arm
>       4. linux-guest: A standard Linux kernel tree with
>       lightweight-paravirtualization patches on the v2.6.17-lpv branch
>       5. qemu: A standard QEMU tree with KVM for ARM patches
>       6. android-extra: Other scripts, tools and binaries useful for
>       developers on this project
>    4. cd linux-android-common; git checkout -b
>    android-goldfish-2.6.27-kvm-upstream_qemu --track
>    origin/android-goldfish-2.6.27-kvm-upstream_qemu (instead of
>    android-goldfish-2.6.27-kvm)
>       1. follow the recommandation from
>       https://lists.cs.columbia.edu/pipermail/android-virt/2010-September/000151.html
>    5. ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- make
>    goldfish_defconfig
>    6. ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- make menuconfig
>    7. ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- make zImage
>    8. Now compile the complete Android system (cd android; make) (does
>    this refer to Android SDK 1.0 r2? the android SDK does not contain Makefile)
>    9. Add the android-extra/scripts (see #Repositories) directory to your
>    path and edit a few of the files:
>       1. Modify the android-extra/scripts/configure-qemu.sh to match with
>       your paths for the kernel and the zlib. (You can find the zlib in
>       android-extra/bin).
>       2. Modify the android-extra/scripts/android-emulator.sh and
>       android-emulator-monitor.sh scripts to point to the right locations. Note
>       the the paths beginning with ~/src/android is the android directory from
>       above and the paths beginning with ~/sdk must point to a downloaded version
>       of the Android 1.0 SDK (not a newer version).
>    10. run emulator (android-emulator.sh) full_log
>
>
>    - ### WARNING: Another emulator is running with our data file
>       - ### WARNING: User data changes will NOT be saved!
>       - Uncompressing
>       Linux.........................................................................................
>       done, booting the kernel.
>       - Linux version 2.6.27-00113-g85b5289 (windtracekimo at Wine-desktop)
>       (gcc version 4.4.1 (Sourcery G++ Lite 2010q1-202) ) #1 Tue Oct 26 19:35:21
>       CST 2010
>       - CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00003137
>       - Machine: Goldfish
>       - Memory policy: ECC disabled, Data cache writeback
>       - CPU0: D VIVT write-through cache
>       - CPU0: I cache: 4096 bytes, associativity 4, 32 byte lines, 32 sets
>       - CPU0: D cache: 65536 bytes, associativity 4, 32 byte lines, 512
>       sets
>       - Built 1 zonelists in Zone order, mobility grouping on.  Total
>       pages: 24384
>       - Kernel command line: qemu=1 console=ttyS0 android.checkjni=1
>       android.qemud=ttyS1 android.ndns=2
>       - Unknown boot option `android.checkjni=1': ignoring
>       - Unknown boot option `android.qemud=ttyS1': ignoring
>       - Unknown boot option `android.ndns=2': ignoring
>       - PID hash table entries: 512 (order: 9, 2048 bytes)
>       - Console: colour dummy device 80x30
>       - Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
>       - Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
>       - Memory: 96MB = 96MB total
>       - Memory: 93924KB available (2528K code, 642K data, 100K init)
>       - Calibrating delay loop... 1045.29 BogoMIPS (lpj=5226496)
>       - Mount-cache hash table entries: 512
>       - CPU: Testing write buffer coherency: ok
>       - net_namespace: 288 bytes
>       - NET: Registered protocol family 16
>       - NET: Registered protocol family 2
>       - IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
>       - TCP established hash table entries: 4096 (order: 3, 32768 bytes)
>       - TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
>       - TCP: Hash tables configured (established 4096 bind 4096)
>       - TCP reno registered
>       - NET: Registered protocol family 1
>       - checking if image is initramfs... it is
>       - Freeing initrd memory: 133K
>       - goldfish_new_pdev goldfish_interrupt_controller at ff000000 irq -1
>       - goldfish_new_pdev goldfish_device_bus at ff001000 irq 1
>       - goldfish_new_pdev goldfish_timer at ff003000 irq 3
>       - goldfish_new_pdev goldfish_rtc at ff010000 irq 10
>       - goldfish_new_pdev goldfish_tty at ff002000 irq 4
>       - goldfish_new_pdev goldfish_tty at ff011000 irq 11
>       - goldfish_new_pdev smc91x at ff012000 irq 12
>       - goldfish_new_pdev goldfish_fb at ff013000 irq 13
>       - goldfish_new_pdev goldfish_audio at ff004000 irq 14
>       - goldfish_new_pdev goldfish_memlog at ff006000 irq -1
>       - goldfish_new_pdev goldfish-battery at ff014000 irq 15
>       - goldfish_new_pdev goldfish_events at ff015000 irq 16
>       - goldfish_new_pdev goldfish_nand at ff016000 irq -1
>       - goldfish_new_pdev goldfish-switch at ff017000 irq 17
>       - goldfish_new_pdev goldfish-switch at ff018000 irq 18
>       - ashmem: initialized
>       - Installing knfsd (copyright (C) 1996 okir at monad.swb.de).
>       - yaffs Oct 26 2010 19:33:45 Installing.
>       - msgmni has been set to 183
>       - io scheduler noop registered
>       - io scheduler anticipatory registered (default)
>       - io scheduler deadline registered
>       - io scheduler cfq registered
>       - goldfish_pdev_worker registered goldfish-switch
>       - goldfish_pdev_worker registered goldfish-switch
>       - goldfish_pdev_worker registered goldfish_nand
>       - goldfish_pdev_worker registered goldfish_events
>       - goldfish_pdev_worker registered goldfish-battery
>       - goldfish_pdev_worker registered goldfish_memlog
>       - goldfish_audio_probe
>       - goldfish_pdev_worker registered goldfish_audio
>       - goldfish_pdev_worker registered goldfish_fb
>       - goldfish_pdev_worker registered smc91x
>       - goldfish_pdev_worker registered goldfish_tty
>       - goldfish_pdev_worker registered goldfish_tty
>       - goldfish_pdev_worker registered goldfish_rtc
>       - goldfish_pdev_worker registered goldfish_timer
>       - goldfish_pdev_worker registered goldfish_device_bus
>       - goldfish_pdev_worker registered goldfish_interrupt_controller
>       - allocating frame buffer 320 * 480, got ffc10000
>       - Console: switching to colour frame buffer device 40x30
>       - console [ttyS0] enabled
>       - brd: module loaded
>       - loop: module loaded
>       - nbd: registered device at major 43
>       - logger: created 64K log 'log_main'
>       - logger: created 256K log 'log_events'
>       - logger: created 64K log 'log_radio'
>       - smc91x.c: v1.1, sep 22 2004 by Nicolas Pitre <nico at cam.org>
>       - No set_type function for IRQ 12 (goldfish)
>       - eth0: SMC91C11xFD (rev 1) at c6800000 IRQ 12 [nowait]
>       - eth0: Ethernet addr: 52:54:00:12:34:56
>       - goldfish nand dev0: size 4000000, page 2048, extra 64, erase
>       131072
>       - goldfish nand dev1: size 4000000, page 2048, extra 64, erase
>       131072
>       - goldfish nand dev2: size 4000000, page 2048, extra 64, erase
>       131072
>       - mice: PS/2 mouse device common for all mice
>       - *** events probe ***
>       - events_probe() addr=0xc6804000 irq=16
>       - events_probe() keymap=qwerty2
>       - input: qwerty2 as /devices/virtual/input/input0
>       - goldfish_rtc goldfish_rtc: rtc core: registered goldfish_rtc as
>       rtc0
>       - IPv4 over IPv4 tunneling driver
>       - GRE over IPv4 tunneling driver
>       - TCP cubic registered
>       - NET: Registered protocol family 17
>       - RPC: Registered udp transport module.
>       - RPC: Registered tcp transport module.
>       - 802.1Q VLAN Support v1.8 Ben Greear <greearb at candelatech.com>
>       - All bugs added by David S. Miller <davem at redhat.com>
>       - VFP support v0.3: implementor 41 architecture 1 part 10 variant 9
>       rev 0
>       - goldfish_rtc goldfish_rtc: setting system clock to 2010-10-27
>       02:45:53 UTC (1288147553)
>       - Freeing init memory: 100K
>       - init: cannot open '/initlogo.rle'
>       - init: Unable to open persistent property directory /data/property
>       errno: 2
>       - init: cannot find '/system/bin/sh', disabling 'console'
>       - init: cannot find '/system/bin/servicemanager', disabling
>       'servicemanager'
>       - init: cannot find '/system/bin/mountd', disabling 'mountd'
>       - init: cannot find '/system/bin/debuggerd', disabling 'debuggerd'
>       - init: cannot find '/system/bin/rild', disabling 'ril-daemon'
>       - init: cannot find '/system/bin/app_process', disabling 'zygote'
>       - init: cannot find '/system/bin/mediaserver', disabling 'media'
>       - init: cannot find '/system/bin/playmp3', disabling 'bootsound'
>       - init: cannot find '/system/bin/dbus-daemon', disabling 'dbus'
>       - init: cannot find '/system/bin/installd', disabling 'installd'
>       - init: cannot find '/system/bin/flash_image', disabling
>       'flash_recovery'
>       - init: cannot find '/system/etc/init.goldfish.sh', disabling
>       'goldfish-setup'
>       - init: cannot find '/system/bin/qemud', disabling 'qemud'
>       - init: cannot find '/system/bin/logcat', disabling
>       'goldfish-logcat'
>
>
>    1. export
>    PATH=$PATH:~/CodeSourcery/Sourcery_G++_Lite/bin/:~/kvmarm/android-extra/scripts/:~/android-sdk-linux_x86-1.0_r2/tools/
>
>    2. Once the Android build is complete, run the emulator on our own
>    custom kernel (I recommend using the -no-window option to see all of the
>    debug output from the android kernel): run android-emulator.sh
>    3. Configure and compile the QEMU/KVM userspace that will run inside
>    the simulator:
>
>
> $ cd qemu # (see #Repositories)
>
> $ git checkout -b armkvm --track origin/armkvm
>
> $ configure-qemu.sh # should be in your path from android-extra
>
> $ make
>
>    1. After qemu is built, we have to put qemu ?inside? the emulator's
>    filesystem:
>
>
> $ adb push arm-softmmu/qemu-system-arm /data/. (adb fork-server server will
> be run     automatically, but got an error ==> error: device not found)
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.cs.columbia.edu/pipermail/android-virt/attachments/20101027/33c45449/attachment-0001.html


[Index of Archives]     [Linux KVM]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux