usb: usb_create() can't fail, drop useless error handling

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
Markus Armbruster 2015-02-04 13:28:08 +01:00 committed by Gerd Hoffmann
parent cd2d554127
commit 4806ec9b2c
5 changed files with 1 additions and 18 deletions

View file

@ -530,14 +530,10 @@ static USBDevice *usb_bt_init(USBBus *bus, const char *cmdline)
} else {
hci = bt_new_hci(qemu_find_bt_vlan(0));
}
if (!hci)
return NULL;
dev = usb_create(bus, name);
if (!dev) {
error_report("Failed to create USB device '%s'", name);
return NULL;
}
s = DO_UPCAST(struct USBBtState, dev, dev);
s->hci = hci;
if (qdev_init(&dev->qdev) < 0) {