diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2017-10-05 15:31:06 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2017-10-05 15:31:06 +0100 |
commit | f43a46f0f43db5449a14813fab521590a8103ce4 (patch) | |
tree | bc395903954fee3f226ae4a5ede6d75bb904e60d | |
parent | 1fdc4c5d82a6a4b327776f10ad435eb8bdd70089 (diff) | |
parent | eea6ae20379dca837631d603c3bed03e5128189f (diff) |
Merge remote-tracking branch 'remotes/kraxel/tags/usb-20171005-pull-request' into staging
usb bugfixes.
# gpg: Signature made Thu 05 Oct 2017 10:04:15 BST
# gpg: using RSA key 0x4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>"
# gpg: aka "Gerd Hoffmann <gerd@kraxel.org>"
# gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>"
# Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138
* remotes/kraxel/tags/usb-20171005-pull-request:
usb: fix host-stub.c build race
usb: Use angle brackets for cacard include directive
usb: fix libusb config variable name.
hw/usb/bus: Remove bad object_unparent() from usb_try_create_simple()
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r-- | hw/usb/Makefile.objs | 3 | ||||
-rw-r--r-- | hw/usb/bus.c | 4 | ||||
-rw-r--r-- | hw/usb/ccid-card-passthru.c | 2 |
3 files changed, 4 insertions, 5 deletions
diff --git a/hw/usb/Makefile.objs b/hw/usb/Makefile.objs index 9255234c63..bdfead6701 100644 --- a/hw/usb/Makefile.objs +++ b/hw/usb/Makefile.objs @@ -42,11 +42,12 @@ redirect.o-cflags = $(USB_REDIR_CFLAGS) redirect.o-libs = $(USB_REDIR_LIBS) # usb pass-through -ifeq ($(CONFIG_LIBUSB)$(CONFIG_USB),yy) +ifeq ($(CONFIG_USB_LIBUSB)$(CONFIG_USB),yy) common-obj-y += host-libusb.o host-legacy.o else common-obj-y += host-stub.o endif +common-obj-$(CONFIG_ALL) += host-stub.o host-libusb.o-cflags := $(LIBUSB_CFLAGS) host-libusb.o-libs := $(LIBUSB_LIBS) diff --git a/hw/usb/bus.c b/hw/usb/bus.c index d910f849e7..e56dc3348a 100644 --- a/hw/usb/bus.c +++ b/hw/usb/bus.c @@ -341,9 +341,7 @@ static USBDevice *usb_try_create_simple(USBBus *bus, const char *name, object_property_set_bool(OBJECT(dev), true, "realized", &err); if (err) { error_propagate(errp, err); - error_prepend(errp, "Failed to initialize USB device '%s': ", - name); - object_unparent(OBJECT(dev)); + error_prepend(errp, "Failed to initialize USB device '%s': ", name); return NULL; } return dev; diff --git a/hw/usb/ccid-card-passthru.c b/hw/usb/ccid-card-passthru.c index 45d96b03c6..117711862e 100644 --- a/hw/usb/ccid-card-passthru.c +++ b/hw/usb/ccid-card-passthru.c @@ -9,11 +9,11 @@ */ #include "qemu/osdep.h" +#include <cacard/vscard_common.h> #include "chardev/char-fe.h" #include "qemu/error-report.h" #include "qemu/sockets.h" #include "ccid.h" -#include "cacard/vscard_common.h" #define DPRINTF(card, lvl, fmt, ...) \ do { \ |