From: Akihiko Odaki Date: Mon, 27 Oct 2025 01:05:38 +0000 (+0900) Subject: nw/nvram/ds1225y: Fix nvram MemoryRegion owner X-Git-Tag: v10.2.0-rc1~41^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=575264e9083bd839ce6ce265fd606c44135799c3;p=thirdparty%2Fqemu.git nw/nvram/ds1225y: Fix nvram MemoryRegion owner 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é --- 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);