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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8355DC433EF for ; Fri, 15 Jul 2022 07:57:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232596AbiGOH5V (ORCPT ); Fri, 15 Jul 2022 03:57:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56192 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229613AbiGOH5V (ORCPT ); Fri, 15 Jul 2022 03:57:21 -0400 Received: from mail-lj1-x229.google.com (mail-lj1-x229.google.com [IPv6:2a00:1450:4864:20::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1E3CB7D7B8 for ; Fri, 15 Jul 2022 00:57:20 -0700 (PDT) Received: by mail-lj1-x229.google.com with SMTP id w2so4849768ljj.7 for ; Fri, 15 Jul 2022 00:57:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=pVS+MTH1XwU1cvawHiiTO1k5At4xPOvBRcWn0E0JKnQ=; b=nPbUHaxTybTz+hSdJPP6CMy/vM/46yKwRrdEcsM8O2DT/PEmEm8ExTH8fb2rzJxdNf xjorId7Lq1mqbvJSYX2eyWQlr2irAmSAS6rnsqJDpmwkL+6QGJrJDDAQyzR9Iy8xuw+W G2Ytl4E09lz7ry/bTjvMUCO5DGdJuNBD5GGICRvvIb1oJkkbuio9/j0nVaKx0WPjH71e +AvFWG+fw+j8KIMVJGW2e2zw/kH23rcpmVVe6i5I+58UpQ0pAGEMQ0Ab8I1eatNJjP6W PSc5bjLGmcyTLTiBxDZGy1rct8c9+FJxaOOz8NoDM7ZjauLPS6uNYjJzZUgZotVcLO5+ wEfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=pVS+MTH1XwU1cvawHiiTO1k5At4xPOvBRcWn0E0JKnQ=; b=SmCA0Xp5NeO3nkDWeo9AkJxPrea7HcVSbKU3fO74+68bx7GDQKLRQQ/HxGVlhjVB/k 8q5dvsSuvYXylotQv6516Q7R81n0MY94DkqrfSapGBQ9nECSLBwusLiWHE8VnTuNmhVU WIM0+BnEC+TEsVveroX/wgYg0RbeeYSEzCD8sVz6EtF1AVnZ0Lp70ROOrSmvz5rLG5gD IXYzcei/oV3C5eX/JbNhw0c+vlCkZLLMajzPSk4AqZ0VaoZOx4PqsY/1O3K2l7brxl8H cITEBkhRPRPgVdRZcwb6/wB3FnuQEvdy4bvz/PehYBfIP4y7lnss/nCSO4WZP3aDB+NI Jmqg== X-Gm-Message-State: AJIora8+WvfadnikOfvpTTdnBLlnfg5Ejn9A1eyOgx+9NaTJ6e9jcbYr J8wOxG0xjvbZiS0vZf5b1MqPtg== X-Google-Smtp-Source: AGRyM1ulJRngwtrHtmZz4bY0FMFRN0qrWGaMpBxRh+yPkwrRe6nsqVmc0rblcJXm/KEw4Ov5c3GRWw== X-Received: by 2002:a2e:9854:0:b0:25d:883d:faf2 with SMTP id e20-20020a2e9854000000b0025d883dfaf2mr6010968ljj.223.1657871838444; Fri, 15 Jul 2022 00:57:18 -0700 (PDT) Received: from [10.0.0.8] (fwa5da9-171.bb.online.no. [88.93.169.171]) by smtp.gmail.com with ESMTPSA id b13-20020a056512070d00b0048960b581e3sm778642lfs.8.2022.07.15.00.57.15 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 15 Jul 2022 00:57:17 -0700 (PDT) Message-ID: <46df4ad5-5102-b5fe-95b7-5b157fb28f01@linaro.org> Date: Fri, 15 Jul 2022 09:57:14 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH v2 03/19] dt-bindings: power: mediatek: Add bindings for MediaTek SCPSYS Content-Language: en-US To: Tinghan Shen , Yong Wu , Joerg Roedel , Will Deacon , Rob Herring , Krzysztof Kozlowski , Lee Jones , Matthias Brugger , Chun-Jie Chen , AngeloGioacchino Del Regno , MandyJH Liu , Weiyi Lu Cc: iommu@lists.linux.dev, linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Project_Global_Chrome_Upstream_Group@mediatek.com References: <20220714122837.20094-1-tinghan.shen@mediatek.com> <20220714122837.20094-4-tinghan.shen@mediatek.com> From: Krzysztof Kozlowski In-Reply-To: <20220714122837.20094-4-tinghan.shen@mediatek.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On 14/07/2022 14:28, Tinghan Shen wrote: > The System Control Processor System (SCPSYS) has several power > management related tasks in the system. Add the bindings for it. > > Signed-off-by: Tinghan Shen > --- > .../bindings/mfd/mediatek,scpsys.yaml | 62 +++++++++++++++++++ > 1 file changed, 62 insertions(+) > create mode 100644 Documentation/devicetree/bindings/mfd/mediatek,scpsys.yaml > > diff --git a/Documentation/devicetree/bindings/mfd/mediatek,scpsys.yaml b/Documentation/devicetree/bindings/mfd/mediatek,scpsys.yaml > new file mode 100644 > index 000000000000..a8b9220f2f27 > --- /dev/null > +++ b/Documentation/devicetree/bindings/mfd/mediatek,scpsys.yaml > @@ -0,0 +1,62 @@ > +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/mfd/mediatek,scpsys.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: MediaTek System Control Processor System > + > +maintainers: > + - MandyJH Liu > + > +description: > + MediaTek System Control Processor System (SCPSYS) has several > + power management tasks. The tasks include MTCMOS power > + domain control, thermal measurement, DVFS, etc. > + > +properties: > + compatible: > + items: > + - const: mediatek,scpsys > + - const: syscon > + - const: simple-mfd > + > + reg: > + maxItems: 1 > + > + power-controller: > + $ref: /schemas/power/mediatek,power-controller.yaml# > + > +required: > + - compatible > + - reg > + > +additionalProperties: false > + > +examples: > + - | > + #include > + #include > + > + syscon@10006000 { > + compatible = "mediatek,scpsys", "syscon", "simple-mfd"; This should be a SoC-specific compatible (and filename). > + reg = <0x10006000 0x100>; > + > + spm: power-controller { I think you created before less-portable, quite constrained bindings for power controller. You now require that mt8195-power-controller is always a child of some parent device which will share its regmap/MMIO with it. And what if in your next block there is no scpsys block and power controller is the scpsys alone? It's not possible with your bindings. Wouldn't it be better to assign some address space to the power-controller (now as an offset from scpsys)? This is just wondering (Rockchip did the same...) and not a blocker as power-controller bindings are done. Best regards, Krzysztof