Received: by 10.223.176.5 with SMTP id f5csp1508257wra; Wed, 7 Feb 2018 21:53:34 -0800 (PST) X-Google-Smtp-Source: AH8x226qkktS6UlyJfLGO8h7YD7TFYm3g8FaEnVlcnCZEvGLVTR3gtZ+QkYBU9Ci0EfuVlombkl8 X-Received: by 10.98.35.211 with SMTP id q80mr8253468pfj.64.1518069214561; Wed, 07 Feb 2018 21:53:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518069214; cv=none; d=google.com; s=arc-20160816; b=x0Bg9HEyu0YfrzvdrnDtqPEPYjx3E33Oko7J3xwGCgCQEqWeSHswnIhbbetQGSBANf eVqf4XkcCaYSwyh/tNMpTlstAvuJakenxiBuF9CAJfLbAQ8n69zJ4uInlwO6KJqLolrH GTa0n+jDtngK7T+wREs9S43AumvsbNiWBSwo6FzIDiY7YEHnZFqJVkei5QVUBjXQSuUY SuXLJSqvmrkO8wSvxynQRzvcQI0x4NwKmlbFymqz1AFUUX0zkVg2inC5pUXX4d8zOht4 vUAvvR1b7zj0ojDyQyydRBEqyWXMD+tlYSZTgql66UN1eiTZwJ+1iQH4rC7PwqTcjAAA WxXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :references:in-reply-to:date:cc:to:from:subject:message-id :arc-authentication-results; bh=WJb3q/H4P/k795C3knLTIqVMB9tlQTqN8Rbe3T1IrE8=; b=WtzRnTk/y/c+WQOxXlP04fBcbzrYkqVrSaLPxMLPZMwpQAVCGv4TbPjVQg8o9V5C/y 1y2RiDmPxx6DR8k3U9E9R6M10LhzA0PcbipYuaOSIOhRy0hcCmyCPyt+kBxqXd2+wghy hyUUVnj1bxtEedDDTWtwJaVsANkMxEuPxzrHuCutSMyvmEMVQe1HwxH5IlDkVQrSAFu6 +empeh6a9zIhjyo6rvSqt6AXq3JPSbsV/J3Y7WHpqgjMPTXQe+XCENlm6UkxvS1ua3Lc izzpd6ZhpQbzHwhbG9fI0MhDwzUbeTrqMs+emitruAajZrupyVQNPZ71SZuVD2/+oEFE 7A1g== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f4-v6si993292plf.59.2018.02.07.21.52.49; Wed, 07 Feb 2018 21:53:34 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750873AbeBHFvL (ORCPT + 99 others); Thu, 8 Feb 2018 00:51:11 -0500 Received: from mailgw02.mediatek.com ([210.61.82.184]:8390 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1750766AbeBHFvJ (ORCPT ); Thu, 8 Feb 2018 00:51:09 -0500 X-UUID: 42840e3e02314102b5d2d9e438c74c6d-20180208 Received: from mtkexhb01.mediatek.inc [(172.21.101.102)] by mailgw02.mediatek.com (envelope-from ) (mhqrelay.mediatek.com ESMTP with TLS) with ESMTP id 228960732; Thu, 08 Feb 2018 13:51:06 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by mtkmbs08n2.mediatek.inc (172.21.101.56) with Microsoft SMTP Server (TLS) id 15.0.1210.3; Thu, 8 Feb 2018 13:51:05 +0800 Received: from [172.21.77.33] (172.21.77.33) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1210.3 via Frontend Transport; Thu, 8 Feb 2018 13:51:05 +0800 Message-ID: <1518069065.24094.48.camel@mtkswgap22> Subject: Re: [PATCH v2 4/5] dt-bindings: clock: mediatek: update audsys documentation to adapt MFD device From: Ryder Lee To: Rob Herring CC: , Garlic Tseng , Stephen Boyd , "linux-kernel@vger.kernel.org" , Mark Brown , , Matthias Brugger , Lee Jones , linux-clk , "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" Date: Thu, 8 Feb 2018 13:51:05 +0800 In-Reply-To: References: <8651585c91ee40f6ab3e30b893bcfb90fe5c2c25.1515639336.git.ryder.lee@mediatek.com> <20180205060833.p56dun5i4bvs3jye@rob-hp-laptop> <1517821892.12510.32.camel@mtkswgap22> 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 Wed, 2018-02-07 at 18:49 -0600, Rob Herring wrote: > >> > diff --git a/Documentation/devicetree/bindings/arm/mediatek/mediatek,audsys.txt b/Documentation/devicetree/bindings/arm/mediatek/mediatek,audsys.txt > >> > index 9b8f578..677af40 100644 > >> > --- a/Documentation/devicetree/bindings/arm/mediatek/mediatek,audsys.txt > >> > +++ b/Documentation/devicetree/bindings/arm/mediatek/mediatek,audsys.txt > >> > @@ -1,22 +1,45 @@ > >> > -MediaTek AUDSYS controller > >> > +MediaTek Audio Subsystem > >> > ============================ > >> > +The audio subsystem is one of the multi-function blocks of MediaTek SoCs. > >> > +It contains a system controller, which provides a number registers giving > >> > +access to two features: AUDSYS clocks and Audio Front End (AFE) components. > >> > > >> > +For the top level node: > >> > +- compatible: must be: "syscon", "simple-mfd"; > >> > >> This should have some SoC specific compatible. > > > > As we don't have a specific driver (compatible string) for it and if we > > need to add that I think the term '*-audsys' is very suitable here, but > > unfortunately, it has already picked for clock driver (see child node). > > Perhaps the clocks block should have "-clk" on the end or something. > > Why do you really need to change this in the first place? You don't > have to have DT child nodes to create child (struct) devices and child > drivers. > I'm not sure I get your point. Did you mean that we could have a parent (which represents clock and its compatible is something like "*-audsys","syscon","simple-mfd") with a subnode for audio function? If so, there's no special reason. I just think it more specifically to let people know we have an MFD (top node) and it has two sub-functions (children) share the same region. > >> > +Required sub-nodes: > >> > + > >> > +AUDSYS clocks: > >> > +------- > >> > The MediaTek AUDSYS controller provides various clocks to the system. > >> > > >> > Required Properties: > >> > > >> > - compatible: Should be one of: > >> > - - "mediatek,mt7622-audsys", "syscon" > >> > + - "mediatek,mt2701-audsys"; > >> > + - "mediatek,mt7622-audsys"; > >> > - #clock-cells: Must be 1 > >> > > >> > The AUDSYS controller uses the common clk binding from > >> > Documentation/devicetree/bindings/clock/clock-bindings.txt > >> > The available clocks are defined in dt-bindings/clock/mt*-clk.h. > >> > >> There's no register range associated with the clocks? If there is, add a > >> reg property. > > > > No, we don't need reg property here, as the two sub-drivers will obtain > > the regmap which is propagated from the parent. > > I know regmap doesn't need it. That's not what I asked. If you have a > range of registers for the clocks, then define that in reg. Only if > the clock control bits are mixed up with other functions within the > same registers, then you can omit it. > Oh okay, I didn't read the mail well. We have four or five registers for the clocks, but one of them (offset:0x634) is mixed up with the audio function (bit 17-19), so I omit it. Ryder.