Microdroid runs on cuttlefish_x86_64
This CL includes x86_64 specific changes that are required to run
microdroid on cuttlefish_x86_64.
1) Unsigned bootloader is used. (b/185115783)
2) androidboot.boot_devices is correctly set for the architecture
3) uboot-env.txt is customized to set loadaddr
4) MicrodroidTestCase is revised to handle the case when multiple
devices are connected.
Bug: 185115783
Bug: 185082754
Test: atest MicrodroidHostTests with aosp_cf_x86_64_phone
Change-Id: I1baebedd392f742f9a9cd064d63a8c3741e46daa
diff --git a/microdroid/uboot-env-x86_64.txt b/microdroid/uboot-env-x86_64.txt
new file mode 100644
index 0000000..ab0fc26
--- /dev/null
+++ b/microdroid/uboot-env-x86_64.txt
@@ -0,0 +1,13 @@
+# Static u-boot environment variables for microdroid. See b/180481192
+
+# Boot the device following the Android boot procedure
+bootcmd=boot_android virtio 0#misc
+
+bootdelay=0
+
+# U-Boot in x86_64 by defaults loads kernel at 0x20000000 (512MB), which is
+# out of the physical memory when the VM is launched with the default memory
+# size of 256MB. To avoid that, explicitly set the kernel load addresss using
+# loadaddr variable.
+loadaddr=0x02000000
+fdtaddr=0x40000000