diff options
author | Markus Armbruster <armbru@redhat.com> | 2020-07-07 18:05:52 +0200 |
---|---|---|
committer | Markus Armbruster <armbru@redhat.com> | 2020-07-10 15:18:08 +0200 |
commit | 4d21fcd52404ff4bac1f94d8054dfb745f1b2ad6 (patch) | |
tree | 922e22ed49a401848d10392a832e474e16fc60bc /hw/usb/hcd-dwc2.c | |
parent | 552d7f49eebdb1c84ab6dc7d93bd152fd885af31 (diff) |
qom: Don't handle impossible object_property_get_link() failure
Don't handle object_property_get_link() failure that can't happen
unless the programmer screwed up, pass &error_abort.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20200707160613.848843-25-armbru@redhat.com>
Diffstat (limited to 'hw/usb/hcd-dwc2.c')
-rw-r--r-- | hw/usb/hcd-dwc2.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/hw/usb/hcd-dwc2.c b/hw/usb/hcd-dwc2.c index 72cbd051f3..56f91f6bee 100644 --- a/hw/usb/hcd-dwc2.c +++ b/hw/usb/hcd-dwc2.c @@ -1274,15 +1274,8 @@ static void dwc2_realize(DeviceState *dev, Error **errp) SysBusDevice *sbd = SYS_BUS_DEVICE(dev); DWC2State *s = DWC2_USB(dev); Object *obj; - Error *err = NULL; - obj = object_property_get_link(OBJECT(dev), "dma-mr", &err); - if (err) { - error_setg(errp, "dwc2: required dma-mr link not found: %s", - error_get_pretty(err)); - return; - } - assert(obj != NULL); + obj = object_property_get_link(OBJECT(dev), "dma-mr", &error_abort); s->dma_mr = MEMORY_REGION(obj); address_space_init(&s->dma_as, s->dma_mr, "dwc2"); |