Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp7567375rwi; Mon, 24 Oct 2022 16:56:44 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4JB8ZPTrxfqKMM+WHajVDeTZRiRxbKbZvx4ABYRC7a+gSYmQR9hJpZDJiGSN6EvLJ0/aP2 X-Received: by 2002:a63:5511:0:b0:439:12f6:fb9a with SMTP id j17-20020a635511000000b0043912f6fb9amr30897086pgb.197.1666655803758; Mon, 24 Oct 2022 16:56:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666655803; cv=none; d=google.com; s=arc-20160816; b=XAdjnQV8CD/Ypau9HUOOASaFYi/KHw9+EX9Rwz4p58MqJvUaLDIbjvygIiJAvZIKdQ M/TyjxdHAp7OC5V0B7edHaVRKP3kv59Az8GWt0sJVxvBSIWK1MInatXy5TCtxWEWi1dn HkgIG6oqHsAg101Y/XHRRhH63OZsD40pzE8o25QJA4fbcY59oBWyPMXi6tqQ9fEvjqY1 KL5MNVkdxr+fYZjLAkHjHXH8EACtlBIJWuNfU5cX1J5A717l6ap9A7hcFNjyOb28deHU FoIBWSwLO30A3wvpq64JndKMKRtp/uXsnSu9KxPm7YJxzyX4ggHQqwYXzFoXdpbpk/Ul sOUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=DZZ2rH46TVYJ7OPEtrme1f9RRklxhQp2hRpt50E13zU=; b=S3lTmx6HaXhERCV//Xbk4navtsB8+HDQiyEGCoBpFL/tyqu4ZxzR+Stk3NW5dCF9we J7qrQ7gn9tjSUkwJ4A/zfBuuBJAiWRyFcu63fesxnnh7+w5rftQhvc6qsgPW1+iQvz5d IynZ80pIukGhWLTabeAGaNBPXmsjxriuWGumRTbc2F5hQUrYZWLnlVjLYOTVO6JaTMaf 47XznqOePHJF+08BRVsbxCsbs1ZZ588BSl4ZZzsMLYB99fcAW8bMV9hz//2cG8tGf09I KnAOl2+hTLk3bi8FbsCcYRY4B7kn02gKRgjcn7XHVZM5G7/XxI/wM4LFwoOhXdqo6bd1 8TnA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=RxnUpi1b; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f8-20020a637548000000b0046b3ba2c807si947832pgn.143.2022.10.24.16.56.29; Mon, 24 Oct 2022 16:56:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=RxnUpi1b; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231455AbiJXXYB (ORCPT + 99 others); Mon, 24 Oct 2022 19:24:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60288 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231344AbiJXXXh (ORCPT ); Mon, 24 Oct 2022 19:23:37 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0119B17F2A8; Mon, 24 Oct 2022 14:44:40 -0700 (PDT) Received: from notapiano (unknown [194.36.25.51]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: nfraprado) by madras.collabora.co.uk (Postfix) with ESMTPSA id 7737B6602392; Mon, 24 Oct 2022 17:43:58 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1666629840; bh=4kWtLxHplFOS10HqVPq+7P3+dYq5PouJzYToXkZX4Kw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=RxnUpi1bDW82nmb44+goLMrowb5Wd9tioPQl7b/kkrgLASz3MA/H6Mfcrk1OWg9p0 kfT8CZT2IAaA5LedmtnGE+nyDEFDU9GMgEWulgV6pIC5lxMp8S63ZLYECm16UV3Vtl nmLjvBik0WwkbtjEKwi76XMOYyUlFA6ToQyYFUkrlAnhl3B+7dRnMg/uoTO/8+tPtG ueksg4mems9ce5/g7amf9L164rpyDn32FV4nTDlaf2rB1rdxE8SRYh1PpvbtovXUdP 0SXlzUsXOMhX+5Pbbfufsxf0NrisgDUYMQmSL0nog1TSoBOmBHnV7ANsQ9bvHiY72g s9ZX7RViGNyLQ== Date: Mon, 24 Oct 2022 12:43:53 -0400 From: =?utf-8?B?TsOtY29sYXMgRi4gUi4gQS4=?= Prado To: Frank Wunderlich Cc: linux-mediatek@lists.infradead.org, Frank Wunderlich , Chaotian Jing , Ulf Hansson , Rob Herring , Krzysztof Kozlowski , Matthias Brugger , Wenbin Mei , linux-mmc@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 2/7] dt-bindings: mmc: mtk-sd: Set clocks based on compatible Message-ID: <20221024164353.jzvx4ea442e4vahj@notapiano> References: <20221023091247.70586-1-linux@fw-web.de> <20221023091247.70586-3-linux@fw-web.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20221023091247.70586-3-linux@fw-web.de> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, thank you for picking this up. On Sun, Oct 23, 2022 at 11:12:42AM +0200, Frank Wunderlich wrote: > From: N?colas F. R. A. Prado > > The binding was describing a single clock list for all platforms, but > that's not really suitable: > > Most platforms using at least 2 clocks (source, hclk), some of them > a third "source_cg". Mt2712 requires an extra 'bus_clk' on some of > its controllers, while mt8192 requires 8 clocks. > > Move the clock definitions inside if blocks that match on the > compatibles. > > I used Patch from N?colas F. R. A. Prado and modified it to not using > "not" statement. > > Fixes: 59a23395d8aa ("dt-bindings: mmc: Add support for MT8192 SoC") > Signed-off-by: N?colas F. R. A. Prado > Signed-off-by: Frank Wunderlich > > --- > v2: > - add this patch > v3: > - add blank lines and change "not" to matchlist > - reorder entries - make generic first then order alphanumeric > - rewrite commit description > - drop soc-specific mt8183 - constraints were also set for it above This is wrong, see below. > --- > .../devicetree/bindings/mmc/mtk-sd.yaml | 113 +++++++++++++----- > 1 file changed, 83 insertions(+), 30 deletions(-) > > diff --git a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml > index 3cbf0208f1b4..31bb6dc329d2 100644 > --- a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml > +++ b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml [..] > > -if: > - properties: > - compatible: > - contains: > - const: mediatek,mt8183-mmc > -then: > - properties: > - reg: > - minItems: 2 You can't drop this. Nodes with the mt8183 compatible should keep requiring two reg values. It's not covered by the branch below. Thanks, N?colas > +allOf: > + - $ref: mmc-controller.yaml# > + - if: > + properties: > + compatible: > + enum: > + - mediatek,mt2701-mmc > + - mediatek,mt6779-mmc > + - mediatek,mt6795-mmc > + - mediatek,mt7620-mmc > + - mediatek,mt7622-mmc > + - mediatek,mt7623-mmc > + - mediatek,mt8135-mmc > + - mediatek,mt8173-mmc > + - mediatek,mt8183-mmc > + - mediatek,mt8186-mmc > + - mediatek,mt8188-mmc > + - mediatek,mt8195-mmc > + - mediatek,mt8516-mmc > + then: > + properties: > + clocks: > + minItems: 2 > + items: > + - description: source clock > + - description: HCLK which used for host > + - description: independent source clock gate > + clock-names: > + minItems: 2 > + items: > + - const: source > + - const: hclk > + - const: source_cg > + [..]