summaryrefslogtreecommitdiffstats
path: root/include/hw
diff options
context:
space:
mode:
authorLaurent Vivier2019-12-19 21:14:39 +0100
committerLaurent Vivier2020-01-07 13:35:53 +0100
commiteb064db94ccd62f054019f41fb8be3f268463a13 (patch)
tree1d0fe04ce2fb0dea2eb6a25962a48aef09df8f05 /include/hw
parentq800: fix mac_via RTC PRAM commands (diff)
downloadqemu-eb064db94ccd62f054019f41fb8be3f268463a13.tar.gz
qemu-eb064db94ccd62f054019f41fb8be3f268463a13.tar.xz
qemu-eb064db94ccd62f054019f41fb8be3f268463a13.zip
q800: add a block backend to the PRAM
This allows to save and restore the content of the PRAM. It may be useful if we want to check the configuration or to change it. The backend is added using mtd interface, for instance: ... -drive file=pram.img,format=raw,if=mtd ... where pram.img is the file where the data will be stored, its size must be 256 bytes. Signed-off-by: Laurent Vivier <laurent@vivier.eu> Message-Id: <20191219201439.84804-3-laurent@vivier.eu>
Diffstat (limited to 'include/hw')
-rw-r--r--include/hw/misc/mac_via.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/hw/misc/mac_via.h b/include/hw/misc/mac_via.h
index 3f86fcb7e1..e74f85be0f 100644
--- a/include/hw/misc/mac_via.h
+++ b/include/hw/misc/mac_via.h
@@ -81,6 +81,8 @@ typedef struct MOS6522Q800VIA2State {
typedef struct MacVIAState {
SysBusDevice busdev;
+ VMChangeStateEntry *vmstate;
+
/* MMIO */
MemoryRegion mmio;
MemoryRegion via1mem;
@@ -100,6 +102,7 @@ typedef struct MacVIAState {
uint8_t cmd;
int wprotect;
int alt;
+ BlockBackend *blk;
/* ADB */
ADBBusState adb_bus;