Lines Matching +full:pc +full:- +full:bios

31 #include "exec/address-spaces.h"
34 #include "hw/char/serial-mm.h"
41 #include "hw/qdev-properties.h"
42 #include "qemu/error-report.h"
98 initrd_offset, loaderparams.ram_size - initrd_offset); in load_kernel()
100 if (initrd_size == (target_ulong) -1) { in load_kernel()
112 CPUMIPSState *env = &s->cpu->env; in main_cpu_reset()
114 cpu_reset(CPU(s->cpu)); in main_cpu_reset()
115 env->active_tc.PC = s->vector & ~(target_ulong)1; in main_cpu_reset()
116 if (s->vector & 1) { in main_cpu_reset()
117 env->hflags |= MIPS_HFLAG_M16; in main_cpu_reset()
142 const char *kernel_filename = machine->kernel_filename; in mips_mipssim_init()
143 const char *kernel_cmdline = machine->kernel_cmdline; in mips_mipssim_init()
144 const char *initrd_filename = machine->initrd_filename; in mips_mipssim_init()
148 MemoryRegion *bios = g_new(MemoryRegion, 1); in mips_mipssim_init() local
155 cpuclk = clock_new(OBJECT(machine), "cpu-refclk"); in mips_mipssim_init()
163 cpu = mips_cpu_create_with_clock(machine->cpu_type, cpuclk, in mips_mipssim_init()
165 env = &cpu->env; in mips_mipssim_init()
168 reset_info->cpu = cpu; in mips_mipssim_init()
169 reset_info->vector = env->active_tc.PC; in mips_mipssim_init()
173 memory_region_init_rom(bios, NULL, "mips_mipssim.bios", BIOS_SIZE, in mips_mipssim_init()
176 memory_region_add_subregion(address_space_mem, 0, machine->ram); in mips_mipssim_init()
178 /* Map the BIOS / boot exception handler. */ in mips_mipssim_init()
179 memory_region_add_subregion(address_space_mem, 0x1fc00000LL, bios); in mips_mipssim_init()
180 /* Load a BIOS / boot exception handler image. */ in mips_mipssim_init()
181 filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, machine->firmware ?: BIOS_FILENAME); in mips_mipssim_init()
186 bios_size = -1; in mips_mipssim_init()
189 machine->firmware && !qtest_enabled()) { in mips_mipssim_init()
191 error_report("Could not load MIPS bios '%s'", machine->firmware); in mips_mipssim_init()
195 env->active_tc.PC = (target_long)(int32_t)0xbfc00000; in mips_mipssim_init()
199 loaderparams.ram_size = machine->ram_size; in mips_mipssim_init()
203 reset_info->vector = load_kernel(); in mips_mipssim_init()
212 * (except for the hardcoded serial port interrupt) -device cannot work, in mips_mipssim_init()
230 sysbus_connect_irq(SYS_BUS_DEVICE(dev), 0, env->irq[4]); in mips_mipssim_init()
236 mipsnet_init(0x4200, env->irq[2]); in mips_mipssim_init()
241 mc->desc = "MIPS MIPSsim platform"; in mips_mipssim_machine_init()
242 mc->init = mips_mipssim_init; in mips_mipssim_machine_init()
244 mc->default_cpu_type = MIPS_CPU_TYPE_NAME("5Kf"); in mips_mipssim_machine_init()
246 mc->default_cpu_type = MIPS_CPU_TYPE_NAME("24Kf"); in mips_mipssim_machine_init()
248 mc->default_ram_id = "mips_mipssim.ram"; in mips_mipssim_machine_init()