From 67cf94be9efc94cd72b5133cf899e3e929365a23 Mon Sep 17 00:00:00 2001 From: Ted Green Date: Wed, 3 May 2017 16:52:23 -0600 Subject: [PATCH] pci9050: More save state work. (nw) --- src/devices/machine/pci9050.cpp | 9 +++++++++ src/devices/machine/pci9050.h | 2 ++ 2 files changed, 11 insertions(+) diff --git a/src/devices/machine/pci9050.cpp b/src/devices/machine/pci9050.cpp index e21055ca3ba..643d8702451 100644 --- a/src/devices/machine/pci9050.cpp +++ b/src/devices/machine/pci9050.cpp @@ -82,9 +82,18 @@ void pci9050_device::device_start() save_item(NAME(m_erombrd)); save_item(NAME(m_intcsr)); save_item(NAME(m_cntrl)); + machine().save().register_postload(save_prepost_delegate(FUNC(pci9050_device::postload), this)); } +void pci9050_device::postload(void) +{ + remap_rom(); + for (int id = 0; id < 4; id++) + remap_local(id); + remap_cb(); +} + void pci9050_device::device_reset() { pci_device::device_reset(); diff --git a/src/devices/machine/pci9050.h b/src/devices/machine/pci9050.h index a1dd3667f10..cb6e07106d9 100644 --- a/src/devices/machine/pci9050.h +++ b/src/devices/machine/pci9050.h @@ -60,6 +60,8 @@ protected: virtual void device_start() override; virtual void device_reset() override; + void postload(void); + private: DECLARE_ADDRESS_MAP(map, 32); DECLARE_ADDRESS_MAP(empty, 32);