From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:36109) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SPYn2-00068j-5k for qemu-devel@nongnu.org; Wed, 02 May 2012 08:36:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SPYmx-000364-DS for qemu-devel@nongnu.org; Wed, 02 May 2012 08:36:15 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50150) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SPYmx-00035s-4r for qemu-devel@nongnu.org; Wed, 02 May 2012 08:36:11 -0400 Message-ID: <4FA12A20.1030000@redhat.com> Date: Wed, 02 May 2012 14:35:44 +0200 From: Gerd Hoffmann MIME-Version: 1.0 References: <1335896294-9530-1-git-send-email-aliguori@us.ibm.com> <1335896294-9530-6-git-send-email-aliguori@us.ibm.com> <4FA02D1A.1090807@us.ibm.com> In-Reply-To: <4FA02D1A.1090807@us.ibm.com> Content-Type: multipart/mixed; boundary="------------030305060303020709090005" Subject: Re: [Qemu-devel] [PATCH 05/14] qdev: use wrapper for qdev_get_path List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: Wanpeng Li , Paolo Bonzini , Peter Maydell , qemu-devel@nongnu.org, Andreas Faerber This is a multi-part message in MIME format. --------------030305060303020709090005 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit On 05/01/12 20:36, Anthony Liguori wrote: > Hi Gerd, > > Could you carefully review the USB changes here? I'm not really sure > what our contract is with the guest in terms of ABI compatibility. I > think it's good but it could use a second set of eyes. incremental fix attached. cheers, Gerd --------------030305060303020709090005 Content-Type: text/plain; name="0001-fixup.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0001-fixup.patch" >>From 8823f1f5491639119d267289610fcad6dd1a0872 Mon Sep 17 00:00:00 2001 From: Gerd Hoffmann Date: Wed, 2 May 2012 14:30:54 +0200 Subject: [PATCH] fixup Signed-off-by: Gerd Hoffmann --- hw/usb/desc.c | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/hw/usb/desc.c b/hw/usb/desc.c index 64352c9..84ea9f2 100644 --- a/hw/usb/desc.c +++ b/hw/usb/desc.c @@ -433,13 +433,11 @@ void usb_desc_create_serial(USBDevice *dev) int index = desc->id.iSerialNumber; char serial[64]; int dst; - char *path = NULL; + char *path; assert(index != 0 && desc->str[index] != NULL); dst = snprintf(serial, sizeof(serial), "%s", desc->str[index]); - if (hcd->parent_bus && hcd->parent_bus->parent) { - path = qdev_get_dev_path(hcd->parent_bus->parent); - } + path = qdev_get_dev_path(hcd); if (path) { dst += snprintf(serial+dst, sizeof(serial)-dst, "-%s", path); } -- 1.7.1 --------------030305060303020709090005--