aboutsummaryrefslogtreecommitdiff
path: root/hw/onenand.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/onenand.c')
-rw-r--r--hw/onenand.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/onenand.c b/hw/onenand.c
index a9d8d677ee..33c9718629 100644
--- a/hw/onenand.c
+++ b/hw/onenand.c
@@ -781,7 +781,8 @@ static int onenand_initfn(SysBusDevice *dev)
}
s->otp = memset(g_malloc((64 + 2) << PAGE_SHIFT),
0xff, (64 + 2) << PAGE_SHIFT);
- memory_region_init_ram(&s->ram, NULL, "onenand.ram", 0xc000 << s->shift);
+ memory_region_init_ram(&s->ram, "onenand.ram", 0xc000 << s->shift);
+ vmstate_register_ram_global(&s->ram);
ram = memory_region_get_ram_ptr(&s->ram);
s->boot[0] = ram + (0x0000 << s->shift);
s->boot[1] = ram + (0x8000 << s->shift);