All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] usb-serial: wakeup device on input
@ 2020-03-06 14:09 Jason Andryuk
  2020-03-06 16:13 ` no-reply
  2020-03-09 10:08 ` Gerd Hoffmann
  0 siblings, 2 replies; 5+ messages in thread
From: Jason Andryuk @ 2020-03-06 14:09 UTC (permalink / raw)
  To: Gerd Hoffmann, Samuel Thibault; +Cc: qemu-devel, Jason Andryuk

Currently usb-serial devices are unable to send data into guests with
the xhci controller.  Data is copied into the usb-serial's buffer, but
it is not sent into the guest.  Data coming out of the guest works
properly.  usb-serial devices work properly with ehci.

Have usb-serial call usb_wakeup() when receiving data from the chardev.
This seems to notify the xhci controller and fix inbound data flow.

Also add USB_CFG_ATT_WAKEUP to the device's bmAttributes.  This matches
a real FTDI serial adapter's bmAttributes.

Signed-off-by: Jason Andryuk <jandryuk@gmail.com>

---
Other devices added USB_CFG_ATT_WAKEUP which is why it is repeated here.
Inbound data flow works without it, but it seems like USB_CFG_ATT_WAKEUP
should be set when using usb_wakeup.
---
 hw/usb/dev-serial.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
