From 575264e9083bd839ce6ce265fd606c44135799c3 Mon Sep 17 00:00:00 2001 From: Akihiko Odaki Date: Mon, 27 Oct 2025 10:05:38 +0900 Subject: [PATCH] nw/nvram/ds1225y: Fix nvram MemoryRegion owner MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit s points to the MemoryRegion itself. dev points to DS1225Y, the real owner. Signed-off-by: Akihiko Odaki Reviewed-by: Philippe Mathieu-Daudé Message-ID: <20251027-ds1225y-v1-1-406888eb495f@rsg.ci.i.u-tokyo.ac.jp> Signed-off-by: Philippe Mathieu-Daudé --- hw/nvram/ds1225y.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/nvram/ds1225y.c b/hw/nvram/ds1225y.c index dbfd0d2e53..0945e36652 100644 --- a/hw/nvram/ds1225y.c +++ b/hw/nvram/ds1225y.c @@ -126,7 +126,7 @@ static void nvram_sysbus_realize(DeviceState *dev, Error **errp) s->contents = g_malloc0(s->chip_size); - memory_region_init_io(&s->iomem, OBJECT(s), &nvram_ops, s, + memory_region_init_io(&s->iomem, OBJECT(dev), &nvram_ops, s, "nvram", s->chip_size); sysbus_init_mmio(SYS_BUS_DEVICE(dev), &s->iomem);