25 |
* SUCH DAMAGE. |
* SUCH DAMAGE. |
26 |
* |
* |
27 |
* |
* |
28 |
* $Id: machine_algor.c,v 1.8 2006/08/14 18:03:12 debug Exp $ |
* $Id: machine_algor.c,v 1.11 2006/09/26 08:49:18 debug Exp $ |
29 |
*/ |
*/ |
30 |
|
|
31 |
#include <stdio.h> |
#include <stdio.h> |
45 |
|
|
46 |
MACHINE_SETUP(algor) |
MACHINE_SETUP(algor) |
47 |
{ |
{ |
48 |
|
machine->emulated_hz = 166560000; |
49 |
|
|
50 |
switch (machine->machine_subtype) { |
switch (machine->machine_subtype) { |
51 |
case MACHINE_ALGOR_P4032: |
case MACHINE_ALGOR_P4032: |
52 |
machine->machine_name = "Algor P4032"; |
machine->machine_name = "Algor P4032"; |
83 |
if (!machine->prom_emulation) |
if (!machine->prom_emulation) |
84 |
return; |
return; |
85 |
|
|
|
/* Magic "reboot" instruction at 0xbfc00000: */ |
|
|
store_32bit_word(cpu, 0xffffffff9fc00000ULL, 0x00c0de0d); |
|
|
|
|
86 |
/* NetBSD/algor wants these: */ |
/* NetBSD/algor wants these: */ |
87 |
|
|
88 |
/* a0 = argc */ |
/* a0 = argc */ |
99 |
store_string(cpu, (int32_t)0x9fc01040, machine->bootstr); |
store_string(cpu, (int32_t)0x9fc01040, machine->bootstr); |
100 |
store_string(cpu, (int32_t)0x9fc01200, machine->bootarg); |
store_string(cpu, (int32_t)0x9fc01200, machine->bootarg); |
101 |
|
|
102 |
/* a2 = (yamon_env_var *)envp */ |
/* a2 = pointer to environment strings */ |
103 |
cpu->cd.mips.gpr[MIPS_GPR_A2] = (int32_t)0x9fc01800; |
cpu->cd.mips.gpr[MIPS_GPR_A2] = (int32_t)0x9fc01800; |
104 |
{ |
{ |
105 |
char tmps[50]; |
char tmps[50]; |