40 41 42using namespace BigEndianGuest; 43 44SparcSystem::SparcSystem(Params *p) 45 : System(p), sysTick(0),funcRomPort(p->name + "-fromport"), 46 funcNvramPort(p->name + "-fnvramport"), 47 funcHypDescPort(p->name + "-fhypdescport"),
--- 163 unchanged lines hidden (view full) ---
211 resetSymtab->unserialize("reset_symtab", cp, section); 212 hypervisorSymtab->unserialize("hypervisor_symtab", cp, section); 213 openbootSymtab->unserialize("openboot_symtab", cp, section); 214 nvramSymtab->unserialize("nvram_symtab", cp, section); 215 hypervisorDescSymtab->unserialize("hypervisor_desc_symtab", cp, section); 216 partitionDescSymtab->unserialize("partition_desc_symtab", cp, section); 217} 218
|
219
220BEGIN_DECLARE_SIM_OBJECT_PARAMS(SparcSystem)
221
222 SimObjectParam<PhysicalMemory *> physmem;
223 SimObjectParam<PhysicalMemory *> rom;
224 SimObjectParam<PhysicalMemory *> nvram;
225 SimObjectParam<PhysicalMemory *> hypervisor_desc;
226 SimObjectParam<PhysicalMemory *> partition_desc;
227 SimpleEnumParam<System::MemoryMode> mem_mode;
228
229 Param<Addr> reset_addr;
230 Param<Addr> hypervisor_addr;
231 Param<Addr> openboot_addr;
232 Param<Addr> nvram_addr;
233 Param<Addr> hypervisor_desc_addr;
234 Param<Addr> partition_desc_addr;
235
236 Param<std::string> kernel;
237 Param<std::string> reset_bin;
238 Param<std::string> hypervisor_bin;
239 Param<std::string> openboot_bin;
240 Param<std::string> nvram_bin;
241 Param<std::string> hypervisor_desc_bin;
242 Param<std::string> partition_desc_bin;
243
244 Param<Tick> boot_cpu_frequency;
245 Param<std::string> boot_osflags;
246 Param<std::string> readfile;
247 Param<unsigned int> init_param;
248
249END_DECLARE_SIM_OBJECT_PARAMS(SparcSystem)
250
251BEGIN_INIT_SIM_OBJECT_PARAMS(SparcSystem)
252
253 INIT_PARAM(physmem, "phsyical memory"),
254 INIT_PARAM(rom, "ROM for boot code"),
255 INIT_PARAM(nvram, "Non-volatile RAM for the nvram"),
256 INIT_PARAM(hypervisor_desc, "ROM for the hypervisor description"),
257 INIT_PARAM(partition_desc, "ROM for the partition description"),
258 INIT_ENUM_PARAM(mem_mode, "Memory Mode, (1=atomic, 2=timing)",
259 System::MemoryModeStrings),
260
261 INIT_PARAM(reset_addr, "Address that reset should be loaded at"),
262 INIT_PARAM(hypervisor_addr, "Address that hypervisor should be loaded at"),
263 INIT_PARAM(openboot_addr, "Address that openboot should be loaded at"),
264 INIT_PARAM(nvram_addr, "Address that nvram should be loaded at"),
265 INIT_PARAM(hypervisor_desc_addr,
266 "Address that hypervisor description should be loaded at"),
267 INIT_PARAM(partition_desc_addr,
268 "Address that partition description should be loaded at"),
269
270 INIT_PARAM(kernel, "file that contains the kernel code"),
271 INIT_PARAM(reset_bin, "file that contains the reset code"),
272 INIT_PARAM(hypervisor_bin, "file that contains the hypervisor code"),
273 INIT_PARAM(openboot_bin, "file that contains the openboot code"),
274 INIT_PARAM(nvram_bin, "file that contains the nvram image"),
275 INIT_PARAM(hypervisor_desc_bin,
276 "file that contains the hypervisor description image"),
277 INIT_PARAM(partition_desc_bin,
278 "file that contains the partition description image"),
279 INIT_PARAM(boot_cpu_frequency, "Frequency of the boot CPU"),
280 INIT_PARAM_DFLT(boot_osflags, "flags to pass to the kernel during boot",
281 "a"),
282 INIT_PARAM_DFLT(readfile, "file to read startup script from", ""),
283 INIT_PARAM_DFLT(init_param, "numerical value to pass into simulator", 0)
284
285END_INIT_SIM_OBJECT_PARAMS(SparcSystem)
286
287CREATE_SIM_OBJECT(SparcSystem)
|