index 98465990ef..daac75b7ae 100644
--- a/hw/usb/dev-serial.c
+++ b/hw/usb/dev-serial.c
@@ -98,6 +98,7 @@ do { printf("usb-serial: " fmt , ## __VA_ARGS__); } while (0)
 
 typedef struct {
     USBDevice dev;
+    USBEndpoint *intr;
     uint8_t recv_buf[RECV_BUF];
     uint16_t recv_ptr;
     uint16_t recv_used;
@@ -153,7 +154,7 @@ static const USBDescDevice desc_device = {
         {
             .bNumInterfaces        = 1,
             .bConfigurationValue   = 1,
-            .bmAttributes          = USB_CFG_ATT_ONE,
+            .bmAttributes          = USB_CFG_ATT_ONE | USB_CFG_ATT_WAKEUP,
             .bMaxPower             = 50,
             .nif = 1,
             .ifs = &desc_iface0,
@@ -459,6 +460,8 @@ static void usb_serial_read(void *opaque, const uint8_t *buf, int size)
         memcpy(s->recv_buf + start, buf, size);
     }
     s->recv_used += size;
+
+    usb_wakeup(s->intr, 0);
 }
 
 static void usb_serial_event(void *opaque, QEMUChrEvent event)
@@ -513,6 +516,7 @@ static void usb_serial_realize(USBDevice *dev, Error **errp)
     if (qemu_chr_fe_backend_open(&s->cs) && !dev->attached) {
         usb_device_attach(dev, &error_abort);
     }
+    s->intr = usb_ep_get(dev, USB_TOKEN_IN, 1);
 }
 
 static USBDevice *usb_braille_init(USBBus *bus, const char *unused)
-- 
2.24.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb-serial: wakeup device on input
  2020-03-06 14:09 [PATCH] usb-serial: wakeup device on input Jason Andryuk
@ 2020-03-06 16:13 ` no-reply
  2020-03-06 17:33   ` Jason Andryuk
  2020-03-09 10:08 ` Gerd Hoffmann
  1 sibling, 1 reply; 5+ messages in thread
From: no-reply @ 2020-03-06 16:13 UTC (permalink / raw)
  To: jandryuk; +Cc: samuel.thibault, jandryuk, kraxel, qemu-devel

Patchew URL: https://patchew.org/QEMU/20200306140917.26726-1-jandryuk@gmail.com/



Hi,

This series failed the docker-clang@ubuntu build test. Please find the testing commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.

=== TEST SCRIPT BEGIN ===
#!/bin/bash
make docker-image-ubuntu V=1 NETWORK=1
time make docker-test-clang@ubuntu SHOW_ENV=1 J=14 NETWORK=1
=== TEST SCRIPT END ===

  LINK    qemu-edid
  LINK    fsdev/virtfs-proxy-helper
  LINK    scsi/qemu-pr-helper
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  LINK    qemu-bridge-helper
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  LINK    virtiofsd
  LINK    vhost-user-input
  LINK    qemu-ga
---
  CC      i386-softmmu/hw/display/vhost-user-gpu.o
  CC      m68k-softmmu/qapi/qapi-types.o
  CC      microblazeel-softmmu/target/microblaze/cpu.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      microblaze-softmmu/qapi/qapi-visit.o
  CC      mips-softmmu/hw/display/virtio-gpu-base.o
  CC      arm-softmmu/hw/display/vhost-user-gpu.o
---
  CC      arm-softmmu/hw/intc/exynos4210_combiner.o
  CC      microblaze-softmmu/qapi/qapi-init-commands.o
  LINK    microblazeel-softmmu/qemu-system-microblazeel
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      cris-softmmu/qapi/qapi-visit.o
  CC      cris-softmmu/qapi/qapi-events-machine-target.o
  CC      mips64-softmmu/accel/stubs/whpx-stub.o
---
  CC      i386-softmmu/hw/scsi/virtio-scsi.o
  CC      mipsel-softmmu/fpu/softfloat.o
  CC      aarch64-softmmu/hw/display/vhost-user-gpu.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      alpha-softmmu/hw/scsi/vhost-scsi.o
  CC      hppa-softmmu/hw/scsi/virtio-scsi-dataplane.o
  CC      mips-softmmu/hw/scsi/virtio-scsi.o
---
  CC      mips64-softmmu/hw/block/vhost-user-blk.o
  CC      aarch64-softmmu/hw/intc/arm_gicv3_cpuif.o
  CC      arm-softmmu/hw/vfio/spapr.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      mips64el-softmmu/accel/tcg/tcg-runtime-gvec.o
  CC      arm-softmmu/hw/vfio/pci.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      hppa-softmmu/hw/vfio/pci-quirks.o
  CC      mipsel-softmmu/ioport.o
  CC      mips64-softmmu/hw/block/dataplane/virtio-blk.o
---
  GEN     trace/generated-helpers.c
  CC      mipsel-softmmu/hw/vfio/spapr.o
  CC      alpha-softmmu/trace/control-target.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      alpha-softmmu/softmmu/main.o
  CC      moxie-softmmu/target/moxie/helper.o
  CC      aarch64-softmmu/hw/arm/tosa.o
---
  CC      aarch64-softmmu/hw/arm/sbsa-ref.o
  CC      arm-softmmu/hw/arm/collie.o
  CC      mips64-softmmu/hw/mips/gt64xxx_pci.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      mips64el-softmmu/hw/virtio/vhost-user-scsi-pci.o
  CC      moxie-softmmu/target/moxie/mmu.o
  CC      mips64el-softmmu/hw/virtio/vhost-scsi-pci.o
---
  CC      mips64-softmmu/hw/mips/mips_jazz.o
  CC      mips64-softmmu/hw/mips/cps.o
  CC      i386-softmmu/hw/i386/../xenpv/xen_machine_pv.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      arm-softmmu/hw/arm/sabrelite.o
  CC      mips64el-softmmu/hw/virtio/virtio-9p-pci.o
  CC      aarch64-softmmu/hw/arm/versatilepb.o
---
  CC      arm-softmmu/hw/arm/smmuv3.o
  CC      aarch64-softmmu/hw/arm/musca.o
  CC      ppc-softmmu/disas.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc64-softmmu/memory.o
  CC      riscv32-softmmu/disas.o
  CC      aarch64-softmmu/hw/arm/armsse.o
---
  CC      s390x-softmmu/accel/stubs/hax-stub.o
  CC      ppc64-softmmu/hw/display/vhost-user-vga.o
  CC      s390x-softmmu/accel/stubs/hvf-stub.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      aarch64-softmmu/target/arm/debug_helper.o
  CC      ppc64-softmmu/hw/intc/xics.o
  CC      s390x-softmmu/accel/stubs/whpx-stub.o
---
  GEN     sh4eb-softmmu/config-devices.h
  GEN     sh4eb-softmmu/config-target.h
  CC      sh4eb-softmmu/exec.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc64-softmmu/hw/intc/pnv_xive.o
  CC      ppc-softmmu/hw/display/vhost-user-gpu.o
  CC      riscv32-softmmu/hw/display/vhost-user-gpu.o
---
  LINK    mips-softmmu/qemu-system-mips
  CC      aarch64-softmmu/target/arm/m_helper.o
  CC      ppc64-softmmu/hw/net/virtio-net.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      s390x-softmmu/accel/tcg/cpu-exec.o
  CC      sh4-softmmu/fpu/softfloat.o
  CC      riscv64-softmmu/hw/display/virtio-gpu-3d.o
---
  CC      riscv32-softmmu/hw/virtio/vhost-user-input-pci.o
  CC      ppc-softmmu/hw/virtio/virtio-crypto-pci.o
  CC      ppc-softmmu/hw/virtio/vhost-user-fs-pci.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      s390x-softmmu/hw/scsi/vhost-scsi.o
  CC      riscv32-softmmu/hw/virtio/vhost-user-scsi-pci.o
  CC      ppc64-softmmu/hw/virtio/virtio.o
---
  CC      sh4eb-softmmu/qtest.o
  CC      ppc-softmmu/hw/virtio/virtio-9p-pci.o
  CC      ppc64-softmmu/hw/virtio/virtio-crypto-pci.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      sparc64-softmmu/exec-vary.o
  CC      riscv64-softmmu/hw/virtio/vhost-vsock.o
  CC      mipsel-softmmu/target/mips/dsp_helper.o
---
  CC      sparc-softmmu/qtest.o
  CC      riscv64-softmmu/hw/riscv/riscv_htif.o
  CC      sh4eb-softmmu/accel/stubs/kvm-stub.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      s390x-softmmu/hw/virtio/vhost-backend.o
  CC      ppc64-softmmu/hw/virtio/virtio-net-pci.o
  CC      riscv64-softmmu/hw/riscv/riscv_hart.o
---
  CC      riscv32-softmmu/softmmu/main.o
  CC      riscv64-softmmu/qapi/qapi-commands-machine-target.o
  CC      s390x-softmmu/hw/s390x/event-facility.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc-softmmu/qapi/qapi-commands-misc-target.o
  CC      riscv32-softmmu/gdbstub-xml.o
  CC      riscv64-softmmu/qapi/qapi-commands-misc-target.o
---
  CC      ppc-softmmu/target/ppc/translate.o
  CC      riscv64-softmmu/target/riscv/cpu_helper.o
  CC      ppc-softmmu/target/ppc/machine.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc-softmmu/target/ppc/mmu_helper.o
  CC      sparc-softmmu/hw/sparc/sun4m.o
  CC      s390x-softmmu/hw/s390x/virtio-ccw.o
---
  CC      s390x-softmmu/hw/s390x/virtio-ccw-scsi.o
  CC      s390x-softmmu/hw/s390x/virtio-ccw-rng.o
  CC      sh4-softmmu/hw/virtio/vhost-user.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc64-softmmu/hw/ppc/pnv_homer.o
  CC      sh4eb-softmmu/hw/display/vhost-user-gpu-pci.o
  CC      tricore-softmmu/tcg/tcg-op.o
---
  CC      sh4-softmmu/hw/virtio/virtio-net-pci.o
  CC      ppc64-softmmu/hw/ppc/ppce500_spin.o
  CC      tricore-softmmu/fpu/softfloat.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      sparc-softmmu/target/sparc/helper.o
  CC      xtensa-softmmu/tcg/tcg.o
  CC      sh4-softmmu/hw/virtio/virtio-serial-pci.o
---
  CC      tricore-softmmu/arch_init.o
  CC      sh4-softmmu/qapi/qapi-commands-machine-target.o
  CC      ppc64-softmmu/qapi/qapi-init-commands.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      sh4eb-softmmu/hw/virtio/vhost-user-fs.o
  CC      sh4-softmmu/qapi/qapi-commands-misc-target.o
  CC      sh4-softmmu/qapi/qapi-commands.o
---
  CC      s390x-softmmu/target/s390x/int_helper.o
  CC      sh4eb-softmmu/qapi/qapi-events-machine-target.o
  CC      unicore32-softmmu/accel/stubs/whpx-stub.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      aarch64_be-linux-user/tcg/tcg-op.o
  CC      sh4eb-softmmu/qapi/qapi-events-misc-target.o
  CC      ppc-softmmu/target/ppc/excp_helper.o
---
  LINK    s390x-softmmu/qemu-system-s390x
  CC      x86_64-softmmu/migration/ram.o
  CC      xtensaeb-softmmu/qtest.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      unicore32-softmmu/hw/core/machine-qmp-cmds.o
  CC      xtensa-softmmu/accel/tcg/cpu-exec.o
  CC      sparc64-softmmu/hw/virtio/vhost-user-fs.o
---
  CC      tricore-softmmu/qapi/qapi-commands-misc-target.o
  CC      xtensaeb-softmmu/migration/ram.o
  CC      sparc64-softmmu/hw/virtio/vhost-user-scsi-pci.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      unicore32-softmmu/qapi/qapi-types-misc-target.o
  CC      ppc-softmmu/softmmu/main.o
  CC      arm-linux-user/tcg/tcg.o
---
  CC      sparc64-softmmu/hw/virtio/virtio-iommu-pci.o
  CC      unicore32-softmmu/qapi/qapi-events-misc-target.o
  CC      alpha-linux-user/accel/stubs/hvf-stub.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      aarch64_be-linux-user/thunk.o
  CC      unicore32-softmmu/qapi/qapi-events.o
  CC      alpha-linux-user/accel/stubs/whpx-stub.o
---
  CC      xtensa-softmmu/hw/net/virtio-net.o
  CC      armeb-linux-user/tcg/tcg-op-gvec.o
  CC      x86_64-softmmu/hw/block/vhost-user-blk.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc64-softmmu/target/ppc/kvm-stub.o
  CC      aarch64-linux-user/linux-user/syscall.o
  CC      aarch64-linux-user/linux-user/strace.o
---
  CC      xtensaeb-softmmu/hw/display/virtio-gpu-pci.o
  CC      armeb-linux-user/gdbstub.o
  CC      ppc64-softmmu/target/ppc/../../libdecnumber/decContext.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      xtensa-softmmu/hw/vfio/display.o
  CCAS    aarch64-linux-user/linux-user/safe-syscall.o
  CC      alpha-linux-user/target/alpha/translate.o
---
  CC      alpha-linux-user/target/alpha/sys_helper.o
  CC      hppa-linux-user/tcg/tcg-common.o
  CC      armeb-linux-user/accel/tcg/translate-all.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      xtensaeb-softmmu/hw/scsi/vhost-user-scsi.o
  LINK    ppc64-softmmu/qemu-system-ppc64
  CC      alpha-linux-user/target/alpha/mem_helper.o
---
  CC      alpha-linux-user/target/alpha/gdbstub.o
  CC      xtensaeb-softmmu/hw/semihosting/config.o
  CC      x86_64-softmmu/hw/scsi/virtio-scsi-dataplane.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      armeb-linux-user/accel/tcg/translator.o
  CC      xtensaeb-softmmu/hw/semihosting/console.o
  GEN     trace/generated-helpers.c
---
  CC      xtensaeb-softmmu/target/xtensa/cpu.o
  CC      mips-linux-user/linux-user/mmap.o
  CC      microblazeel-linux-user/linux-user/signal.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      mips64el-linux-user/tcg/tcg-op.o
  CC      mips64el-linux-user/tcg/tcg-op-vec.o
  LINK    armeb-linux-user/qemu-armeb
---
  LINK    xtensaeb-softmmu/qemu-system-xtensaeb
  CC      mips64-linux-user/tcg/tcg-op-gvec.o
  CC      microblazeel-linux-user/target/microblaze/translate.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      i386-linux-user/target/i386/svm_helper.o
  GEN     ppc-linux-user/config-target.h
  CC      ppc-linux-user/exec.o
---
  CC      ppc64abi32-linux-user/linux-user/syscall.o
  CC      ppc64-linux-user/accel/tcg/translator.o
  CC      mipsn32-linux-user/linux-user/linuxload.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      ppc-linux-user/linux-user/elfload.o
  CC      mipsn32-linux-user/linux-user/uaccess.o
  CC      nios2-linux-user/linux-user/strace.o
---
  CC      s390x-linux-user/target/s390x/translate.o
  CC      xtensa-linux-user/thunk.o
  CC      xtensaeb-linux-user/fpu/softfloat.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      x86_64-linux-user/accel/stubs/hvf-stub.o
  CC      sh4-linux-user/linux-user/flatload.o
  CC      tilegx-linux-user/linux-user/syscall.o
---
  CC      i32_to_f64.o
  CC      i32_to_extF80.o
  LINK    tests/test-aio-multithread
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      i32_to_extF80M.o
  CC      i32_to_f128.o
  CC      i32_to_f128M.o
---
  CC      i64_to_f32.o
  CC      i64_to_f64.o
  CC      i64_to_extF80.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      i64_to_extF80M.o
  LINK    tests/test-throttle
  CC      i64_to_f128.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      i64_to_f128M.o
  LINK    tests/test-thread-pool
  CC      f16_to_ui32.o
---
  CC      f16_to_ui64_r_minMag.o
  CC      f16_to_i32_r_minMag.o
  CC      f16_to_i64_r_minMag.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      f16_to_f32.o
  CC      f16_to_f64.o
  LINK    tests/test-bdrv-drain
  CC      f16_to_extF80.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      f16_to_extF80M.o
  CC      f16_to_f128.o
  CC      f16_to_f128M.o
  CC      f16_roundToInt.o
  CC      f16_add.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  LINK    tests/test-bdrv-graph-mod
  CC      f16_sub.o
  CC      f16_mul.o
  CC      f16_mulAdd.o
  CC      f16_div.o
  CC      f16_rem.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  LINK    tests/test-blockjob
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      f16_sqrt.o
  CC      f16_eq.o
  CC      f16_le.o
---
  CC      f32_to_ui32.o
  CC      f32_to_ui64.o
  CC      f32_to_i32.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      f32_to_i64.o
  LINK    tests/test-block-backend
  CC      f32_to_ui32_r_minMag.o
  CC      f32_to_ui64_r_minMag.o
  CC      f32_to_i32_r_minMag.o
  CC      f32_to_i64_r_minMag.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      f32_to_f16.o
  CC      f32_to_f64.o
  CC      f32_to_extF80.o
  LINK    tests/test-block-iothread
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  LINK    tests/test-image-locking
  LINK    tests/test-x86-cpuid
  CC      f32_to_extF80M.o
---
  LINK    tests/test-xbzrle
  CC      f32_div.o
  LINK    tests/test-vmstate
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      f32_rem.o
  CC      f32_sqrt.o
  LINK    tests/test-cutils
---
  CC      extF80M_to_f64.o
  CC      extF80M_to_f128M.o
  CC      extF80M_roundToInt.o
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  CC      extF80M_add.o
  CC      extF80M_sub.o
  CC      extF80M_mul.o
---
  LINK    tests/qtest/arm-cpu-features
  AR      libsoftfloat.a
  LINK    tests/qtest/tpm-tis-device-test
/usr/bin/ld: /lib/x86_64-linux-gnu/libtirpc.so.3: warning: common of `rpc_createerr@@GLIBC_2.2.5' overridden by definition from /lib/x86_64-linux-gnu/libc.so.6
  LINK    tests/qtest/tpm-tis-device-swtpm-test
  LINK    tests/qtest/numa-test
  LINK    fp-test
---
dbus-daemon[5453]: Could not get password database information for UID of current process: User "???" unknown or no memory to allocate password entry

**
ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
ERROR - Bail out! ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
Aborted (core dumped)
cleaning up pid 5453
make: *** [/tmp/qemu-test/src/tests/Makefile.include:632: check-qtest-i386] Error 1
make: *** Waiting for unfinished jobs....

Looking for expected file 'tests/data/acpi/pc/FACP.bridge'
---
dbus-daemon[6892]: Could not get password database information for UID of current process: User "???" unknown or no memory to allocate password entry

**
ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
Aborted (core dumped)
cleaning up pid 6892
ERROR - Bail out! ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
make: *** [/tmp/qemu-test/src/tests/Makefile.include:632: check-qtest-x86_64] Error 1
  TEST    check-qtest-arm: tests/qtest/test-hmp
  TEST    check-qtest-arm: tests/qtest/qos-test
  TEST    check-qtest-aarch64: tests/qtest/test-hmp
---
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=2e42e92cfb504ed5b5cb56b2c8b512df', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=1', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-dwbsabkq/src/docker-src.2020-03-06-10.32.46.2194:/var/tmp/qemu:z,ro', 'qemu:ubuntu', '/var/tmp/qemu/run', 'test-clang']' returned non-zero exit status 2.
filter=--filter=label=com.qemu.instance.uuid=2e42e92cfb504ed5b5cb56b2c8b512df
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-dwbsabkq/src'
make: *** [docker-run-test-clang@ubuntu] Error 2

real    40m29.624s
user    0m9.675s


The full log is available at
http://patchew.org/logs/20200306140917.26726-1-jandryuk@gmail.com/testing.docker-clang@ubuntu/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb-serial: wakeup device on input
  2020-03-06 16:13 ` no-reply
@ 2020-03-06 17:33   ` Jason Andryuk
  0 siblings, 0 replies; 5+ messages in thread
From: Jason Andryuk @ 2020-03-06 17:33 UTC (permalink / raw)
  To: QEMU; +Cc: Samuel Thibault, Gerd Hoffmann

On Fri, Mar 6, 2020 at 11:13 AM <no-reply@patchew.org> wrote:
>
> Patchew URL: https://patchew.org/QEMU/20200306140917.26726-1-jandryuk@gmail.com/
>
>
>
> Hi,
>
> This series failed the docker-clang@ubuntu build test. Please find the testing commands and
> their output below. If you have Docker installed, you can probably reproduce it
> locally.
>
> === TEST SCRIPT BEGIN ===
> #!/bin/bash
> make docker-image-ubuntu V=1 NETWORK=1
> time make docker-test-clang@ubuntu SHOW_ENV=1 J=14 NETWORK=1
> === TEST SCRIPT END ===

I ran these two commands locally and they completed successfully.

>   LINK    fp-test
> ---
> dbus-daemon[5453]: Could not get password database information for UID of current process: User "???" unknown or no memory to allocate password entry

Was there a problem with this container's password db and/or
out-of-memory like this message states?

Regards,
Jason

> **
> ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
> ERROR - Bail out! ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
> Aborted (core dumped)
> cleaning up pid 5453
> make: *** [/tmp/qemu-test/src/tests/Makefile.include:632: check-qtest-i386] Error 1
> make: *** Waiting for unfinished jobs....
>
> Looking for expected file 'tests/data/acpi/pc/FACP.bridge'
> ---
> dbus-daemon[6892]: Could not get password database information for UID of current process: User "???" unknown or no memory to allocate password entry
>
> **
> ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
> Aborted (core dumped)
> cleaning up pid 6892
> ERROR - Bail out! ERROR:/tmp/qemu-test/src/tests/qtest/dbus-vmstate-test.c:114:get_connection: assertion failed (err == NULL): The connection is closed (g-io-error-quark, 18)
> make: *** [/tmp/qemu-test/src/tests/Makefile.include:632: check-qtest-x86_64] Error 1
>   TEST    check-qtest-arm: tests/qtest/test-hmp
>   TEST    check-qtest-arm: tests/qtest/qos-test
>   TEST    check-qtest-aarch64: tests/qtest/test-hmp
> ---
>     raise CalledProcessError(retcode, cmd)
> subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=2e42e92cfb504ed5b5cb56b2c8b512df', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=1', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-dwbsabkq/src/docker-src.2020-03-06-10.32.46.2194:/var/tmp/qemu:z,ro', 'qemu:ubuntu', '/var/tmp/qemu/run', 'test-clang']' returned non-zero exit status 2.
> filter=--filter=label=com.qemu.instance.uuid=2e42e92cfb504ed5b5cb56b2c8b512df
> make[1]: *** [docker-run] Error 1
> make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-dwbsabkq/src'
> make: *** [docker-run-test-clang@ubuntu] Error 2
>
> real    40m29.624s
> user    0m9.675s
>
>
> The full log is available at
> http://patchew.org/logs/20200306140917.26726-1-jandryuk@gmail.com/testing.docker-clang@ubuntu/?type=message.
> ---
> Email generated automatically by Patchew [https://patchew.org/].
> Please send your feedback to patchew-devel@redhat.com


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb-serial: wakeup device on input
  2020-03-06 14:09 [PATCH] usb-serial: wakeup device on input Jason Andryuk
  2020-03-06 16:13 ` no-reply
@ 2020-03-09 10:08 ` Gerd Hoffmann
  2020-03-09 18:38   ` Jason Andryuk
  1 sibling, 1 reply; 5+ messages in thread
From: Gerd Hoffmann @ 2020-03-09 10:08 UTC (permalink / raw)
  To: Jason Andryuk; +Cc: Samuel Thibault, qemu-devel

On Fri, Mar 06, 2020 at 09:09:17AM -0500, Jason Andryuk wrote:
> Currently usb-serial devices are unable to send data into guests with
> the xhci controller.  Data is copied into the usb-serial's buffer, but
> it is not sent into the guest.  Data coming out of the guest works
> properly.  usb-serial devices work properly with ehci.
> 
> Have usb-serial call usb_wakeup() when receiving data from the chardev.
> This seems to notify the xhci controller and fix inbound data flow.
> 
> Also add USB_CFG_ATT_WAKEUP to the device's bmAttributes.  This matches
> a real FTDI serial adapter's bmAttributes.
> 
> Signed-off-by: Jason Andryuk <jandryuk@gmail.com>

Added to usb patch queue.

thanks,
  Gerd



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] usb-serial: wakeup device on input
  2020-03-09 10:08 ` Gerd Hoffmann
@ 2020-03-09 18:38   ` Jason Andryuk
  0 siblings, 0 replies; 5+ messages in thread
From: Jason Andryuk @ 2020-03-09 18:38 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: Samuel Thibault, QEMU

On Mon, Mar 9, 2020 at 6:08 AM Gerd Hoffmann <kraxel@redhat.com> wrote:
>
> On Fri, Mar 06, 2020 at 09:09:17AM -0500, Jason Andryuk wrote:
> > Currently usb-serial devices are unable to send data into guests with
> > the xhci controller.  Data is copied into the usb-serial's buffer, but
> > it is not sent into the guest.  Data coming out of the guest works
> > properly.  usb-serial devices work properly with ehci.
> >
> > Have usb-serial call usb_wakeup() when receiving data from the chardev.
> > This seems to notify the xhci controller and fix inbound data flow.
> >
> > Also add USB_CFG_ATT_WAKEUP to the device's bmAttributes.  This matches
> > a real FTDI serial adapter's bmAttributes.
> >
> > Signed-off-by: Jason Andryuk <jandryuk@gmail.com>
>
> Added to usb patch queue.

Thanks.  Unfortunately, while this seemed okay in my early testing,
something is still off.  Typing at slow (human) speed, input seems
fine.  Pasting a large chunk of data into netcat has some of the data
dropped (not coming out of /dev/ttyUSB0 in the guest).  The VM kernel
reports "ttyUSB0: X input overrun(s)" with X seen between 1 and 8.
EHCI seems fine, even for chunks greater than the 384 byte buffer of
usb-serial.

As one example, pasting
Aa0Aa1Aa2Aa3Aa4Aa5Aa6Aa7Aa8Aa9Ab0Ab1Ab2Ab3Ab4Ab5Ab6Ab7Ab8Ab9Ac0Ac1Ac2Ac3Ac4Ac5Ac6Ac7Ac8Ac9Ad0Ad1Ad2Ad3Ad4Ad5Ad6Ad7Ad8Ad9Ae0
looks to only have the following output in the guest
Aa0Aa1Aa2Aa3Aa4Aa5Aa6Aa7Aa8Aa9Ab0Ab1Ab2Ab3Ab4Ab5Ab6Ab7Ab8Ab9Acc1Ac2Ac3Ac4Ac5Ac6Ac7Ac8Ac9Ad0Ad1Ad2Ad3Ad4Ad5Ad6Ad7Ad8Ad9Ae0

Characters 62 & 63 don't make it through "c0Ac" -> "cc".  The guest
kernel does *not* report input overruns in this case.

Any ideas?

Thanks,
Jason


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-03-09 18:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-06 14:09 [PATCH] usb-serial: wakeup device on input Jason Andryuk
2020-03-06 16:13 ` no-reply
2020-03-06 17:33   ` Jason Andryuk
2020-03-09 10:08 ` Gerd Hoffmann
2020-03-09 18:38   ` Jason Andryuk

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.