|
|
5544c1 |
From 9f6674cd9bf6e0e3bafa8b8ec8388576756a6d13 Mon Sep 17 00:00:00 2001
|
|
Hans de Goede |
93b7e3 |
From: Hans de Goede <hdegoede@redhat.com>
|
|
|
5544c1 |
Date: Wed, 12 Sep 2012 15:08:39 +0200
|
|
|
5544c1 |
Subject: [PATCH] usb-redir: Revert usb-redir part of commit 93bfef4c
|
|
Hans de Goede |
93b7e3 |
|
|
Hans de Goede |
93b7e3 |
Commit 93bfef4c6e4b23caea9d51e1099d06433d8835a4 makes qemu-devices
|
|
Hans de Goede |
93b7e3 |
which report the qemu version string to the guest in some way use a
|
|
Hans de Goede |
93b7e3 |
qemu_get_version function which reports a machine-specific version string.
|
|
Hans de Goede |
93b7e3 |
|
|
Hans de Goede |
93b7e3 |
However usb-redir does not expose the qemu version to the guest, only to
|
|
Hans de Goede |
93b7e3 |
the usbredir-host as part of the initial handshake. This can then be logged
|
|
Hans de Goede |
93b7e3 |
on the usbredir-host side for debugging purposes and is otherwise completely
|
|
Hans de Goede |
93b7e3 |
unused! For debugging purposes it is important to have the real qemu version
|
|
Hans de Goede |
93b7e3 |
in there, rather then the machine-specific version.
|
|
Hans de Goede |
93b7e3 |
|
|
Hans de Goede |
93b7e3 |
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
|
|
|
5544c1 |
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
|
|
|
5544c1 |
(cherry picked from commit 35efba2cc6812dc980c336d7b9bf81dbfb5daf00)
|
|
|
5544c1 |
|
|
|
5544c1 |
Conflicts:
|
|
|
5544c1 |
|
|
|
5544c1 |
hw/usb/redirect.c
|
|
|
5544c1 |
|
|
|
5544c1 |
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
|
|
Hans de Goede |
93b7e3 |
---
|
|
|
5544c1 |
hw/usb/redirect.c | 7 +++----
|
|
|
5544c1 |
1 file changed, 3 insertions(+), 4 deletions(-)
|
|
Hans de Goede |
93b7e3 |
|
|
Hans de Goede |
93b7e3 |
diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c
|
|
|
5544c1 |
index ee75217..ab8d79a 100644
|
|
Hans de Goede |
93b7e3 |
--- a/hw/usb/redirect.c
|
|
Hans de Goede |
93b7e3 |
+++ b/hw/usb/redirect.c
|
|
|
5544c1 |
@@ -134,6 +134,8 @@ static void usbredir_interrupt_packet(void *priv, uint32_t id,
|
|
Hans de Goede |
93b7e3 |
static int usbredir_handle_status(USBRedirDevice *dev,
|
|
Hans de Goede |
93b7e3 |
int status, int actual_len);
|
|
Hans de Goede |
93b7e3 |
|
|
Hans de Goede |
93b7e3 |
+#define VERSION "qemu usb-redir guest " QEMU_VERSION
|
|
Hans de Goede |
93b7e3 |
+
|
|
Hans de Goede |
93b7e3 |
/*
|
|
Hans de Goede |
93b7e3 |
* Logging stuff
|
|
Hans de Goede |
93b7e3 |
*/
|
|
|
5544c1 |
@@ -777,9 +779,6 @@ static void usbredir_chardev_open(USBRedirDevice *dev)
|
|
|
5544c1 |
usbredir_chardev_close_bh(dev);
|
|
|
5544c1 |
qemu_bh_cancel(dev->chardev_close_bh);
|
|
Hans de Goede |
93b7e3 |
|
|
Hans de Goede |
93b7e3 |
- strcpy(version, "qemu usb-redir guest ");
|
|
Hans de Goede |
93b7e3 |
- pstrcat(version, sizeof(version), qemu_get_version());
|
|
Hans de Goede |
93b7e3 |
-
|
|
Hans de Goede |
93b7e3 |
dev->parser = qemu_oom_check(usbredirparser_create());
|
|
Hans de Goede |
93b7e3 |
dev->parser->priv = dev;
|
|
Hans de Goede |
93b7e3 |
dev->parser->log_func = usbredir_log;
|
|
|
5544c1 |
@@ -805,7 +804,7 @@ static void usbredir_chardev_open(USBRedirDevice *dev)
|
|
|
5544c1 |
|
|
|
5544c1 |
usbredirparser_caps_set_cap(caps, usb_redir_cap_connect_device_version);
|
|
|
5544c1 |
usbredirparser_caps_set_cap(caps, usb_redir_cap_filter);
|
|
|
5544c1 |
- usbredirparser_init(dev->parser, version, caps, USB_REDIR_CAPS_SIZE, 0);
|
|
|
5544c1 |
+ usbredirparser_init(dev->parser, VERSION, caps, USB_REDIR_CAPS_SIZE, 0);
|
|
Hans de Goede |
93b7e3 |
usbredirparser_do_write(dev->parser);
|
|
Hans de Goede |
93b7e3 |
}
|
|
|
5544c1 |
|
|
Hans de Goede |
93b7e3 |
--
|
|
|
5544c1 |
1.7.12.1
|
|
Hans de Goede |
93b7e3 |
|