All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] usb-serial: xHCI and timeout fixes
@ 2020-03-12 12:55 Jason Andryuk
  2020-03-12 12:55 ` [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function Jason Andryuk
                   ` (5 more replies)
  0 siblings, 6 replies; 13+ messages in thread
From: Jason Andryuk @ 2020-03-12 12:55 UTC (permalink / raw)
  To: Gerd Hoffmann, Samuel Thibault; +Cc: qemu-devel, Jason Andryuk

This patch series includes two fixes for usb-serial.

The first is a data corruption issue with xHCI controllers.  The FTDI
data packets need to have a 2 byte header start every 64 bytes of packet
data.  For EHCI this is not a problem since USBPacket size is 64, so
only 1 such chunk fits in a packet.  xHCI controllers supply 512 byte
USBPackets, and usb-serial would only write a single header.  This
confuses drivers since they interpret some data bytes as header bytes.
Chunk the data with headers at every 64 byte offset.

To allow full use of the 512 USBPackets, increase the buffer size to 512
- 2 * 8 = 496 bytes.

A second fix is to set the FTDI_THRE (Transmitter Holding Register) and
FTDI_TEMT (Transmitter Empty) status bits in a GetModemStat response.
This makes the linux driver happy when closing the device and avoids a
30 second timeout.

Jason Andryuk (4):
  usb-serial: Move USB_TOKEN_IN into a helper function
  usb-serial: chunk data to wMaxPacketSize
  usb-serial: Increase receive buffer to 496
  usb-serial: Fix timeout closing the device

 hw/usb/dev-serial.c | 92 +++++++++++++++++++++++++++------------------
 1 file changed, 56 insertions(+), 36 deletions(-)

-- 
2.24.1



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

