File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 12
12
#include "qemu/log.h"
13
13
#include "qemu/error-report.h"
14
14
#include "qapi/error.h"
15
+ #include "qemu-common.h"
15
16
#include "hw/hw.h"
16
17
#include "hw/boards.h"
17
18
#include "hw/loader.h"
@@ -474,6 +475,16 @@ static void esp32_soc_init(Object *obj)
474
475
qdev_init_gpio_in_named (DEVICE (s ), esp32_cpu_reset , ESP32_RTC_CPU_RESET_GPIO , ESP32_CPU_COUNT );
475
476
qdev_init_gpio_in_named (DEVICE (s ), esp32_cpu_stall , ESP32_RTC_CPU_STALL_GPIO , ESP32_CPU_COUNT );
476
477
qdev_init_gpio_in_named (DEVICE (s ), esp32_clk_update , ESP32_RTC_CLK_UPDATE_GPIO , 1 );
478
+
479
+ const char * rom_filename = "rom.bin" ;
480
+
481
+ rom_filename = qemu_find_file (QEMU_FILE_TYPE_BIOS , rom_filename );
482
+ if (!rom_filename ||
483
+ load_image_targphys (rom_filename , 0x40000000 , 794624 /*412384*/ ) < 0 ) {
484
+ error_report ("unable to load ROM image '%s'\n" , rom_filename );
485
+ exit (EXIT_FAILURE );
486
+ }
487
+
477
488
}
478
489
479
490
static Property esp32_soc_properties [] = {
You can’t perform that action at this time.
0 commit comments