From 5852c1f86529ca6f4055a69d1683f91384fceaed Mon Sep 17 00:00:00 2001 From: Stafford Horne Date: Thu, 10 Feb 2022 06:39:12 +0900 Subject: hw/openrisc/openrisc_sim: Add automatic device tree generation Using the device tree means that qemu can now directly tell the kernel what hardware is configured rather than use having to maintain and update a separate device tree file. This patch adds automatic device tree generation support for the OpenRISC simulator. A device tree is built up based on the state of the configure openrisc simulator. This is then dumped to memory and the load address is passed to the kernel in register r3. Signed-off-by: Stafford Horne Reviewed-by: Peter Maydell --- hw/openrisc/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'hw/openrisc/meson.build') diff --git a/hw/openrisc/meson.build b/hw/openrisc/meson.build index 947f63ee08..ec48172c9d 100644 --- a/hw/openrisc/meson.build +++ b/hw/openrisc/meson.build @@ -1,5 +1,5 @@ openrisc_ss = ss.source_set() openrisc_ss.add(files('cputimer.c')) -openrisc_ss.add(when: 'CONFIG_OR1K_SIM', if_true: files('openrisc_sim.c')) +openrisc_ss.add(when: 'CONFIG_OR1K_SIM', if_true: [files('openrisc_sim.c'), fdt]) hw_arch += {'openrisc': openrisc_ss} -- cgit v1.2.3