summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/cpu/jaguar
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2008-04-11 05:41:46 +0000
committer Aaron Giles <aaron@aarongiles.com>2008-04-11 05:41:46 +0000
commitdbb98c547380ba8c6148f9f49b9bbb81a15d89e5 (patch)
tree325ff3b39776788b20e5a6d02c0428524b1152c3 /src/emu/cpu/jaguar
parent6331c8d69950041543552fc528018a373e1091ae (diff)
Reduced the number of save state callback types from 3 to 1. The
only remaining form is the one that takes a pointer parameter. Added macros for STATE_PRESAVE and STATE_POSTLOAD to define common functions. Added machine parameter to these functions. Updated all drivers and CPU/sound cores to use the new macros and consolidate on the single function type. As a result pushed the machine parameter through a few initialization stacks. Removed unnecessary postload callbacks which only marked all tiles dirty, since this is done automatically by the tilemap engine.
Diffstat (limited to 'src/emu/cpu/jaguar')
-rw-r--r--src/emu/cpu/jaguar/jaguar.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/emu/cpu/jaguar/jaguar.c b/src/emu/cpu/jaguar/jaguar.c
index badf0ff9f71..e525a996aaf 100644
--- a/src/emu/cpu/jaguar/jaguar.c
+++ b/src/emu/cpu/jaguar/jaguar.c
@@ -415,14 +415,19 @@ static void init_tables(void)
}
}
+static STATE_POSTLOAD( jaguar_postload )
+{
+ update_register_banks();
+ check_irqs();
+}
+
static void jaguar_state_register(int index, const char *type)
{
state_save_register_item_array(type, index, jaguar.r);
state_save_register_item_array(type, index, jaguar.a);
state_save_register_item_array(type, index, jaguar.ctrl);
state_save_register_item(type, index, jaguar.ppc);
- state_save_register_func_postload(update_register_banks);
- state_save_register_func_postload(check_irqs);
+ state_save_register_postload(Machine, jaguar_postload, NULL);
}
static void jaguargpu_init(int index, int clock, const void *_config, int (*irqcallback)(int))