mirror of
https://github.com/pevans/erc-c.git
synced 2024-08-20 09:29:01 +00:00
Remove peripheral rom init
This commit is contained in:
parent
ac39349344
commit
2db5c791ba
@ -62,7 +62,6 @@
|
|||||||
|
|
||||||
extern SEGMENT_READER(apple2_mem_zp_read);
|
extern SEGMENT_READER(apple2_mem_zp_read);
|
||||||
extern SEGMENT_WRITER(apple2_mem_zp_write);
|
extern SEGMENT_WRITER(apple2_mem_zp_write);
|
||||||
extern int apple2_mem_init_peripheral_rom(apple2 *);
|
|
||||||
extern int apple2_mem_init_sys_rom(apple2 *);
|
extern int apple2_mem_init_sys_rom(apple2 *);
|
||||||
extern void apple2_mem_map(apple2 *, vm_segment *);
|
extern void apple2_mem_map(apple2 *, vm_segment *);
|
||||||
|
|
||||||
|
@ -87,12 +87,6 @@ apple2_create(int width, int height)
|
|||||||
apple2_mem_map(mach, mach->main);
|
apple2_mem_map(mach, mach->main);
|
||||||
apple2_mem_map(mach, mach->aux);
|
apple2_mem_map(mach, mach->aux);
|
||||||
|
|
||||||
if (apple2_mem_init_peripheral_rom(mach) != OK) {
|
|
||||||
log_critical("Could not initialize disk2 ROM");
|
|
||||||
apple2_free(mach);
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (apple2_mem_init_sys_rom(mach) != OK) {
|
if (apple2_mem_init_sys_rom(mach) != OK) {
|
||||||
log_critical("Could not initialize apple2 ROM");
|
log_critical("Could not initialize apple2 ROM");
|
||||||
apple2_free(mach);
|
apple2_free(mach);
|
||||||
|
@ -35,28 +35,6 @@ apple2_mem_map(apple2 *mach, vm_segment *segment)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Initialize the peripheral ROM ($C100 - $C7FF).
|
|
||||||
*/
|
|
||||||
int
|
|
||||||
apple2_mem_init_peripheral_rom(apple2 *mach)
|
|
||||||
{
|
|
||||||
int err;
|
|
||||||
|
|
||||||
// Let's copy beginning at the 1-slot offset in memory, but going
|
|
||||||
// all the way as far as the length of all peripheral ROM in memory.
|
|
||||||
err = vm_segment_copy_buf(mach->main,
|
|
||||||
objstore_apple2_peripheral_rom(),
|
|
||||||
APPLE2_PERIPHERAL_SLOT(1), 0,
|
|
||||||
APPLE2_PERIPHERAL_SIZE);
|
|
||||||
if (err != OK) {
|
|
||||||
log_critical("Could not copy apple2 peripheral rom");
|
|
||||||
return ERR_BADFILE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return OK;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* I'm still a bit hazy on how this _should_ work, but this function
|
* I'm still a bit hazy on how this _should_ work, but this function
|
||||||
* will copy as much as we can from the system rom into both main memory
|
* will copy as much as we can from the system rom into both main memory
|
||||||
|
Loading…
Reference in New Issue
Block a user