From: Mark Cave-Ayland Date: Fri, 24 Jun 2022 16:08:39 +0000 (+0100) Subject: artist: set memory region owners for buffers to the artist device X-Git-Tag: v7.1.0-rc0~50^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=39fbaeca096a9bf6cbe2af88572c1cb2aa62aa8c;p=thirdparty%2Fqemu.git artist: set memory region owners for buffers to the artist device This fixes the output of "info qom-tree" so that the buffers appear as children of the artist device, rather than underneath the "unattached" container. Signed-off-by: Mark Cave-Ayland Message-Id: <20220624160839.886649-1-mark.cave-ayland@ilande.co.uk> Reviewed-by: Helge Deller --- diff --git a/hw/display/artist.c b/hw/display/artist.c index eadaef0d466..fde050c882b 100644 --- a/hw/display/artist.c +++ b/hw/display/artist.c @@ -1358,7 +1358,7 @@ static void artist_create_buffer(ARTISTState *s, const char *name, { struct vram_buffer *buf = s->vram_buffer + idx; - memory_region_init_ram(&buf->mr, NULL, name, width * height, + memory_region_init_ram(&buf->mr, OBJECT(s), name, width * height, &error_fatal); memory_region_add_subregion_overlap(&s->mem_as_root, *offset, &buf->mr, 0);