* [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function
  2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
@ 2020-03-12 12:55 ` Jason Andryuk
  2020-03-13 23:56   ` Samuel Thibault
  2020-03-16 11:40   ` Gerd Hoffmann
  2020-03-12 12:55 ` [PATCH 2/4] usb-serial: chunk data to wMaxPacketSize Jason Andryuk
                   ` (4 subsequent siblings)
  5 siblings, 2 replies; 13+ messages in thread
From: Jason Andryuk @ 2020-03-12 12:55 UTC (permalink / raw)
  To: Gerd Hoffmann, Samuel Thibault; +Cc: qemu-devel, Jason Andryuk

We'll be adding a loop, so move the code into a helper function.  breaks
are replaced with returns.

Signed-off-by: Jason Andryuk <jandryuk@gmail.com>
---
 hw/usb/dev-serial.c | 77 +++++++++++++++++++++++++--------------------
 1 file changed, 43 insertions(+), 34 deletions(-)

diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
index daac75b7ae..71fa786bd8 100644
--- a/hw/usb/dev-serial.c
+++ b/hw/usb/dev-serial.c
@@ -358,13 +358,53 @@ static void usb_serial_handle_control(USBDevice *dev, USBPacket *p,
     }
 }
 
+static void usb_serial_token_in(USBSerialState *s, USBPacket *p)
+{
+    int first_len, len;
+    uint8_t header[2];
+
+    first_len = RECV_BUF - s->recv_ptr;
+    len = p->iov.size;
+    if (len <= 2) {
+        p->status = USB_RET_NAK;
+        return;
+    }
+    header[0] = usb_get_modem_lines(s) | 1;
+    /* We do not have the uart details */
+    /* handle serial break */
+    if (s->event_trigger && s->event_trigger & FTDI_BI) {
+        s->event_trigger &= ~FTDI_BI;
+        header[1] = FTDI_BI;
+        usb_packet_copy(p, header, 2);
+        return;
+    } else {
+        header[1] = 0;
+    }
+    len -= 2;
+    if (len > s->recv_used)
+        len = s->recv_used;
+    if (!len) {
+        p->status = USB_RET_NAK;
+        return;
+    }
+    if (first_len > len)
+        first_len = len;
+    usb_packet_copy(p, header, 2);
+    usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
+    if (len > first_len)
+        usb_packet_copy(p, s->recv_buf, len - first_len);
+    s->recv_used -= len;
+    s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
+
+    return;
+}
+
 static void usb_serial_handle_data(USBDevice *dev, USBPacket *p)
 {
     USBSerialState *s = (USBSerialState *)dev;
     uint8_t devep = p->ep->nr;
     struct iovec *iov;
-    uint8_t header[2];
-    int i, first_len, len;
+    int i;
 
     switch (p->pid) {
     case USB_TOKEN_OUT:
@@ -382,38 +422,7 @@ static void usb_serial_handle_data(USBDevice *dev, USBPacket *p)
     case USB_TOKEN_IN:
         if (devep != 1)
             goto fail;
-        first_len = RECV_BUF - s->recv_ptr;
-        len = p->iov.size;
-        if (len <= 2) {
-            p->status = USB_RET_NAK;
-            break;
-        }
-        header[0] = usb_get_modem_lines(s) | 1;
-        /* We do not have the uart details */
-        /* handle serial break */
-        if (s->event_trigger && s->event_trigger & FTDI_BI) {
-            s->event_trigger &= ~FTDI_BI;
-            header[1] = FTDI_BI;
-            usb_packet_copy(p, header, 2);
-            break;
-        } else {
-            header[1] = 0;
-        }
-        len -= 2;
-        if (len > s->recv_used)
-            len = s->recv_used;
-        if (!len) {
-            p->status = USB_RET_NAK;
-            break;
-        }
-        if (first_len > len)
-            first_len = len;
-        usb_packet_copy(p, header, 2);
-        usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
-        if (len > first_len)
-            usb_packet_copy(p, s->recv_buf, len - first_len);
-        s->recv_used -= len;
-        s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
+        usb_serial_token_in(s, p);
         break;
 
     default:
-- 
2.24.1



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

* [PATCH 2/4] usb-serial: chunk data to wMaxPacketSize
  2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
  2020-03-12 12:55 ` [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function Jason Andryuk
@ 2020-03-12 12:55 ` Jason Andryuk
  2020-03-14  0:07   ` Samuel Thibault
  2020-03-12 12:55 ` [PATCH 3/4] usb-serial: Increase receive buffer to 496 Jason Andryuk
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 13+ messages in thread
From: Jason Andryuk @ 2020-03-12 12:55 UTC (permalink / raw)
  To: Gerd Hoffmann, Samuel Thibault; +Cc: qemu-devel, Jason Andryuk

usb-serial has issues with xHCI controllers where data is lost in the
VM.  Inspecting the URBs in the guest, EHCI starts every 64 byte boundary
(wMaxPacketSize) with a header.  EHCI hands packets into
usb_serial_token_in() with size 64, so these cannot cross the 64 byte
boundary.  The xHCI controller has packets of 512 bytes and the usb-serial
will just write through the 64 byte boundary.  In the guest, this means
data bytes are interpreted as header, so data bytes don't make it out
the serial interface.

Re-work usb_serial_token_in to chunk data into 64 byte units - 2 byte
header and 62 bytes data.  The Linux driver reads wMaxPacketSize to find
the chunk size, so we match that.

Real hardware was observed to pass in 512 byte URBs (496 bytes data +
8 * 2 byte headers).  Since usb-serial only buffers 384 bytes of data,
usb-serial will pass in 6 64 byte blocks and 1 12 byte partial block for
462 bytes max.

Signed-off-by: Jason Andryuk <jandryuk@gmail.com>
---
 hw/usb/dev-serial.c | 43 +++++++++++++++++++++++++++----------------
 1 file changed, 27 insertions(+), 16 deletions(-)

diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
index 71fa786bd8..96b6c34202 100644
--- a/hw/usb/dev-serial.c
+++ b/hw/usb/dev-serial.c
@@ -360,15 +360,16 @@ static void usb_serial_handle_control(USBDevice *dev, USBPacket *p,
 
 static void usb_serial_token_in(USBSerialState *s, USBPacket *p)
 {
-    int first_len, len;
+    const int max_packet_size = desc_iface0.eps[0].wMaxPacketSize;
+    int packet_len;
     uint8_t header[2];
 
-    first_len = RECV_BUF - s->recv_ptr;
-    len = p->iov.size;
-    if (len <= 2) {
+    packet_len = p->iov.size;
+    if (packet_len <= 2) {
         p->status = USB_RET_NAK;
         return;
     }
+
     header[0] = usb_get_modem_lines(s) | 1;
     /* We do not have the uart details */
     /* handle serial break */
@@ -380,21 +381,31 @@ static void usb_serial_token_in(USBSerialState *s, USBPacket *p)
     } else {
         header[1] = 0;
     }
-    len -= 2;
-    if (len > s->recv_used)
-        len = s->recv_used;
-    if (!len) {
+
+    if (!s->recv_used) {
         p->status = USB_RET_NAK;
         return;
     }
-    if (first_len > len)
-        first_len = len;
-    usb_packet_copy(p, header, 2);
-    usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
-    if (len > first_len)
-        usb_packet_copy(p, s->recv_buf, len - first_len);
-    s->recv_used -= len;
-    s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
+
+    while (s->recv_used && packet_len > 2) {
+        int first_len, len;
+
+        len = MIN(packet_len, max_packet_size);
+        len -= 2;
+        if (len > s->recv_used)
+            len = s->recv_used;
+
+        first_len = RECV_BUF - s->recv_ptr;
+        if (first_len > len)
+            first_len = len;
+        usb_packet_copy(p, header, 2);
+        usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
+        if (len > first_len)
+            usb_packet_copy(p, s->recv_buf, len - first_len);
+        s->recv_used -= len;
+        s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
+        packet_len -= len + 2;
+    }
 
     return;
 }
-- 
2.24.1



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

* [PATCH 3/4] usb-serial: Increase receive buffer to 496
  2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
  2020-03-12 12:55 ` [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function Jason Andryuk
  2020-03-12 12:55 ` [PATCH 2/4] usb-serial: chunk data to wMaxPacketSize Jason Andryuk
@ 2020-03-12 12:55 ` Jason Andryuk
  2020-03-14 21:40   ` Samuel Thibault
  2020-03-12 12:55 ` [PATCH 4/4] usb-serial: Fix timeout closing the device Jason Andryuk
                   ` (2 subsequent siblings)
  5 siblings, 1 reply; 13+ messages in thread
From: Jason Andryuk @ 2020-03-12 12:55 UTC (permalink / raw)
  To: Gerd Hoffmann, Samuel Thibault; +Cc: qemu-devel, Jason Andryuk

A FTDI USB adapter on an xHCI controller can send 512 byte USB packets.
These are 8 * ( 2 bytes header + 62 bytes data).  A 384 byte receive
buffer is insufficient to fill a 512 byte packet, so bump the receive
size to 496 ( 512 - 2 * 8 ).

Signed-off-by: Jason Andryuk <jandryuk@gmail.com>
---
 hw/usb/dev-serial.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
index 96b6c34202..ef33bcd127 100644
--- a/hw/usb/dev-serial.c
+++ b/hw/usb/dev-serial.c
@@ -29,7 +29,7 @@ do { printf("usb-serial: " fmt , ## __VA_ARGS__); } while (0)
 #define DPRINTF(fmt, ...) do {} while(0)
 #endif
 
-#define RECV_BUF 384
+#define RECV_BUF (512 - (2 * 8))
 
 /* Commands */
 #define FTDI_RESET		0
-- 
2.24.1



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

* [PATCH 4/4] usb-serial: Fix timeout closing the device
  2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
                   ` (2 preceding siblings ...)
  2020-03-12 12:55 ` [PATCH 3/4] usb-serial: Increase receive buffer to 496 Jason Andryuk
@ 2020-03-12 12:55 ` Jason Andryuk
  2020-03-14 21:41   ` Samuel Thibault
  2020-03-12 13:14 ` [PATCH 0/4] usb-serial: xHCI and timeout fixes no-reply
  2020-03-12 13:31 ` no-reply
  5 siblings, 1 reply; 13+ messages in thread
From: Jason Andryuk @ 2020-03-12 12:55 UTC (permalink / raw)
  To: Gerd Hoffmann, Samuel Thibault; +Cc: qemu-devel, Jason Andryuk

Linux guests wait ~30 seconds when closing the emulated /dev/ttyUSB0.
During that time, the kernel driver is sending many control URBs
requesting GetModemStat (5).  Real hardware returns a status with
FTDI_THRE (Transmitter Holding Register) and FTDI_TEMT (Transmitter
Empty) set.  QEMU leaves them clear, and it seems Linux is waiting for
FTDI_TEMT to be set to indicate the tx queue is empty before closing.

Set the bits when responding to a GetModemStat query and avoid the
shutdown delay.

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

---
Looking at a USB dump for a real FTDI USB adapter, I see these bits set
in all the bulk URBs where QEMU currently has them clear.
---
 hw/usb/dev-serial.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
index ef33bcd127..5389235f17 100644
--- a/hw/usb/dev-serial.c
+++ b/hw/usb/dev-serial.c
@@ -332,7 +332,7 @@ static void usb_serial_handle_control(USBDevice *dev, USBPacket *p,
         break;
     case DeviceInVendor | FTDI_GET_MDM_ST:
         data[0] = usb_get_modem_lines(s) | 1;
-        data[1] = 0;
+        data[1] = FTDI_THRE | FTDI_TEMT;
         p->actual_length = 2;
         break;
     case DeviceOutVendor | FTDI_SET_EVENT_CHR:
-- 
2.24.1



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

* Re: [PATCH 0/4] usb-serial: xHCI and timeout fixes
  2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
                   ` (3 preceding siblings ...)
  2020-03-12 12:55 ` [PATCH 4/4] usb-serial: Fix timeout closing the device Jason Andryuk
@ 2020-03-12 13:14 ` no-reply
  2020-03-12 13:31 ` no-reply
  5 siblings, 0 replies; 13+ messages in thread
From: no-reply @ 2020-03-12 13:14 UTC (permalink / raw)
  To: jandryuk; +Cc: samuel.thibault, jandryuk, kraxel, qemu-devel

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



Hi,

This series seems to have some coding style problems. See output below for
more information:

Subject: [PATCH 0/4] usb-serial: xHCI and timeout fixes
Message-id: 20200312125524.7812-1-jandryuk@gmail.com
Type: series

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
Switched to a new branch 'test'
657eee3 usb-serial: Fix timeout closing the device
299ce37 usb-serial: Increase receive buffer to 496
80411e3 usb-serial: chunk data to wMaxPacketSize
1d93326 usb-serial: Move USB_TOKEN_IN into a helper function

=== OUTPUT BEGIN ===
1/4 Checking commit 1d9332671a0d (usb-serial: Move USB_TOKEN_IN into a helper function)
ERROR: braces {} are necessary for all arms of this statement
#44: FILE: hw/usb/dev-serial.c:384:
+    if (len > s->recv_used)
[...]

ERROR: braces {} are necessary for all arms of this statement
#50: FILE: hw/usb/dev-serial.c:390:
+    if (first_len > len)
[...]

ERROR: braces {} are necessary for all arms of this statement
#54: FILE: hw/usb/dev-serial.c:394:
+    if (len > first_len)
[...]

total: 3 errors, 0 warnings, 94 lines checked

Patch 1/4 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

2/4 Checking commit 80411e3c7e85 (usb-serial: chunk data to wMaxPacketSize)
ERROR: braces {} are necessary for all arms of this statement
#80: FILE: hw/usb/dev-serial.c:395:
+        if (len > s->recv_used)
[...]

ERROR: braces {} are necessary for all arms of this statement
#84: FILE: hw/usb/dev-serial.c:399:
+        if (first_len > len)
[...]

ERROR: braces {} are necessary for all arms of this statement
#88: FILE: hw/usb/dev-serial.c:403:
+        if (len > first_len)
[...]

total: 3 errors, 0 warnings, 63 lines checked

Patch 2/4 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

3/4 Checking commit 299ce37a1f63 (usb-serial: Increase receive buffer to 496)
4/4 Checking commit 657eee3ce83f (usb-serial: Fix timeout closing the device)
=== OUTPUT END ===

Test command exited with code: 1


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

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

* Re: [PATCH 0/4] usb-serial: xHCI and timeout fixes
  2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
                   ` (4 preceding siblings ...)
  2020-03-12 13:14 ` [PATCH 0/4] usb-serial: xHCI and timeout fixes no-reply
@ 2020-03-12 13:31 ` no-reply
  5 siblings, 0 replies; 13+ messages in thread
From: no-reply @ 2020-03-12 13:31 UTC (permalink / raw)
  To: jandryuk; +Cc: samuel.thibault, jandryuk, kraxel, qemu-devel

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



Hi,

This series failed the asan 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
export ARCH=x86_64
make docker-image-fedora V=1 NETWORK=1
time make docker-test-debug@fedora TARGET_LIST=x86_64-softmmu J=14 NETWORK=1
=== TEST SCRIPT END ===

PASS 1 fdc-test /x86_64/fdc/cmos
PASS 2 fdc-test /x86_64/fdc/no_media_on_start
PASS 3 fdc-test /x86_64/fdc/read_without_media
==8219==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 fdc-test /x86_64/fdc/media_change
PASS 5 fdc-test /x86_64/fdc/sense_interrupt
PASS 6 fdc-test /x86_64/fdc/relative_seek
---
PASS 32 test-opts-visitor /visitor/opts/range/beyond
PASS 33 test-opts-visitor /visitor/opts/dict/unvisited
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-coroutine -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-coroutine" 
==8280==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8280==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff0f0d9000; bottom 0x7fc84d120000; size: 0x0036c1fb9000 (235182723072)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-coroutine /basic/no-dangling-access
---
PASS 13 fdc-test /x86_64/fdc/fuzz-registers
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/ide-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ide-test" 
PASS 14 test-aio /aio/timer/schedule
==8295==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 15 test-aio /aio/coroutine/queue-chaining
PASS 16 test-aio /aio-gsource/flush
PASS 17 test-aio /aio-gsource/bh/schedule
---
PASS 25 test-aio /aio-gsource/event/wait
PASS 26 test-aio /aio-gsource/event/flush
PASS 27 test-aio /aio-gsource/event/wait/no-flush-cb
==8303==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 ide-test /x86_64/ide/identify
==8309==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 ide-test /x86_64/ide/flush
PASS 28 test-aio /aio-gsource/timer/schedule
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-aio-multithread -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-aio-multithread" 
==8315==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8318==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-aio-multithread /aio/multi/lifecycle
PASS 3 ide-test /x86_64/ide/bmdma/simple_rw
==8335==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 ide-test /x86_64/ide/bmdma/trim
PASS 2 test-aio-multithread /aio/multi/schedule
==8341==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-aio-multithread /aio/multi/mutex/contended
PASS 4 test-aio-multithread /aio/multi/mutex/handoff
PASS 5 test-aio-multithread /aio/multi/mutex/mcs
==8362==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 6 test-aio-multithread /aio/multi/mutex/pthread
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-throttle -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-throttle" 
PASS 1 test-throttle /throttle/leak_bucket
---
PASS 6 test-throttle /throttle/detach_attach
PASS 7 test-throttle /throttle/config_functions
PASS 8 test-throttle /throttle/accounting
==8374==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-throttle /throttle/groups
PASS 10 test-throttle /throttle/config/enabled
PASS 11 test-throttle /throttle/config/conflicting
---
PASS 14 test-throttle /throttle/config/max
PASS 15 test-throttle /throttle/config/iops_size
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-thread-pool -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-thread-pool" 
==8378==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-thread-pool /thread-pool/submit
PASS 2 test-thread-pool /thread-pool/submit-aio
PASS 3 test-thread-pool /thread-pool/submit-co
---
PASS 2 test-hbitmap /hbitmap/size/0
PASS 3 test-hbitmap /hbitmap/size/unaligned
PASS 4 test-hbitmap /hbitmap/iter/empty
==8445==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 test-hbitmap /hbitmap/iter/partial
PASS 6 test-hbitmap /hbitmap/iter/granularity
PASS 7 test-hbitmap /hbitmap/iter/iter_and_reset
---
PASS 28 test-hbitmap /hbitmap/truncate/shrink/medium
PASS 29 test-hbitmap /hbitmap/truncate/shrink/large
PASS 30 test-hbitmap /hbitmap/meta/zero
==8455==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 31 test-hbitmap /hbitmap/meta/one
PASS 32 test-hbitmap /hbitmap/meta/byte
PASS 33 test-hbitmap /hbitmap/meta/word
---
PASS 44 test-hbitmap /hbitmap/next_dirty_area/next_dirty_area_4
PASS 45 test-hbitmap /hbitmap/next_dirty_area/next_dirty_area_after_truncate
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bdrv-drain -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bdrv-drain" 
==8461==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8464==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bdrv-drain /bdrv-drain/nested
PASS 2 test-bdrv-drain /bdrv-drain/multiparent
PASS 3 test-bdrv-drain /bdrv-drain/set_aio_context
---
PASS 41 test-bdrv-drain /bdrv-drain/bdrv_drop_intermediate/poll
PASS 42 test-bdrv-drain /bdrv-drain/replace_child/mid-drain
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bdrv-graph-mod -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bdrv-graph-mod" 
==8507==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bdrv-graph-mod /bdrv-graph-mod/update-perm-tree
PASS 2 test-bdrv-graph-mod /bdrv-graph-mod/should-update-child
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-blockjob -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-blockjob" 
==8511==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-blockjob /blockjob/ids
PASS 2 test-blockjob /blockjob/cancel/created
PASS 3 test-blockjob /blockjob/cancel/running
---
PASS 7 test-blockjob /blockjob/cancel/pending
PASS 8 test-blockjob /blockjob/cancel/concluded
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-blockjob-txn -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-blockjob-txn" 
==8515==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-blockjob-txn /single/success
PASS 2 test-blockjob-txn /single/failure
PASS 3 test-blockjob-txn /single/cancel
---
PASS 6 test-blockjob-txn /pair/cancel
PASS 7 test-blockjob-txn /pair/fail-cancel-race
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-block-backend -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-block-backend" 
==8519==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-block-backend /block-backend/drain_aio_error
PASS 2 test-block-backend /block-backend/drain_all_aio_error
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-block-iothread -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-block-iothread" 
==8523==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-block-iothread /sync-op/pread
PASS 2 test-block-iothread /sync-op/pwrite
PASS 3 test-block-iothread /sync-op/load_vmstate
---
PASS 15 test-block-iothread /propagate/diamond
PASS 16 test-block-iothread /propagate/mirror
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-image-locking -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-image-locking" 
==8543==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-image-locking /image-locking/basic
PASS 2 test-image-locking /image-locking/set-perm-abort
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-x86-cpuid -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-x86-cpuid" 
---
PASS 9 test-int128 /int128/int128_gt
PASS 10 test-int128 /int128/int128_rshift
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/rcutorture -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="rcutorture" 
==8562==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 rcutorture /rcu/torture/1reader
PASS 2 rcutorture /rcu/torture/10readers
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-list -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-list" 
PASS 1 test-rcu-list /rcu/qlist/single-threaded
PASS 2 test-rcu-list /rcu/qlist/short-few
==8634==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 test-rcu-list /rcu/qlist/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-simpleq -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-simpleq" 
PASS 1 test-rcu-simpleq /rcu/qsimpleq/single-threaded
PASS 2 test-rcu-simpleq /rcu/qsimpleq/short-few
PASS 3 test-rcu-simpleq /rcu/qsimpleq/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-tailq -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-tailq" 
==8676==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-rcu-tailq /rcu/qtailq/single-threaded
PASS 2 test-rcu-tailq /rcu/qtailq/short-few
PASS 3 test-rcu-tailq /rcu/qtailq/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-rcu-slist -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-rcu-slist" 
PASS 1 test-rcu-slist /rcu/qslist/single-threaded
==8724==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 test-rcu-slist /rcu/qslist/short-few
PASS 3 test-rcu-slist /rcu/qslist/long-many
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qdist -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qdist" 
---
PASS 8 test-qdist /qdist/binning/shrink
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qht -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qht" 
PASS 5 ide-test /x86_64/ide/bmdma/various_prdts
==8758==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8758==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffcd26ce000; bottom 0x7fe1b67fe000; size: 0x001b1bed0000 (116432633856)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 6 ide-test /x86_64/ide/bmdma/no_busmaster
PASS 7 ide-test /x86_64/ide/flush/nodev
==8769==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 ide-test /x86_64/ide/flush/empty_drive
==8774==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 ide-test /x86_64/ide/flush/retry_pci
==8780==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 ide-test /x86_64/ide/flush/retry_isa
==8786==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 ide-test /x86_64/ide/cdrom/pio
==8792==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 ide-test /x86_64/ide/cdrom/pio_large
==8798==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 ide-test /x86_64/ide/cdrom/dma
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/ahci-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ahci-test" 
==8812==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 ahci-test /x86_64/ahci/sanity
==8818==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 ahci-test /x86_64/ahci/pci_spec
==8824==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 ahci-test /x86_64/ahci/pci_enable
==8830==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 ahci-test /x86_64/ahci/hba_spec
==8836==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 5 ahci-test /x86_64/ahci/hba_enable
PASS 1 test-qht /qht/mode/default
==8842==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 test-qht /qht/mode/resize
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qht-par -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qht-par" 
PASS 6 ahci-test /x86_64/ahci/identify
==8857==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 ahci-test /x86_64/ahci/max
PASS 1 test-qht-par /qht/parallel/2threads-0%updates-1s
==8863==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 ahci-test /x86_64/ahci/reset
PASS 2 test-qht-par /qht/parallel/2threads-20%updates-1s
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bitops -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bitops" 
---
PASS 5 test-bitops /bitops/half_unshuffle32
PASS 6 test-bitops /bitops/half_unshuffle64
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bitcnt -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bitcnt" 
==8875==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bitcnt /bitcnt/ctpop8
PASS 2 test-bitcnt /bitcnt/ctpop16
PASS 3 test-bitcnt /bitcnt/ctpop32
---
PASS 3 test-qdev-global-props /qdev/properties/dynamic/global
PASS 4 test-qdev-global-props /qdev/properties/global/subclass
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/check-qom-interface -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="check-qom-interface" 
==8875==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd27c22000; bottom 0x7f4d16ffe000; size: 0x00b010c24000 (756195409920)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 9 ahci-test /x86_64/ahci/io/pio/lba28/simple/zero
---
PASS 8 check-qom-proplist /qom/proplist/delchild
PASS 9 check-qom-proplist /qom/resolve/partial
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qemu-opts -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qemu-opts" 
==8905==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-qemu-opts /qemu-opts/find_unknown_opts
PASS 2 test-qemu-opts /qemu-opts/find_opts
PASS 3 test-qemu-opts /qemu-opts/opts_create
---
PASS 18 test-qemu-opts /qemu-opts/to_qdict/filtered
PASS 19 test-qemu-opts /qemu-opts/to_qdict/duplicates
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-keyval -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-keyval" 
==8905==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff536cb000; bottom 0x7f70a4ffe000; size: 0x008eae6cd000 (612811722752)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 10 ahci-test /x86_64/ahci/io/pio/lba28/simple/low
---
PASS 4 test-crypto-hash /crypto/hash/digest
PASS 5 test-crypto-hash /crypto/hash/base64
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-hmac -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-hmac" 
==8923==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-crypto-hmac /crypto/hmac/iov
PASS 2 test-crypto-hmac /crypto/hmac/alloc
PASS 3 test-crypto-hmac /crypto/hmac/prealloc
PASS 4 test-crypto-hmac /crypto/hmac/digest
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-cipher -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-cipher" 
==8923==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc82c33000; bottom 0x7fa3693fe000; size: 0x005919835000 (382680125440)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 11 ahci-test /x86_64/ahci/io/pio/lba28/simple/high
---
PASS 15 test-crypto-secret /crypto/secret/crypt/missingiv
PASS 16 test-crypto-secret /crypto/secret/crypt/badiv
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-tlscredsx509 -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-tlscredsx509" 
==8945==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8945==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd0d769000; bottom 0x7fc6b35fe000; size: 0x00365a16b000 (233439670272)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 12 ahci-test /x86_64/ahci/io/pio/lba28/double/zero
PASS 1 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/perfectserver
PASS 2 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/perfectclient
PASS 3 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca1
==8959==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8959==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd2bf33000; bottom 0x7f2da79fe000; size: 0x00cf84535000 (891278282752)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 13 ahci-test /x86_64/ahci/io/pio/lba28/double/low
==8965==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8965==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc292ce000; bottom 0x7f19153fe000; size: 0x00e313ed0000 (975291875328)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 14 ahci-test /x86_64/ahci/io/pio/lba28/double/high
PASS 4 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca2
==8971==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8971==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff5dc72000; bottom 0x7f8bd9ffe000; size: 0x007383c74000 (496132112384)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 5 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodca3
---
PASS 7 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca2
PASS 8 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/badca3
PASS 15 ahci-test /x86_64/ahci/io/pio/lba28/long/zero
==8977==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver1
==8977==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff9adea000; bottom 0x7f73a33fe000; size: 0x008bf79ec000 (601154830336)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 16 ahci-test /x86_64/ahci/io/pio/lba28/long/low
==8983==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==8983==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff80d3f000; bottom 0x7fe0d637c000; size: 0x001eaa9c3000 (131711381504)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 17 ahci-test /x86_64/ahci/io/pio/lba28/long/high
PASS 10 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver2
PASS 11 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver3
==8989==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 18 ahci-test /x86_64/ahci/io/pio/lba28/short/zero
PASS 12 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver4
PASS 13 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver5
==8995==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 19 ahci-test /x86_64/ahci/io/pio/lba28/short/low
==9001==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver6
PASS 20 ahci-test /x86_64/ahci/io/pio/lba28/short/high
PASS 15 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/goodserver7
---
PASS 32 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/inactive1
PASS 33 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/inactive2
PASS 34 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/inactive3
==9007==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9007==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe828c1000; bottom 0x7fe0d33fe000; size: 0x001daf4c3000 (127495057408)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 21 ahci-test /x86_64/ahci/io/pio/lba48/simple/zero
---
PASS 38 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingserver
PASS 39 test-crypto-tlscredsx509 /qcrypto/tlscredsx509/missingclient
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-crypto-tlssession -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-crypto-tlssession" 
==9013==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9013==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffcbf821000; bottom 0x7f24539fe000; size: 0x00d86be23000 (929522921472)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 22 ahci-test /x86_64/ahci/io/pio/lba48/simple/low
PASS 1 test-crypto-tlssession /qcrypto/tlssession/psk
==9023==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 test-crypto-tlssession /qcrypto/tlssession/basicca
==9023==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe46341000; bottom 0x7f23f2dfe000; size: 0x00da53543000 (937700896768)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 23 ahci-test /x86_64/ahci/io/pio/lba48/simple/high
==9029==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9029==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc53fbc000; bottom 0x7f34a67fe000; size: 0x00c7ad7be000 (857609068544)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 24 ahci-test /x86_64/ahci/io/pio/lba48/double/zero
PASS 3 test-crypto-tlssession /qcrypto/tlssession/differentca
==9035==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9035==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff1475b000; bottom 0x7ff476bfe000; size: 0x000a9db5d000 (45595611136)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 25 ahci-test /x86_64/ahci/io/pio/lba48/double/low
==9041==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9041==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc56cc2000; bottom 0x7f586b5fe000; size: 0x00a3eb6c4000 (704029409280)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 26 ahci-test /x86_64/ahci/io/pio/lba48/double/high
PASS 4 test-crypto-tlssession /qcrypto/tlssession/altname1
PASS 5 test-crypto-tlssession /qcrypto/tlssession/altname2
==9047==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9047==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffdedadd000; bottom 0x7f52e49fe000; size: 0x00ab090df000 (734591315968)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 6 test-crypto-tlssession /qcrypto/tlssession/altname3
PASS 27 ahci-test /x86_64/ahci/io/pio/lba48/long/zero
PASS 7 test-crypto-tlssession /qcrypto/tlssession/altname4
==9053==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9053==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe07281000; bottom 0x7f37ec5fe000; size: 0x00c61ac83000 (850852851712)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 28 ahci-test /x86_64/ahci/io/pio/lba48/long/low
PASS 8 test-crypto-tlssession /qcrypto/tlssession/altname5
==9059==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9059==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd605f4000; bottom 0x7f6f30dfe000; size: 0x008e2f7f6000 (610682232832)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 9 test-crypto-tlssession /qcrypto/tlssession/altname6
PASS 29 ahci-test /x86_64/ahci/io/pio/lba48/long/high
==9065==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 30 ahci-test /x86_64/ahci/io/pio/lba48/short/zero
PASS 10 test-crypto-tlssession /qcrypto/tlssession/wildcard1
==9071==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 31 ahci-test /x86_64/ahci/io/pio/lba48/short/low
PASS 11 test-crypto-tlssession /qcrypto/tlssession/wildcard2
==9077==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 32 ahci-test /x86_64/ahci/io/pio/lba48/short/high
==9083==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 test-crypto-tlssession /qcrypto/tlssession/wildcard3
PASS 33 ahci-test /x86_64/ahci/io/dma/lba28/fragmented
PASS 13 test-crypto-tlssession /qcrypto/tlssession/wildcard4
==9089==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 34 ahci-test /x86_64/ahci/io/dma/lba28/retry
==9095==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 35 ahci-test /x86_64/ahci/io/dma/lba28/simple/zero
==9101==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 test-crypto-tlssession /qcrypto/tlssession/wildcard5
PASS 36 ahci-test /x86_64/ahci/io/dma/lba28/simple/low
PASS 15 test-crypto-tlssession /qcrypto/tlssession/wildcard6
==9107==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 16 test-crypto-tlssession /qcrypto/tlssession/cachain
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-qga -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-qga" 
PASS 37 ahci-test /x86_64/ahci/io/dma/lba28/simple/high
==9121==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-qga /qga/sync-delimited
PASS 2 test-qga /qga/sync
PASS 3 test-qga /qga/ping
---
PASS 16 test-qga /qga/invalid-args
PASS 17 test-qga /qga/fsfreeze-status
PASS 38 ahci-test /x86_64/ahci/io/dma/lba28/double/zero
==9130==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 39 ahci-test /x86_64/ahci/io/dma/lba28/double/low
PASS 18 test-qga /qga/blacklist
==9136==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 19 test-qga /qga/config
PASS 20 test-qga /qga/guest-exec
PASS 40 ahci-test /x86_64/ahci/io/dma/lba28/double/high
PASS 21 test-qga /qga/guest-exec-invalid
==9151==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9151==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd7a461000; bottom 0x7faeac7fd000; size: 0x004ecdc64000 (338459770880)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 22 test-qga /qga/guest-get-osinfo
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-util-filemonitor -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-util-filemonitor" 
PASS 1 test-util-filemonitor /util/filemonitor
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-util-sockets -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-util-sockets" 
==9166==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-util-sockets /util/socket/is-socket/bad
PASS 2 test-util-sockets /util/socket/is-socket/good
PASS 3 test-util-sockets /socket/fd-pass/name/good
---
PASS 7 test-util-sockets /socket/fd-pass/num/bad
PASS 8 test-util-sockets /socket/fd-pass/num/nocli
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-authz-simple -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-authz-simple" 
==9166==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe7cc34000; bottom 0x7fa60457b000; size: 0x0058786b9000 (379977437184)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-authz-simple /authz/simple
---
PASS 4 test-io-task /crypto/task/thread_complete
PASS 5 test-io-task /crypto/task/thread_failure
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-io-channel-socket -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-socket" 
==9193==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-io-channel-socket /io/channel/socket/ipv4-sync
PASS 2 test-io-channel-socket /io/channel/socket/ipv4-async
PASS 3 test-io-channel-socket /io/channel/socket/ipv4-fd
---
PASS 8 test-io-channel-socket /io/channel/socket/unix-fd-pass
PASS 9 test-io-channel-socket /io/channel/socket/unix-listen-cleanup
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-io-channel-file -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-file" 
==9193==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd42878000; bottom 0x7fd6e717b000; size: 0x00265b6fd000 (164742811648)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 1 test-io-channel-file /io/channel/file
---
PASS 3 test-io-channel-command /io/channel/command/echo/sync
PASS 4 test-io-channel-command /io/channel/command/echo/async
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-io-channel-buffer -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-io-channel-buffer" 
==9259==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-io-channel-buffer /io/channel/buf
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-base64 -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-base64" 
PASS 1 test-base64 /util/base64/good
---
PASS 3 test-logging /logging/logfile_write_path
PASS 4 test-logging /logging/logfile_lock_path
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-replication -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-replication" 
==9300==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9307==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-replication /replication/primary/read
PASS 2 test-replication /replication/primary/write
PASS 45 ahci-test /x86_64/ahci/io/dma/lba28/short/low
==9315==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 46 ahci-test /x86_64/ahci/io/dma/lba28/short/high
PASS 3 test-replication /replication/primary/start
PASS 4 test-replication /replication/primary/stop
PASS 5 test-replication /replication/primary/do_checkpoint
PASS 6 test-replication /replication/primary/get_error_all
==9321==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 test-replication /replication/secondary/read
PASS 47 ahci-test /x86_64/ahci/io/dma/lba48/simple/zero
==9327==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 test-replication /replication/secondary/write
PASS 48 ahci-test /x86_64/ahci/io/dma/lba48/simple/low
==9333==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 49 ahci-test /x86_64/ahci/io/dma/lba48/simple/high
==9339==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 50 ahci-test /x86_64/ahci/io/dma/lba48/double/zero
==9307==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffc837ba000; bottom 0x7f2f5e3c5000; size: 0x00cd253f5000 (881093201920)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
==9346==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 test-replication /replication/secondary/start
PASS 51 ahci-test /x86_64/ahci/io/dma/lba48/double/low
==9369==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 52 ahci-test /x86_64/ahci/io/dma/lba48/double/high
==9375==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9375==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fffea034000; bottom 0x7f13b1dfd000; size: 0x00ec38237000 (1014554128384)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 53 ahci-test /x86_64/ahci/io/dma/lba48/long/zero
==9382==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9382==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffe1d500000; bottom 0x7f410937b000; size: 0x00bd14185000 (812085956608)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 10 test-replication /replication/secondary/stop
PASS 54 ahci-test /x86_64/ahci/io/dma/lba48/long/low
==9389==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9389==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7fff5234e000; bottom 0x7f61791fd000; size: 0x009dd9151000 (677951901696)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 55 ahci-test /x86_64/ahci/io/dma/lba48/long/high
==9396==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 56 ahci-test /x86_64/ahci/io/dma/lba48/short/zero
PASS 11 test-replication /replication/secondary/continuous_replication
==9402==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 57 ahci-test /x86_64/ahci/io/dma/lba48/short/low
==9408==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 58 ahci-test /x86_64/ahci/io/dma/lba48/short/high
==9414==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 test-replication /replication/secondary/do_checkpoint
PASS 59 ahci-test /x86_64/ahci/io/ncq/simple
==9420==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 test-replication /replication/secondary/get_error_all
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-bufferiszero -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-bufferiszero" 
PASS 60 ahci-test /x86_64/ahci/io/ncq/retry
==9429==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 61 ahci-test /x86_64/ahci/flush/simple
==9435==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 62 ahci-test /x86_64/ahci/flush/retry
==9441==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9447==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 63 ahci-test /x86_64/ahci/flush/migrate
==9455==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9461==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 64 ahci-test /x86_64/ahci/migrate/sanity
==9469==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9475==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 65 ahci-test /x86_64/ahci/migrate/dma/simple
==9483==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9489==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 66 ahci-test /x86_64/ahci/migrate/dma/halted
==9497==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9503==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 67 ahci-test /x86_64/ahci/migrate/ncq/simple
==9511==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9517==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 68 ahci-test /x86_64/ahci/migrate/ncq/halted
==9525==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 69 ahci-test /x86_64/ahci/cdrom/eject
==9530==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 70 ahci-test /x86_64/ahci/cdrom/dma/single
==9536==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 71 ahci-test /x86_64/ahci/cdrom/dma/multi
==9542==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 72 ahci-test /x86_64/ahci/cdrom/pio/single
==9548==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9548==WARNING: ASan is ignoring requested __asan_handle_no_return: stack top: 0x7ffd6fa9e000; bottom 0x7fae953fe000; size: 0x004eda6a0000 (338671828992)
False positive error reports may follow
For details see https://github.com/google/sanitizers/issues/189
PASS 73 ahci-test /x86_64/ahci/cdrom/pio/multi
==9554==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 74 ahci-test /x86_64/ahci/cdrom/pio/bcl
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/hd-geo-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="hd-geo-test" 
PASS 1 hd-geo-test /x86_64/hd-geo/ide/none
==9568==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 2 hd-geo-test /x86_64/hd-geo/ide/drive/cd_0
==9574==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/blank
==9580==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/lba
==9586==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 test-bufferiszero /cutils/bufferiszero
PASS 5 hd-geo-test /x86_64/hd-geo/ide/drive/mbr/chs
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/test-uuid -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="test-uuid" 
---
PASS 4 test-uuid /uuid/unparse
PASS 5 test-uuid /uuid/unparse_strdup
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  tests/ptimer-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="ptimer-test" 
==9593==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 1 ptimer-test /ptimer/set_count policy=default
PASS 2 ptimer-test /ptimer/set_limit policy=default
PASS 3 ptimer-test /ptimer/oneshot policy=default
---
PASS 21 test-qgraph /qgraph/test_two_test_same_interface
PASS 22 test-qgraph /qgraph/test_test_in_path
PASS 23 test-qgraph /qgraph/test_double_edge
==9604==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 7 hd-geo-test /x86_64/hd-geo/ide/device/mbr/lba
==9617==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 8 hd-geo-test /x86_64/hd-geo/ide/device/mbr/chs
==9623==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 9 hd-geo-test /x86_64/hd-geo/ide/device/user/chs
==9628==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 10 hd-geo-test /x86_64/hd-geo/ide/device/user/chst
==9634==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9638==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9642==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9646==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9650==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9654==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9658==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9662==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9665==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 11 hd-geo-test /x86_64/hd-geo/override/ide
==9672==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9676==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9680==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9684==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9688==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9692==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9696==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9700==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9703==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 12 hd-geo-test /x86_64/hd-geo/override/scsi
==9710==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9714==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9718==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9722==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9726==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9730==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9734==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9738==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9741==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 13 hd-geo-test /x86_64/hd-geo/override/scsi_2_controllers
==9748==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9752==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9756==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9760==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9763==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 14 hd-geo-test /x86_64/hd-geo/override/virtio_blk
==9770==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9774==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9777==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 15 hd-geo-test /x86_64/hd-geo/override/zero_chs
==9784==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9788==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9792==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9796==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9799==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 16 hd-geo-test /x86_64/hd-geo/override/scsi_hot_unplug
==9806==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9810==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9814==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9818==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
==9821==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 17 hd-geo-test /x86_64/hd-geo/override/virtio_hot_unplug
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/boot-order-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="boot-order-test" 
PASS 1 boot-order-test /x86_64/boot-order/pc
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9890==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP'
Using expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9896==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP'
Using expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9902==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.bridge'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9908==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.ipmikcs'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9914==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.cphp'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9921==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.memhp'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9927==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.numamem'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9933==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.dimmpxm'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9942==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/pc/FACP.acpihmat'
Looking for expected file 'tests/data/acpi/pc/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9949==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.bridge'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9955==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.mmio64'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9961==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.ipmibt'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9967==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.cphp'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9974==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.memhp'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9980==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.numamem'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9986==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.dimmpxm'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
Could not access KVM kernel module: No such file or directory
qemu-system-x86_64: -accel kvm: failed to initialize kvm: No such file or directory
qemu-system-x86_64: falling back to tcg
==9995==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!

Looking for expected file 'tests/data/acpi/q35/FACP.acpihmat'
Looking for expected file 'tests/data/acpi/q35/FACP'
---
PASS 1 i440fx-test /x86_64/i440fx/defaults
PASS 2 i440fx-test /x86_64/i440fx/pam
PASS 3 i440fx-test /x86_64/i440fx/firmware/bios
==10087==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 4 i440fx-test /x86_64/i440fx/firmware/pflash
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/fw_cfg-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="fw_cfg-test" 
PASS 1 fw_cfg-test /x86_64/fw_cfg/signature
---
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/drive_del-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="drive_del-test" 
PASS 1 drive_del-test /x86_64/drive_del/without-dev
PASS 2 drive_del-test /x86_64/drive_del/after_failed_device_add
==10180==WARNING: ASan doesn't fully support makecontext/swapcontext functions and may produce false positives in some cases!
PASS 3 drive_del-test /x86_64/blockdev/drive_del_device_del
MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(( ${RANDOM:-0} % 255 + 1))}  QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/qtest/wdt_ib700-test -m=quick -k --tap < /dev/null | ./scripts/tap-driver.pl --test-name="wdt_ib700-test" 
PASS 1 wdt_ib700-test /x86_64/wdt_ib700/pause
---
dbus-daemon[10350]: 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)
cleaning up pid 10350
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
make: *** Waiting for unfinished jobs....
Traceback (most recent call last):
  File "./tests/docker/docker.py", line 664, in <module>
---
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=c149f13600b74bdc914f38c068983d3e', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=x86_64-softmmu', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-vu6bhht4/src/docker-src.2020-03-12-09.03.46.7828:/var/tmp/qemu:z,ro', 'qemu:fedora', '/var/tmp/qemu/run', 'test-debug']' returned non-zero exit status 2.
filter=--filter=label=com.qemu.instance.uuid=c149f13600b74bdc914f38c068983d3e
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-vu6bhht4/src'
make: *** [docker-run-test-debug@fedora] Error 2

real    28m1.951s
user    0m8.343s


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

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

* Re: [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function
  2020-03-12 12:55 ` [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function Jason Andryuk
@ 2020-03-13 23:56   ` Samuel Thibault
  2020-03-16 11:40   ` Gerd Hoffmann
  1 sibling, 0 replies; 13+ messages in thread
From: Samuel Thibault @ 2020-03-13 23:56 UTC (permalink / raw)
  To: Jason Andryuk; +Cc: Gerd Hoffmann, qemu-devel

Jason Andryuk, le jeu. 12 mars 2020 08:55:20 -0400, a ecrit:
> We'll be adding a loop, so move the code into a helper function.  breaks
> are replaced with returns.
> 
> Signed-off-by: Jason Andryuk <jandryuk@gmail.com>

Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>

> ---
>  hw/usb/dev-serial.c | 77 +++++++++++++++++++++++++--------------------
>  1 file changed, 43 insertions(+), 34 deletions(-)
> 
> diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
> index daac75b7ae..71fa786bd8 100644
> --- a/hw/usb/dev-serial.c
> +++ b/hw/usb/dev-serial.c
> @@ -358,13 +358,53 @@ static void usb_serial_handle_control(USBDevice *dev, USBPacket *p,
>      }
>  }
>  
> +static void usb_serial_token_in(USBSerialState *s, USBPacket *p)
> +{
> +    int first_len, len;
> +    uint8_t header[2];
> +
> +    first_len = RECV_BUF - s->recv_ptr;
> +    len = p->iov.size;
> +    if (len <= 2) {
> +        p->status = USB_RET_NAK;
> +        return;
> +    }
> +    header[0] = usb_get_modem_lines(s) | 1;
> +    /* We do not have the uart details */
> +    /* handle serial break */
> +    if (s->event_trigger && s->event_trigger & FTDI_BI) {
> +        s->event_trigger &= ~FTDI_BI;
> +        header[1] = FTDI_BI;
> +        usb_packet_copy(p, header, 2);
> +        return;
> +    } else {
> +        header[1] = 0;
> +    }
> +    len -= 2;
> +    if (len > s->recv_used)
> +        len = s->recv_used;
> +    if (!len) {
> +        p->status = USB_RET_NAK;
> +        return;
> +    }
> +    if (first_len > len)
> +        first_len = len;
> +    usb_packet_copy(p, header, 2);
> +    usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
> +    if (len > first_len)
> +        usb_packet_copy(p, s->recv_buf, len - first_len);
> +    s->recv_used -= len;
> +    s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
> +
> +    return;
> +}
> +
>  static void usb_serial_handle_data(USBDevice *dev, USBPacket *p)
>  {
>      USBSerialState *s = (USBSerialState *)dev;
>      uint8_t devep = p->ep->nr;
>      struct iovec *iov;
> -    uint8_t header[2];
> -    int i, first_len, len;
> +    int i;
>  
>      switch (p->pid) {
>      case USB_TOKEN_OUT:
> @@ -382,38 +422,7 @@ static void usb_serial_handle_data(USBDevice *dev, USBPacket *p)
>      case USB_TOKEN_IN:
>          if (devep != 1)
>              goto fail;
> -        first_len = RECV_BUF - s->recv_ptr;
> -        len = p->iov.size;
> -        if (len <= 2) {
> -            p->status = USB_RET_NAK;
> -            break;
> -        }
> -        header[0] = usb_get_modem_lines(s) | 1;
> -        /* We do not have the uart details */
> -        /* handle serial break */
> -        if (s->event_trigger && s->event_trigger & FTDI_BI) {
> -            s->event_trigger &= ~FTDI_BI;
> -            header[1] = FTDI_BI;
> -            usb_packet_copy(p, header, 2);
> -            break;
> -        } else {
> -            header[1] = 0;
> -        }
> -        len -= 2;
> -        if (len > s->recv_used)
> -            len = s->recv_used;
> -        if (!len) {
> -            p->status = USB_RET_NAK;
> -            break;
> -        }
> -        if (first_len > len)
> -            first_len = len;
> -        usb_packet_copy(p, header, 2);
> -        usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
> -        if (len > first_len)
> -            usb_packet_copy(p, s->recv_buf, len - first_len);
> -        s->recv_used -= len;
> -        s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
> +        usb_serial_token_in(s, p);
>          break;
>  
>      default:
> -- 
> 2.24.1
> 

-- 
Samuel
Tu as lu les docs. Tu es devenu un informaticien. Que tu le veuilles
ou non. Lire la doc, c'est le Premier et Unique Commandement de
l'informaticien.
-+- TP in: Guide du Linuxien pervers - "L'évangile selon St Thomas"


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

* Re: [PATCH 2/4] usb-serial: chunk data to wMaxPacketSize
  2020-03-12 12:55 ` [PATCH 2/4] usb-serial: chunk data to wMaxPacketSize Jason Andryuk
@ 2020-03-14  0:07   ` Samuel Thibault
  0 siblings, 0 replies; 13+ messages in thread
From: Samuel Thibault @ 2020-03-14  0:07 UTC (permalink / raw)
  To: Jason Andryuk; +Cc: Gerd Hoffmann, qemu-devel

Jason Andryuk, le jeu. 12 mars 2020 08:55:21 -0400, a ecrit:
> usb-serial has issues with xHCI controllers where data is lost in the
> VM.  Inspecting the URBs in the guest, EHCI starts every 64 byte boundary
> (wMaxPacketSize) with a header.  EHCI hands packets into
> usb_serial_token_in() with size 64, so these cannot cross the 64 byte
> boundary.  The xHCI controller has packets of 512 bytes and the usb-serial
> will just write through the 64 byte boundary.  In the guest, this means
> data bytes are interpreted as header, so data bytes don't make it out
> the serial interface.
> 
> Re-work usb_serial_token_in to chunk data into 64 byte units - 2 byte
> header and 62 bytes data.  The Linux driver reads wMaxPacketSize to find
> the chunk size, so we match that.
> 
> Real hardware was observed to pass in 512 byte URBs (496 bytes data +
> 8 * 2 byte headers).  Since usb-serial only buffers 384 bytes of data,
> usb-serial will pass in 6 64 byte blocks and 1 12 byte partial block for
> 462 bytes max.
> 
> Signed-off-by: Jason Andryuk <jandryuk@gmail.com>

Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>

> ---
>  hw/usb/dev-serial.c | 43 +++++++++++++++++++++++++++----------------
>  1 file changed, 27 insertions(+), 16 deletions(-)
> 
> diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
> index 71fa786bd8..96b6c34202 100644
> --- a/hw/usb/dev-serial.c
> +++ b/hw/usb/dev-serial.c
> @@ -360,15 +360,16 @@ static void usb_serial_handle_control(USBDevice *dev, USBPacket *p,
>  
>  static void usb_serial_token_in(USBSerialState *s, USBPacket *p)
>  {
> -    int first_len, len;
> +    const int max_packet_size = desc_iface0.eps[0].wMaxPacketSize;
> +    int packet_len;
>      uint8_t header[2];
>  
> -    first_len = RECV_BUF - s->recv_ptr;
> -    len = p->iov.size;
> -    if (len <= 2) {
> +    packet_len = p->iov.size;
> +    if (packet_len <= 2) {
>          p->status = USB_RET_NAK;
>          return;
>      }
> +
>      header[0] = usb_get_modem_lines(s) | 1;
>      /* We do not have the uart details */
>      /* handle serial break */
> @@ -380,21 +381,31 @@ static void usb_serial_token_in(USBSerialState *s, USBPacket *p)
>      } else {
>          header[1] = 0;
>      }
> -    len -= 2;
> -    if (len > s->recv_used)
> -        len = s->recv_used;
> -    if (!len) {
> +
> +    if (!s->recv_used) {
>          p->status = USB_RET_NAK;
>          return;
>      }
> -    if (first_len > len)
> -        first_len = len;
> -    usb_packet_copy(p, header, 2);
> -    usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
> -    if (len > first_len)
> -        usb_packet_copy(p, s->recv_buf, len - first_len);
> -    s->recv_used -= len;
> -    s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
> +
> +    while (s->recv_used && packet_len > 2) {
> +        int first_len, len;
> +
> +        len = MIN(packet_len, max_packet_size);
> +        len -= 2;
> +        if (len > s->recv_used)
> +            len = s->recv_used;
> +
> +        first_len = RECV_BUF - s->recv_ptr;
> +        if (first_len > len)
> +            first_len = len;
> +        usb_packet_copy(p, header, 2);
> +        usb_packet_copy(p, s->recv_buf + s->recv_ptr, first_len);
> +        if (len > first_len)
> +            usb_packet_copy(p, s->recv_buf, len - first_len);
> +        s->recv_used -= len;
> +        s->recv_ptr = (s->recv_ptr + len) % RECV_BUF;
> +        packet_len -= len + 2;
> +    }
>  
>      return;
>  }
> -- 
> 2.24.1
> 

-- 
Samuel
We are Pentium of Borg. Division is futile. You will be approximated.
(seen in someone's .signature)


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

* Re: [PATCH 3/4] usb-serial: Increase receive buffer to 496
  2020-03-12 12:55 ` [PATCH 3/4] usb-serial: Increase receive buffer to 496 Jason Andryuk
@ 2020-03-14 21:40   ` Samuel Thibault
  0 siblings, 0 replies; 13+ messages in thread
From: Samuel Thibault @ 2020-03-14 21:40 UTC (permalink / raw)
  To: Jason Andryuk; +Cc: Gerd Hoffmann, qemu-devel

Jason Andryuk, le jeu. 12 mars 2020 08:55:22 -0400, a ecrit:
> A FTDI USB adapter on an xHCI controller can send 512 byte USB packets.
> These are 8 * ( 2 bytes header + 62 bytes data).  A 384 byte receive
> buffer is insufficient to fill a 512 byte packet, so bump the receive
> size to 496 ( 512 - 2 * 8 ).
> 
> Signed-off-by: Jason Andryuk <jandryuk@gmail.com>

Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>

> ---
>  hw/usb/dev-serial.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
> index 96b6c34202..ef33bcd127 100644
> --- a/hw/usb/dev-serial.c
> +++ b/hw/usb/dev-serial.c
> @@ -29,7 +29,7 @@ do { printf("usb-serial: " fmt , ## __VA_ARGS__); } while (0)
>  #define DPRINTF(fmt, ...) do {} while(0)
>  #endif
>  
> -#define RECV_BUF 384
> +#define RECV_BUF (512 - (2 * 8))
>  
>  /* Commands */
>  #define FTDI_RESET		0
> -- 
> 2.24.1
> 

-- 
Samuel
After watching my newly-retired dad spend two weeks learning how to make a new
folder, it became obvious that "intuitive" mostly means "what the writer or
speaker of intuitive likes".
(Bruce Ediger, bediger@teal.csn.org, in comp.os.linux.misc, on X the
intuitiveness of a Mac interface.)


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

* Re: [PATCH 4/4] usb-serial: Fix timeout closing the device
  2020-03-12 12:55 ` [PATCH 4/4] usb-serial: Fix timeout closing the device Jason Andryuk
@ 2020-03-14 21:41   ` Samuel Thibault
  0 siblings, 0 replies; 13+ messages in thread
From: Samuel Thibault @ 2020-03-14 21:41 UTC (permalink / raw)
  To: Jason Andryuk; +Cc: Gerd Hoffmann, qemu-devel

Jason Andryuk, le jeu. 12 mars 2020 08:55:23 -0400, a ecrit:
> Linux guests wait ~30 seconds when closing the emulated /dev/ttyUSB0.
> During that time, the kernel driver is sending many control URBs
> requesting GetModemStat (5).  Real hardware returns a status with
> FTDI_THRE (Transmitter Holding Register) and FTDI_TEMT (Transmitter
> Empty) set.  QEMU leaves them clear, and it seems Linux is waiting for
> FTDI_TEMT to be set to indicate the tx queue is empty before closing.
> 
> Set the bits when responding to a GetModemStat query and avoid the
> shutdown delay.
> 
> Signed-off-by: Jason Andryuk <jandryuk@gmail.com>

Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>

> ---
> Looking at a USB dump for a real FTDI USB adapter, I see these bits set
> in all the bulk URBs where QEMU currently has them clear.
> ---
>  hw/usb/dev-serial.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/hw/usb/dev-serial.c b/hw/usb/dev-serial.c
> index ef33bcd127..5389235f17 100644
> --- a/hw/usb/dev-serial.c
> +++ b/hw/usb/dev-serial.c
> @@ -332,7 +332,7 @@ static void usb_serial_handle_control(USBDevice *dev, USBPacket *p,
>          break;
>      case DeviceInVendor | FTDI_GET_MDM_ST:
>          data[0] = usb_get_modem_lines(s) | 1;
> -        data[1] = 0;
> +        data[1] = FTDI_THRE | FTDI_TEMT;
>          p->actual_length = 2;
>          break;
>      case DeviceOutVendor | FTDI_SET_EVENT_CHR:
> -- 
> 2.24.1
> 

-- 
Samuel
c> ah (on trouve fluide glacial sur le net, ou il faut aller dans le monde reel ?)
s> dans le monde reel
c> zut


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

* Re: [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function
  2020-03-12 12:55 ` [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function Jason Andryuk
  2020-03-13 23:56   ` Samuel Thibault
@ 2020-03-16 11:40   ` Gerd Hoffmann
  2020-03-16 12:05     ` Jason Andryuk
  1 sibling, 1 reply; 13+ messages in thread
From: Gerd Hoffmann @ 2020-03-16 11:40 UTC (permalink / raw)
  To: Jason Andryuk; +Cc: Samuel Thibault, qemu-devel

  Hi,

> +    if (len > s->recv_used)
> +        len = s->recv_used;

scripts/checkpatch.pl flags a codestyle error here.

> -        if (len > s->recv_used)
> -            len = s->recv_used;

Which is strictly speaking not your fault as you are just moving around
existing code.  It's common practice though that codestyle is fixed up
too when touching code.  Any chance you can make sure the patches pass
checkpatch & resend?

thanks,
  Gerd



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

* Re: [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function
  2020-03-16 11:40   ` Gerd Hoffmann
@ 2020-03-16 12:05     ` Jason Andryuk
  0 siblings, 0 replies; 13+ messages in thread
From: Jason Andryuk @ 2020-03-16 12:05 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: Samuel Thibault, QEMU

On Mon, Mar 16, 2020 at 7:40 AM Gerd Hoffmann <kraxel@redhat.com> wrote:
>
>   Hi,
>
> > +    if (len > s->recv_used)
> > +        len = s->recv_used;
>
> scripts/checkpatch.pl flags a codestyle error here.
>
> > -        if (len > s->recv_used)
> > -            len = s->recv_used;
>
> Which is strictly speaking not your fault as you are just moving around
> existing code.  It's common practice though that codestyle is fixed up
> too when touching code.  Any chance you can make sure the patches pass
> checkpatch & resend?

Sure.  Will do.

Regards,
Jason


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

end of thread, other threads:[~2020-03-16 14:38 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-12 12:55 [PATCH 0/4] usb-serial: xHCI and timeout fixes Jason Andryuk
2020-03-12 12:55 ` [PATCH 1/4] usb-serial: Move USB_TOKEN_IN into a helper function Jason Andryuk
2020-03-13 23:56   ` Samuel Thibault
2020-03-16 11:40   ` Gerd Hoffmann
2020-03-16 12:05     ` Jason Andryuk
2020-03-12 12:55 ` [PATCH 2/4] usb-serial: chunk data to wMaxPacketSize Jason Andryuk
2020-03-14  0:07   ` Samuel Thibault
2020-03-12 12:55 ` [PATCH 3/4] usb-serial: Increase receive buffer to 496 Jason Andryuk
2020-03-14 21:40   ` Samuel Thibault
2020-03-12 12:55 ` [PATCH 4/4] usb-serial: Fix timeout closing the device Jason Andryuk
2020-03-14 21:41   ` Samuel Thibault
2020-03-12 13:14 ` [PATCH 0/4] usb-serial: xHCI and timeout fixes no-reply
2020-03-12 13:31 ` no-reply

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.