Received: from eggs.gnu.org ([2001:4830:134:3::10]:50909) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bNI7x-0002V6-3Y for qemu-devel@nongnu.org; Wed, 13 Jul 2016 07:14:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bNI7t-0000oO-0p for qemu-devel@nongnu.org; Wed, 13 Jul 2016 07:14:53 -0400 Received: from mx1.redhat.com ([209.132.183.28]:45696) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bNI7s-0000nk-RG for qemu-devel@nongnu.org; Wed, 13 Jul 2016 07:14:48 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 5723AC057EC9 for ; Wed, 13 Jul 2016 11:14:48 +0000 (UTC) From: Gerd Hoffmann Date: Wed, 13 Jul 2016 13:14:33 +0200 Message-Id: <1468408474-17648-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH] usbredir: add streams property List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann Enabled by default, can be used to turn off (usb3) streams support. xhci has a such a property too (same name, same default). Signed-off-by: Gerd Hoffmann --- hw/usb/redirect.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c index 8ec8484..444672a 100644 --- a/hw/usb/redirect.c +++ b/hw/usb/redirect.c @@ -109,6 +109,7 @@ struct USBRedirDevice { uint8_t debug; char *filter_str; int32_t bootindex; + bool enable_streams; /* Data passed from chardev the fd_read cb to the usbredirparser read cb */ const uint8_t *read_buf; int read_buf_size; @@ -1229,7 +1230,9 @@ static void usbredir_create_parser(USBRedirDevice *dev) usbredirparser_caps_set_cap(caps, usb_redir_cap_32bits_bulk_length); usbredirparser_caps_set_cap(caps, usb_redir_cap_bulk_receiving); #if USBREDIR_VERSION >= 0x000700 - usbredirparser_caps_set_cap(caps, usb_redir_cap_bulk_streams); + if (dev->enable_streams) { + usbredirparser_caps_set_cap(caps, usb_redir_cap_bulk_streams); + } #endif if (runstate_check(RUN_STATE_INMIGRATE)) { @@ -2476,6 +2479,7 @@ static Property usbredir_properties[] = { DEFINE_PROP_CHR("chardev", USBRedirDevice, cs), DEFINE_PROP_UINT8("debug", USBRedirDevice, debug, usbredirparser_warning), DEFINE_PROP_STRING("filter", USBRedirDevice, filter_str), + DEFINE_PROP_BOOL("streams", USBRedirDevice, enable_streams, true), DEFINE_PROP_END_OF_LIST(), }; -- 1.8.3.1