summaryrefslogtreecommitdiff
path: root/include/configs/qemu-x86.h
diff options
context:
space:
mode:
authorJoshua Watt <jpewhacker@gmail.com>2019-07-03 12:45:32 -0500
committerBin Meng <bmeng.cn@gmail.com>2019-08-09 22:24:02 +0800
commit00f237e226bc8a6ecf168ca0d2e1853f203f17d1 (patch)
tree52e6e8ccb99785049bb792d422762f8885736210 /include/configs/qemu-x86.h
parent42ef7079224abc7c6073c0bab63f3aa6fffd5d00 (diff)
qemu-x86: Use config_distro_bootcmd
Converts qemu x86 machines to boot using distro_config. The intent is to allow u-boot in qemu to be maximally compatible with many boot methods without having to change the config. Previously, u-boot would only boot in a very limited set of circumstances where there was a /boot/vmlinuz on scsi 0:3 with no ramdisk. Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> [bmeng: convert doc updates to reST] Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'include/configs/qemu-x86.h')
-rw-r--r--include/configs/qemu-x86.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/include/configs/qemu-x86.h b/include/configs/qemu-x86.h
index 64e7a60b8a..097ed414f8 100644
--- a/include/configs/qemu-x86.h
+++ b/include/configs/qemu-x86.h
@@ -10,8 +10,33 @@
#ifndef __CONFIG_H
#define __CONFIG_H
+#include <linux/sizes.h>
+
+#define BOOT_TARGET_DEVICES(func) \
+ func(USB, usb, 0) \
+ func(SCSI, scsi, 0) \
+ func(VIRTIO, virtio, 0) \
+ func(IDE, ide, 0) \
+ func(DHCP, dhcp, na)
+
+#include <config_distro_bootcmd.h>
#include <configs/x86-common.h>
+#undef CONFIG_ENV_SIZE
+#define CONFIG_ENV_SIZE SZ_256K
+
+#define CONFIG_PREBOOT "pci enum"
+
+#undef CONFIG_EXTRA_ENV_SETTINGS
+#define CONFIG_EXTRA_ENV_SETTINGS \
+ CONFIG_STD_DEVICES_SETTINGS \
+ "scriptaddr=0x7000000\0" \
+ "kernel_addr_r=0x1000000\0" \
+ "ramdisk_addr_r=0x4000000\0" \
+ "consoledev=ttyS0\0" \
+ CONFIG_OTHBOOTARGS \
+ BOOTENV
+
#define CONFIG_SYS_MONITOR_LEN (1 << 20)
#define CONFIG_STD_DEVICES_SETTINGS "stdin=serial,i8042-kbd\0" \