From patchwork Thu Apr 2 11:47:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?YmF1ZXJjaGVuKOmZiOiSmeiSmSk=?= X-Patchwork-Id: 11470525 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5195814DD for ; Thu, 2 Apr 2020 11:48:09 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A0EBE206D3 for ; Thu, 2 Apr 2020 11:48:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=tencent.com header.i=@tencent.com header.b="m+Za0XVn" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A0EBE206D3 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=tencent.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Received: from localhost ([::1]:37326 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJyKM-0002sd-J2 for patchwork-qemu-devel@patchwork.kernel.org; Thu, 02 Apr 2020 07:48:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52912) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJyJt-0002SO-5n for qemu-devel@nongnu.org; Thu, 02 Apr 2020 07:47:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jJyJk-0005eT-W6 for qemu-devel@nongnu.org; Thu, 02 Apr 2020 07:47:31 -0400 Received: from mail6.tencent.com ([220.249.245.26]:55261) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1jJyJk-0005cO-2g for qemu-devel@nongnu.org; Thu, 02 Apr 2020 07:47:28 -0400 Received: from EX-SZ021.tencent.com (unknown [10.28.6.73]) by mail6.tencent.com (Postfix) with ESMTP id 36CF3CC271; Thu, 2 Apr 2020 19:47:56 +0800 (CST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tencent.com; s=s202002; t=1585828076; bh=ODk1nZ4bCkOyrjG9lQDyR2E9wQvZp3xy0tCZBxevX28=; h=From:To:CC:Subject:Date; b=m+Za0XVnem/0/arNf8aCti34ilCLIvI0nd5mbizfjzjZgRQ7vKRaMvCB2OreLPC0C EKJYq8OMPYgGsVtzzCElA/vpMNe0mFQSeTdnCVzLRTvtVJmRF1ssl7jg37UTL3tx9u bew/stNCiQMxrV0bozGPf5xvs17eXnNQa7bPdK14= Received: from EX-SZ005.tencent.com (10.28.6.29) by EX-SZ021.tencent.com (10.28.6.73) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1847.3; Thu, 2 Apr 2020 19:47:17 +0800 Received: from EX-SZ005.tencent.com (10.28.6.29) by EX-SZ005.tencent.com (10.28.6.29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1847.3; Thu, 2 Apr 2020 19:47:17 +0800 Received: from EX-SZ005.tencent.com ([fe80::5d14:1c60:ce53:dbd6]) by EX-SZ005.tencent.com ([fe80::5d14:1c60:ce53:dbd6%4]) with mapi id 15.01.1847.007; Thu, 2 Apr 2020 19:47:17 +0800 From: =?utf-8?b?YmF1ZXJjaGVuKOmZiOiSmeiSmSk=?= To: qemu-devel Subject: is just a wrong function name of libusb_get_port_number? request for a review of the bug fix Thread-Topic: is just a wrong function name of libusb_get_port_number? request for a review of the bug fix Thread-Index: AQHWCOBmrsmcg0upoEK6uJ0LEU9ceA== Date: Thu, 2 Apr 2020 11:47:17 +0000 Message-ID: <02a07a59c3964199b73b1145e4abe0e9@tencent.com> Accept-Language: zh-CN, en-US Content-Language: zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.14.87.198] MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 220.249.245.26 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: hdegoede , kraxel Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" From 6bfb3087866606ed36a21e7bd05f0674e6a97158 Mon Sep 17 00:00:00 2001 From: Bauerchen Date: Thu, 2 Apr 2020 19:19:00 +0800 Subject: [PATCH] Fix:fix the wrong function name of libusb_get_port_number [desc]: libusb_get_port_numbers is called in function usb_host_get_port, and qemu crashed with: symbol lookup error: undefined symbol: libusb_get_port_numbers I check /lib64/libusb-1.0.so.0 and output is libusb_get_port_number, I change it to libusb_get_port_number, crash problem is gone; so is it just a function name bug? Signed-off-by: Bauerchen ---  hw/usb/host-libusb.c | 2 +-  1 file changed, 1 insertion(+), 1 deletion(-) --  1.8.3.1 ------------- bauerchen diff --git a/hw/usb/host-libusb.c b/hw/usb/host-libusb.c index 2ac7a93..713db8d 100644 --- a/hw/usb/host-libusb.c +++ b/hw/usb/host-libusb.c @@ -285,7 +285,7 @@ static int usb_host_get_port(libusb_device *dev, char *port, size_t len)      int rc, i;    #if LIBUSB_API_VERSION >= 0x01000102 -    rc = libusb_get_port_numbers(dev, path, 7); +    rc = libusb_get_port_number(dev, path, 7);  #else      rc = libusb_get_port_path(ctx, dev, path, 7);  #endif