Usb 20170913 patches
[Qemu-devel] [PULL 1/4] xhci: Avoid DMA when ERSTBA is set to zero
In reply to Gerd HoffmannFrom: Alexey Kardashevskiy <[email protected]>
The existing XHCI code reads the Event Ring Segment Table Base Address Register (ERSTBA) every time when it is changed. However zero is its default state so one would think that zero there means it is not in use.
This adds a check for ERSTBA in addition to the existing check for the Event Ring Segment Table Size Register (ERSTSZ).
Message-id: [email protected]
--- hw/usb/hcd-xhci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
hw/usb/hcd-xhci.c +2 -2
@@ -811,8 +811,9 @@ static void xhci_er_reset(XHCIState *xhci, int v) {XHCIInterrupter *intr = &xhci->intr[v];XHCIEvRingSeg seg; +dma_addr_t erstba =xhci_addr64 (intr->erstba_low, intr->erstba_high); -if (intr->erstsz ==0 ) { +if (intr->erstsz ==0 || erstba ==0 ) {/* disabled */ intr->er_start =0 ; intr->er_size =0 ;
@@ -824,7 +825,6 @@ static void xhci_er_reset(XHCIState *xhci, int v)xhci_die (xhci);return ; } -dma_addr_t erstba =xhci_addr64 (intr->erstba_low, intr->erstba_high);pci_dma_read (PCI_DEVICE (xhci), erstba, &seg,sizeof (seg));le32_to_cpus (&seg.addr_low);le32_to_cpus (&seg.addr_high);
Signature · 1 line
2.9.3
[Qemu-devel] [PULL 2/4] MAINTAINERS: add missing USB entry
In reply to Gerd HoffmannFrom: Philippe Mathieu-Daudé <[email protected]>
--- MAINTAINERS | 1 + 1 file changed, 1 insertion(+)
MAINTAINERS +1 -0
@@ -999,6 +999,7 @@ F: docs/usb2.txt F: docs/usb-storage.txt F: include/hw/usb.h F: include/hw/usb/ +F: default-configs/usb.mak USB (serial adapter) M: Gerd Hoffmann <[email protected]>
Signature · 1 line
2.9.3
[Qemu-devel] [PULL 4/4] usb: only build usb-host with CONFIG_USB=y
In reply to Gerd HoffmannMessage-id: [email protected]
--- hw/usb/Makefile.objs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
hw/usb/Makefile.objs +1 -1
@@ -38,7 +38,7 @@ endif common-obj-$(CONFIG_USB_REDIR) += redirect.o quirks.o # usb pass-through -ifeq ($(CONFIG_LIBUSB),y) +ifeq ($(CONFIG_LIBUSB)$(CONFIG_USB),yy) common-obj-y += host-libusb.o host-legacy.o else common-obj-y += host-stub.o
Signature · 1 line
2.9.3
The following changes since commit 619c200f6ce2f44fbc8a5732174530c3b4782aab:
Merge remote-tracking branch 'remotes/mcayland/tags/qemu-openbios-signed' into staging (2017-09-11 11:44:30 +0100)
are available in the git repository at:
git://git.kraxel.org/qemu tags/usb-20170913-pull-request
for you to fetch changes up to 2041649f0b04f61869589571ddf5ecd4f0695ea2:
usb: only build usb-host with CONFIG_USB=y (2017-09-13 10:44:49 +0200)
----------------------------------------------------------------
usb: misc small fixes.
----------------------------------------------------------------
Alexey Kardashevskiy (1):
xhci: Avoid DMA when ERSTBA is set to zero
Gerd Hoffmann (2):
usb: drop HOST_USB
usb: only build usb-host with CONFIG_USB=y
Philippe Mathieu-Daudé (1):
MAINTAINERS: add missing USB entry
configure | 7 ------- hw/usb/hcd-xhci.c | 4 ++-- MAINTAINERS | 1 + hw/usb/Makefile.objs | 6 +++++- 4 files changed, 8 insertions(+), 10 deletions(-)
Signature · 1 line
2.9.3
[Qemu-devel] [PULL 3/4] usb: drop HOST_USB
Nowdays we use libusb for usb-host, so we don't have different code for linux vs. bsd any more. So there is little reason to have the HOST_USB variable, we can just write things directly into the Makefile and avoid a pointless indirection.
Message-id: [email protected]
--- configure | 7 ------- hw/usb/Makefile.objs | 6 +++++- 2 files changed, 5 insertions(+), 8 deletions(-)
configure +0 -7
@@ -5967,13 +5967,6 @@ if test "$live_block_migration" = "yes" ; then echo "CONFIG_LIVE_BLOCK_MIGRATION=y" >> $config_host_mak fi -# USB host support -if test "$libusb" = "yes"; then - echo "HOST_USB=libusb legacy" >> $config_host_mak -else - echo "HOST_USB=stub" >> $config_host_mak -fi - # TPM passthrough support? if test "$tpm" = "yes"; then echo 'CONFIG_TPM=$(CONFIG_SOFTMMU)' >> $config_host_mak
hw/usb/Makefile.objs +5 -1
@@ -38,7 +38,11 @@ endif common-obj-$(CONFIG_USB_REDIR) += redirect.o quirks.o # usb pass-through -common-obj-y += $(patsubst %,host-%.o,$(HOST_USB)) +ifeq ($(CONFIG_LIBUSB),y) +common-obj-y += host-libusb.o host-legacy.o +else +common-obj-y += host-stub.o +endif ifeq ($(CONFIG_USB_LIBUSB),y) common-obj-$(CONFIG_XEN) += xen-usb.o
Signature · 1 line
2.9.3
Peter Maydell
AppliedQuoted 6 lines · Gerd Hoffmann
The following changes since commit
619c200f6ce2f44fbc8a5732174530c3b4782aab:Merge remote-tracking branch 'remotes/mcayland/tags/qemu-openbios-signed' into staging (2017-09-11 11:44:30 +0100)
are available in the git repository at:
Quoted 9 lines
git://git.kraxel.org/qemutags/usb-20170913-pull-requestfor you to fetch changes up to
2041649f0b04f61869589571ddf5ecd4f0695ea2:usb: only build usb-host with
CONFIG_USB=y(2017-09-13 10:44:49 +0200)----------------------------------------------------------------
usb: misc small fixes.
Applied, thanks.
-- PMM