Make AddressSpaces QOM objects to ensure that they are destroyed when their owners are finalized and also to get a unique path for debugging output.
The name arguments were used to distinguish AddresSpaces in debugging output, but they will represent property names after QOM-ification and debugging output will show QOM paths. So change them to make them more concise and also avoid conflicts with other properties. Signed-off-by: Akihiko Odaki <od...@rsg.ci.i.u-tokyo.ac.jp> --- hw/usb/hcd-dwc2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/usb/hcd-dwc2.c b/hw/usb/hcd-dwc2.c index 8aaa696dd4de..156cfb4263e3 100644 --- a/hw/usb/hcd-dwc2.c +++ b/hw/usb/hcd-dwc2.c @@ -1351,7 +1351,7 @@ static void dwc2_realize(DeviceState *dev, Error **errp) obj = object_property_get_link(OBJECT(dev), "dma-mr", &error_abort); s->dma_mr = MEMORY_REGION(obj); - address_space_init(&s->dma_as, NULL, s->dma_mr, "dwc2"); + address_space_init(&s->dma_as, OBJECT(s), s->dma_mr, "as"); usb_bus_new(&s->bus, sizeof(s->bus), &dwc2_bus_ops, dev); usb_register_port(&s->bus, &s->uport, s, 0, &dwc2_port_ops, -- 2.51.0