Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp4499874ybc; Fri, 15 Nov 2019 05:45:42 -0800 (PST) X-Google-Smtp-Source: APXvYqw7lZTGl5s1PevSrTGhWGxgwwDswoDLQi6zvQTwFnGP5C3xru6z1kWzhYLQGK85xx4T64E+ X-Received: by 2002:a17:906:e297:: with SMTP id gg23mr1057857ejb.41.1573825542381; Fri, 15 Nov 2019 05:45:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573825542; cv=none; d=google.com; s=arc-20160816; b=fhHfosgqGepaz9fSVGR1PW1QeHCbVYf15TMFlVUFvELuk9k+qJ8BvD6G7FpJ0uwCH6 2og4+uf7xsWX+2PcuAqn6NgSCaUZyhzdjsoQeR0V4yZsqUvoC1FpkwsG6laZ4ErkKx6w 9XB2ncwviCCtuOhYriMJmJ8zIAN8ajWZpXj5bv0LoeMOYYvfTFhkSRxbHswPhKnnsb5q E26dDuTZsFuQ5I2E9OtzDYw9LdMacqfIUe+a8ON9355AvGy2y0kdV6GlrqSfKHSnsSrf iz6kzrmkMbgGvGHruMOPlSo4XJYtwTpW3TxorbJnp/xHlcvc+x6zTRupXTTRatqidYT7 0dVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:mail-followup-to :message-id:subject:cc:to:from:date:dkim-signature; bh=0GMF8waTlZ/mMmEu9OdTiNMpJgRZ1U+24RV0VdCAq3s=; b=bjMuvdS2uImndBzUq66IVJwOGrKS3CqXGdDLWl+JwAaLSe7rli/jdXsZPYY06CORjc ZmSxUACcC425klfmjJ9Y3RHfZlb9asREGZVfRNkGvLyhsxNsqjB9u3d4JE6ZjJuUGo2D wgUKSmIGbipnaRaQUCBBFIXBWDatmWXJ2vtjxz19b1zZBE+6kbJZA6xFikckS6szE+Nn KYujTptMXgegCzccmorojRWiP3e72LapX0MHzhfCWK/0jb11c+qbvvoMPmq9tRwg2Xjv BDTuSR/D3ExiQrjZT6Af8ijl0MYI/UyI2cANgVRJlR3srKnjMNhezu5AoqQzo/LnE1Kz igQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=fXpOKUav; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b9si6475106eda.115.2019.11.15.05.45.16; Fri, 15 Nov 2019 05:45:42 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=fXpOKUav; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727569AbfKONoI (ORCPT + 99 others); Fri, 15 Nov 2019 08:44:08 -0500 Received: from fllv0015.ext.ti.com ([198.47.19.141]:38750 "EHLO fllv0015.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727249AbfKONoH (ORCPT ); Fri, 15 Nov 2019 08:44:07 -0500 Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id xAFDhENw021665; Fri, 15 Nov 2019 07:43:14 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1573825394; bh=0GMF8waTlZ/mMmEu9OdTiNMpJgRZ1U+24RV0VdCAq3s=; h=Date:From:To:CC:Subject:References:In-Reply-To; b=fXpOKUavZPJUxNL9lEFn7zZNVLFYuhGojcJgORZ0h/BB4qyRFo6mrlCOsH4ERQeHs h9leKq2A0Fj6bzJ4IDPmzVMYiipwgHWHf4mYsJ2/6ss1dHgt4T7A8cxc/hktAUYZHd PabnC59jQNgb5DLLinNwWV5dTN5f0x+2iBMNsWMU= Received: from DFLE104.ent.ti.com (dfle104.ent.ti.com [10.64.6.25]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id xAFDhELd079797 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 15 Nov 2019 07:43:14 -0600 Received: from DFLE114.ent.ti.com (10.64.6.35) by DFLE104.ent.ti.com (10.64.6.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3; Fri, 15 Nov 2019 07:43:14 -0600 Received: from lelv0326.itg.ti.com (10.180.67.84) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3 via Frontend Transport; Fri, 15 Nov 2019 07:43:14 -0600 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by lelv0326.itg.ti.com (8.15.2/8.15.2) with ESMTP id xAFDhEow098885; Fri, 15 Nov 2019 07:43:14 -0600 Date: Fri, 15 Nov 2019 07:45:30 -0600 From: Bin Liu To: Greg Kroah-Hartman CC: Chunfeng Yun , Felipe Balbi , Laurent Pinchart , Mauro Carvalho Chehab , Peter Chen , Minas Harutyunyan , Cristian Birsan , Nicolas Ferre , Alexandre Belloni , Ludovic Desroches , Kevin Cernekee , Florian Fainelli , , Daniel Mack , Haojian Zhuang , Robert Jarzmik , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Matthias Brugger , Stephen Boyd , Yoshihiro Shimoda , Colin Ian King , Biju Das , Fabrizio Castro , "Gustavo A. R. Silva" , Yangtao Li , , , , , Subject: Re: [PATCH v2 05/13] usb: musb: create debugfs directory under usb root Message-ID: <20191115134530.GB12511@uda0271908> Mail-Followup-To: Bin Liu , Greg Kroah-Hartman , Chunfeng Yun , Felipe Balbi , Laurent Pinchart , Mauro Carvalho Chehab , Peter Chen , Minas Harutyunyan , Cristian Birsan , Nicolas Ferre , Alexandre Belloni , Ludovic Desroches , Kevin Cernekee , Florian Fainelli , bcm-kernel-feedback-list@broadcom.com, Daniel Mack , Haojian Zhuang , Robert Jarzmik , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Matthias Brugger , Stephen Boyd , Yoshihiro Shimoda , Colin Ian King , Biju Das , Fabrizio Castro , "Gustavo A. R. Silva" , Yangtao Li , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org References: <1573541519-28488-1-git-send-email-chunfeng.yun@mediatek.com> <1573541519-28488-5-git-send-email-chunfeng.yun@mediatek.com> <20191112152857.GA5853@uda0271908> <20191114032018.GA122287@kroah.com> <20191114140234.GB5853@uda0271908> <20191115032153.GC793701@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20191115032153.GC793701@kroah.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 15, 2019 at 11:21:53AM +0800, Greg Kroah-Hartman wrote: > On Thu, Nov 14, 2019 at 08:02:34AM -0600, Bin Liu wrote: > > On Thu, Nov 14, 2019 at 11:20:18AM +0800, Greg Kroah-Hartman wrote: > > > On Tue, Nov 12, 2019 at 09:28:57AM -0600, Bin Liu wrote: > > > > Hi, > > > > > > > > On Tue, Nov 12, 2019 at 02:51:51PM +0800, Chunfeng Yun wrote: > > > > > Now the USB gadget subsystem can use the USB debugfs root directory, > > > > > so move musb's directory from the root of the debugfs filesystem into > > > > > the root of usb > > > > > > > > My opinion is this move is unnecessary. I breaks existing debug tools or > > > > documentation which is already published on Internet. > > > > > > Having a "root" directory for a single random driver seems like you are > > > making your driver a "very important" thing in the overall scheme of the > > > kernel, right? What's wrong with using the usb subdirectory like all > > > > Agree, it wasn't the right thing to do at the first place. But now > > changing it adds support burden, because people very often refer to the > > old information on the internet which no longer matches to the new > > location. Basically, it is a cost of ABI change. > > What information says that /sys/kernel/debug/mdev/ is the location for > this? Is it in-kernel? No, they are not in-kernel, but many places mainly on https://e2e.ti.com and http://processors.wiki.ti.com. It basically says to get musb regdump, cat /sys/kernel/debug/musb-hdrc.{0,1}/regdump, or to enter test mode, do echo _testmode_ > /sys/kernel/debug/musb-hdrc.{0,1}/testmode... > > > other USB drivers use (after this patch series is merged)? That feels > > > like a much more "sane" way to handle the wide-open debugfs namespace. > > > > Though I commented on this musb patch, my opinion is for this whole > > series, either drop the whole series or apply the whole series. > > I've applied all but this one and 2 others that did not build properly. Okay. > > > Yes, there are no rules when it comes to debugfs file names and > > > locations, but let's try to be sane please. > > > > Fine with me. I can still support questions such as "can't open > > /sys/kernel/debug/musb-hdrc.0/testmode: No such file or directory". > > What tool looks for that? I wrote a usb diagnosis tool called chkusb.sh, which basically checks usb related information in - /proc/config.gz - /lib/modules/`uname -r`/kernel/drivers/ - /proc/device-tree/ - /sys/device/ - /sys/kernel/debug/ So whenever I got a report on e2e.ti.com saying that usb doesn't work, I just post this script and get a log which would give a clue if there was any fundamental mistake in kernel configuration or deployment. But not a big issue here for this tool regarding this patch set, I can update the script to check both locations - /sys/kernel/debug/ and /sys/kernel/debug/usb/. -Bin.