25 |
* SUCH DAMAGE. |
* SUCH DAMAGE. |
26 |
* |
* |
27 |
* |
* |
28 |
* $Id: dev_prep.c,v 1.10 2007/02/11 10:03:55 debug Exp $ |
* $Id: dev_prep.c,v 1.11 2007/06/15 19:57:33 debug Exp $ |
29 |
* |
* |
30 |
* PReP mainbus. |
* COMMENT: PReP machine mainbus (ISA bus + interrupt controller) |
|
* |
|
|
* o) ISA bus |
|
|
* o) Interrupt controller |
|
31 |
*/ |
*/ |
32 |
|
|
33 |
#include <stdio.h> |
#include <stdio.h> |
72 |
{ |
{ |
73 |
struct prep_data *d; |
struct prep_data *d; |
74 |
|
|
75 |
d = malloc(sizeof(struct prep_data)); |
CHECK_ALLOCATION(d = malloc(sizeof(struct prep_data))); |
|
if (d == NULL) { |
|
|
fprintf(stderr, "out of memory\n"); |
|
|
exit(1); |
|
|
} |
|
76 |
memset(d, 0, sizeof(struct prep_data)); |
memset(d, 0, sizeof(struct prep_data)); |
77 |
|
|
78 |
memory_device_register(devinit->machine->memory, devinit->name, |
memory_device_register(devinit->machine->memory, devinit->name, |