From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BD2B7C072B5 for ; Fri, 24 May 2019 09:26:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8EDDD217F9 for ; Fri, 24 May 2019 09:26:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390120AbfEXJ0O (ORCPT ); Fri, 24 May 2019 05:26:14 -0400 Received: from Mailgw01.mediatek.com ([1.203.163.78]:23165 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S2389758AbfEXJ0O (ORCPT ); Fri, 24 May 2019 05:26:14 -0400 X-UUID: 6380ca07a1a848caadf8a110be0a92e8-20190524 X-UUID: 6380ca07a1a848caadf8a110be0a92e8-20190524 Received: from mtkcas35.mediatek.inc [(172.27.4.253)] by mailgw01.mediatek.com (envelope-from ) (mailgw01.mediatek.com ESMTP with TLS) with ESMTP id 1520838834; Fri, 24 May 2019 17:25:54 +0800 Received: from MTKCAS32.mediatek.inc (172.27.4.184) by MTKMBS31N1.mediatek.inc (172.27.4.69) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Fri, 24 May 2019 17:25:52 +0800 Received: from [10.17.3.153] (172.27.4.253) by MTKCAS32.mediatek.inc (172.27.4.170) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Fri, 24 May 2019 17:25:51 +0800 Message-ID: <1558689951.10179.422.camel@mhfsdcap03> Subject: Re: [RESEND PATCH] usb: mtu3: fix up undefined reference to usb_debug_root From: Chunfeng Yun To: Greg Kroah-Hartman CC: Matthias Brugger , Randy Dunlap , , , , Date: Fri, 24 May 2019 17:25:51 +0800 In-Reply-To: <20190524074552.GA1080@kroah.com> References: <20190524074552.GA1080@kroah.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.3-0ubuntu6 Content-Transfer-Encoding: 7bit MIME-Version: 1.0 X-MTK: N Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 2019-05-24 at 09:45 +0200, Greg Kroah-Hartman wrote: > On Fri, May 24, 2019 at 02:11:33PM +0800, Chunfeng Yun wrote: > > When CONFIG_USB is not set, and CONFIG_USB_GADGET is set, > > there is an issue: > > > > ld: > > drivers/usb/mtu3/mtu3_debugfs.o: in function 'ssusb_debugfs_create_root': > > mtu3_debugfs.c:(.text+0xba3): undefined reference to 'usb_debug_root' > > > > usb_debug_root is only built when CONFIG_USB is enabled, so here drop it > > and use NULL instead. > > > > Reported-by: Randy Dunlap > > Signed-off-by: Chunfeng Yun > > Acked-by: Randy Dunlap > > --- > > drivers/usb/mtu3/mtu3_debugfs.c | 3 +-- > > 1 file changed, 1 insertion(+), 2 deletions(-) > > Why resend? Sorry, I should send it out as v2 due to acked-by is added. > > > diff --git a/drivers/usb/mtu3/mtu3_debugfs.c b/drivers/usb/mtu3/mtu3_debugfs.c > > index 62c57ddc554e..b7c86ccd50b4 100644 > > --- a/drivers/usb/mtu3/mtu3_debugfs.c > > +++ b/drivers/usb/mtu3/mtu3_debugfs.c > > @@ -528,8 +528,7 @@ void ssusb_dr_debugfs_init(struct ssusb_mtk *ssusb) > > > > void ssusb_debugfs_create_root(struct ssusb_mtk *ssusb) > > { > > - ssusb->dbgfs_root = > > - debugfs_create_dir(dev_name(ssusb->dev), usb_debug_root); > > + ssusb->dbgfs_root = debugfs_create_dir(dev_name(ssusb->dev), NULL); > > This moves the directory to a new location no matter what the > configuration is. What's wrong with where it is today? it seems usb_debug_root is only for host, but not for gadget only, it's defined and created in usb/core/usb.c > And shoudn't we > create the usb root directory if only gadget is enabled? Yes, need modify udc/core.c, it's better if support it, do you want me to send a patch for it? Thanks > > thanks, > > greg k-h From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chunfeng Yun Subject: Re: [RESEND PATCH] usb: mtu3: fix up undefined reference to usb_debug_root Date: Fri, 24 May 2019 17:25:51 +0800 Message-ID: <1558689951.10179.422.camel@mhfsdcap03> References: <20190524074552.GA1080@kroah.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20190524074552.GA1080@kroah.com> Sender: linux-kernel-owner@vger.kernel.org To: Greg Kroah-Hartman Cc: Matthias Brugger , Randy Dunlap , linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org List-Id: linux-mediatek@lists.infradead.org On Fri, 2019-05-24 at 09:45 +0200, Greg Kroah-Hartman wrote: > On Fri, May 24, 2019 at 02:11:33PM +0800, Chunfeng Yun wrote: > > When CONFIG_USB is not set, and CONFIG_USB_GADGET is set, > > there is an issue: > > > > ld: > > drivers/usb/mtu3/mtu3_debugfs.o: in function 'ssusb_debugfs_create_root': > > mtu3_debugfs.c:(.text+0xba3): undefined reference to 'usb_debug_root' > > > > usb_debug_root is only built when CONFIG_USB is enabled, so here drop it > > and use NULL instead. > > > > Reported-by: Randy Dunlap > > Signed-off-by: Chunfeng Yun > > Acked-by: Randy Dunlap > > --- > > drivers/usb/mtu3/mtu3_debugfs.c | 3 +-- > > 1 file changed, 1 insertion(+), 2 deletions(-) > > Why resend? Sorry, I should send it out as v2 due to acked-by is added. > > > diff --git a/drivers/usb/mtu3/mtu3_debugfs.c b/drivers/usb/mtu3/mtu3_debugfs.c > > index 62c57ddc554e..b7c86ccd50b4 100644 > > --- a/drivers/usb/mtu3/mtu3_debugfs.c > > +++ b/drivers/usb/mtu3/mtu3_debugfs.c > > @@ -528,8 +528,7 @@ void ssusb_dr_debugfs_init(struct ssusb_mtk *ssusb) > > > > void ssusb_debugfs_create_root(struct ssusb_mtk *ssusb) > > { > > - ssusb->dbgfs_root = > > - debugfs_create_dir(dev_name(ssusb->dev), usb_debug_root); > > + ssusb->dbgfs_root = debugfs_create_dir(dev_name(ssusb->dev), NULL); > > This moves the directory to a new location no matter what the > configuration is. What's wrong with where it is today? it seems usb_debug_root is only for host, but not for gadget only, it's defined and created in usb/core/usb.c > And shoudn't we > create the usb root directory if only gadget is enabled? Yes, need modify udc/core.c, it's better if support it, do you want me to send a patch for it? Thanks > > thanks, > > greg k-h From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,T_DKIMWL_WL_HIGH,UNPARSEABLE_RELAY,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 076FAC072B5 for ; Fri, 24 May 2019 09:26:13 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 CF411217F9 for ; Fri, 24 May 2019 09:26:12 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="QjLeTmCj" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CF411217F9 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=mediatek.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Date:To:From:Subject:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=C8L3qrT2Fk+N9clyIVUKwzWUJeLZifD3N0/LqSls7tE=; b=QjLeTmCjA1S5+W KeCQL8QgEDQuygjI6nACC++9SiioOIljwQcY9sy96B09CmpoP4X/UQf2xk5NK3a0vxF6gNrAkMkvu gtK3KV/ZOoCXGKbYg4bSKnWJPNtMuD7oCQLFPAjr+FoSwvYVzAGh3fH2P0qCc0MnvJIhDKuY+QIJr e0AHLI4OUL3+pHIsvicSyTwLjoZshaHBksOpyLtFRN82hH2RPFF0OKUsVyQ3yhhtoYW2PQpijrBIv QAxq0uL/JXwCIVF+2O4r6SlTuZ6DI98r9GClETmaEFtpz3MM8jHwBYN9hMTdAoGmAoUD42XlFixx0 LUE731ZjZwKqLTXNJLSA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hU6Sj-0008NX-GD; Fri, 24 May 2019 09:26:05 +0000 Received: from mailgw01.mediatek.com ([216.200.240.184]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hU6Sg-0008N2-0a; Fri, 24 May 2019 09:26:03 +0000 X-UUID: e59c6b71c41f4e17a30bb24133059496-20190524 X-UUID: e59c6b71c41f4e17a30bb24133059496-20190524 Received: from mtkcas67.mediatek.inc [(172.29.193.45)] by mailgw01.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLS) with ESMTP id 1131723545; Fri, 24 May 2019 01:25:56 -0800 Received: from MTKMBS31N1.mediatek.inc (172.27.4.69) by MTKMBS62N1.mediatek.inc (172.29.193.41) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Fri, 24 May 2019 02:25:54 -0700 Received: from MTKCAS32.mediatek.inc (172.27.4.184) by MTKMBS31N1.mediatek.inc (172.27.4.69) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Fri, 24 May 2019 17:25:52 +0800 Received: from [10.17.3.153] (172.27.4.253) by MTKCAS32.mediatek.inc (172.27.4.170) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Fri, 24 May 2019 17:25:51 +0800 Message-ID: <1558689951.10179.422.camel@mhfsdcap03> Subject: Re: [RESEND PATCH] usb: mtu3: fix up undefined reference to usb_debug_root From: Chunfeng Yun To: Greg Kroah-Hartman Date: Fri, 24 May 2019 17:25:51 +0800 In-Reply-To: <20190524074552.GA1080@kroah.com> References: <20190524074552.GA1080@kroah.com> X-Mailer: Evolution 3.2.3-0ubuntu6 MIME-Version: 1.0 X-MTK: N X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190524_022602_059548_8A85068C X-CRM114-Status: GOOD ( 17.97 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-usb@vger.kernel.org, Randy Dunlap , linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, Matthias Brugger , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, 2019-05-24 at 09:45 +0200, Greg Kroah-Hartman wrote: > On Fri, May 24, 2019 at 02:11:33PM +0800, Chunfeng Yun wrote: > > When CONFIG_USB is not set, and CONFIG_USB_GADGET is set, > > there is an issue: > > > > ld: > > drivers/usb/mtu3/mtu3_debugfs.o: in function 'ssusb_debugfs_create_root': > > mtu3_debugfs.c:(.text+0xba3): undefined reference to 'usb_debug_root' > > > > usb_debug_root is only built when CONFIG_USB is enabled, so here drop it > > and use NULL instead. > > > > Reported-by: Randy Dunlap > > Signed-off-by: Chunfeng Yun > > Acked-by: Randy Dunlap > > --- > > drivers/usb/mtu3/mtu3_debugfs.c | 3 +-- > > 1 file changed, 1 insertion(+), 2 deletions(-) > > Why resend? Sorry, I should send it out as v2 due to acked-by is added. > > > diff --git a/drivers/usb/mtu3/mtu3_debugfs.c b/drivers/usb/mtu3/mtu3_debugfs.c > > index 62c57ddc554e..b7c86ccd50b4 100644 > > --- a/drivers/usb/mtu3/mtu3_debugfs.c > > +++ b/drivers/usb/mtu3/mtu3_debugfs.c > > @@ -528,8 +528,7 @@ void ssusb_dr_debugfs_init(struct ssusb_mtk *ssusb) > > > > void ssusb_debugfs_create_root(struct ssusb_mtk *ssusb) > > { > > - ssusb->dbgfs_root = > > - debugfs_create_dir(dev_name(ssusb->dev), usb_debug_root); > > + ssusb->dbgfs_root = debugfs_create_dir(dev_name(ssusb->dev), NULL); > > This moves the directory to a new location no matter what the > configuration is. What's wrong with where it is today? it seems usb_debug_root is only for host, but not for gadget only, it's defined and created in usb/core/usb.c > And shoudn't we > create the usb root directory if only gadget is enabled? Yes, need modify udc/core.c, it's better if support it, do you want me to send a patch for it? Thanks > > thanks, > > greg k-h _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel