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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 774BBC4332F for ; Thu, 22 Dec 2022 11:30:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=wAK06CPaUdSjNZH05zx2x38m1+j2Zgw9OENtsj0EqSs=; b=Tu4RnkJeEWtCLu XRykU+jPhvy89Ta/FgwdE18ZjCw5CVXl9RiJ+QV2d1Jll1Qi7rsW9tngvXvEfjUYrZOZuM1rjp/Tt kNiMvDrii3/8vZaAmuL7lludZy0YPeplsBnB2ntxTUInUu0QRSf/bqdOcjyFgBpq746MvgEqfx1io jHlJM/6o3L2fJ7X7bElTp69vFuifLAGCptmS1RFv2cR+zIS82LqmB1qtB0HgEQ2ky7gmxFsf1YSqU RaNHEHNYuIlGWqF17cs6yfihcXi5tljmXTio/4rHhhKdcSZnOlxMnjqVZTK0LqP59ItIhPghWb5FZ LDnBI0ki/RHFR/XBU3/g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p8JlJ-00B55D-5i; Thu, 22 Dec 2022 11:29:21 +0000 Received: from mail-lf1-x12e.google.com ([2a00:1450:4864:20::12e]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p8Jka-00B4Is-ES for linux-arm-kernel@lists.infradead.org; Thu, 22 Dec 2022 11:28:38 +0000 Received: by mail-lf1-x12e.google.com with SMTP id m29so2259321lfo.11 for ; Thu, 22 Dec 2022 03:28:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=K5HqGkBqBzfZDqaAUotpMPHwjpp4zNjbUWE9MppZ23U=; b=JKYz9vhC6veCEOBUC5Klk4pvaJYmo/yasJsTQXQkAwGmBhbRDCpI8ZY+Vjv3di4OiX IkIJT24z9jxADAxhJOpfKTcth1YxrQJn5KOY1BWyXhBoYAyeKee2CuQxK9iLiEP+eGp0 6zvxwjipsTTmSt5LBhm7oPiP5d43zxYdDKzxUYG/nSofwendCncbqCUhjpUB91NNjf4K 3UEpP788W2k50ns4PzPDxiu8xQF5NFvuySFOlHR9zyQNe8QZBIjRt4yIQ60RtAJzJved 6KZth3Pgoxf1BG3nLvKiZxF+VjdCbsfJDGyrPaChMuT0bwSPoJVPKboQt0E55frP4gru ldVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=K5HqGkBqBzfZDqaAUotpMPHwjpp4zNjbUWE9MppZ23U=; b=L6N64bHISjg0reWSY0yI3GN0G95W8ue76IM5XhJGbNPqJoILYrDmz9GWEB+wCfmZv0 TMo2f0ZVs5DmHBGD0he0G4WNN+jkVoKnMZpfWVyCyLZobDz8pAuWMGEdZSImDm69qKkE oiKqg21KSeEJD+lrFpqJDmlNcuOcxO7RNbhBpndyJX+LeVko44DQD9dGBG49LSze1Dnv FBhLtgoMoAA/1Fi042y7YDgjWWZ8z6RUmfaFnraQzWvUGkCs1KgUZooOx30m1Y/Mt5S9 yGCqxa/howaSApfW5o2oPcvYZvMYMYFMEjb2N2Cegr6eJbILT17o5g17Ym95mV2CRUhI Xh0A== X-Gm-Message-State: AFqh2kro3B60GDxKHqPDCKN0Wl16xSndEJNOcuQofKAL/sUgUXY1iNjD CB2zusy7WnBhwDSx7PqxYpLKJQ== X-Google-Smtp-Source: AMrXdXvfkgKKBgus/9ew+CKIdUk8kg+3nsMPazKfH/x8M2NFqKqOkCh/SNIgCpwt+hd/0taBYSb1dA== X-Received: by 2002:a05:6512:3d94:b0:4a4:68b8:f4f4 with SMTP id k20-20020a0565123d9400b004a468b8f4f4mr1970535lfv.58.1671708513405; Thu, 22 Dec 2022 03:28:33 -0800 (PST) Received: from [192.168.0.20] (088156142067.dynamic-2-waw-k-3-2-0.vectranet.pl. [88.156.142.67]) by smtp.gmail.com with ESMTPSA id j10-20020a056512028a00b00499b1873d6dsm37956lfp.269.2022.12.22.03.28.32 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 22 Dec 2022 03:28:32 -0800 (PST) Message-ID: <17dc933d-e46c-ddfa-b185-5c24fa7dddb6@linaro.org> Date: Thu, 22 Dec 2022 12:28:31 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.0 Subject: Re: [PATCH v3 1/2] dt-bindings: pinctrl: add schema for NXP S32 SoCs Content-Language: en-US To: Chester Lin , Rob Herring , Linus Walleij , Krzysztof Kozlowski , =?UTF-8?Q?Andreas_F=c3=a4rber?= Cc: s32@nxp.com, linux-gpio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Larisa Grigore , Ghennadi Procopciuc , Andrei Stefanescu , Matthias Brugger References: <20221221073232.21888-1-clin@suse.com> <20221221073232.21888-2-clin@suse.com> From: Krzysztof Kozlowski In-Reply-To: <20221221073232.21888-2-clin@suse.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221222_032836_576504_BC873BA0 X-CRM114-Status: GOOD ( 26.41 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 21/12/2022 08:32, Chester Lin wrote: > Add DT schema for the pinctrl driver of NXP S32 SoC family. > > Signed-off-by: Larisa Grigore > Signed-off-by: Ghennadi Procopciuc > Signed-off-by: Chester Lin > --- > > Changes in v3: > - Remove the minItems from reg because there's no optional item for s32g2. > - List supported properties of pinmux-node and pincfg-node and add more > descriptions. > - Adjust the location of "required:". > - Fix descriptions and wordings. > - Rename the yaml file to nxp,s32g2-siul2-pinctrl.yaml. > > Changes in v2: > - Remove the "nxp,pins" property since it has been moved into the driver. > - Add descriptions for reg entries. > - Refine the compatible name from "nxp,s32g-..." to "nxp,s32g2-...". > - Fix schema issues and revise the example. > - Fix the copyright format suggested by NXP. > > .../pinctrl/nxp,s32g2-siul2-pinctrl.yaml | 129 ++++++++++++++++++ > 1 file changed, 129 insertions(+) > create mode 100644 Documentation/devicetree/bindings/pinctrl/nxp,s32g2-siul2-pinctrl.yaml > > diff --git a/Documentation/devicetree/bindings/pinctrl/nxp,s32g2-siul2-pinctrl.yaml b/Documentation/devicetree/bindings/pinctrl/nxp,s32g2-siul2-pinctrl.yaml > new file mode 100644 > index 000000000000..1554ce14214a > --- /dev/null > +++ b/Documentation/devicetree/bindings/pinctrl/nxp,s32g2-siul2-pinctrl.yaml > @@ -0,0 +1,129 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +# Copyright 2022 NXP > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/pinctrl/nxp,s32g2-siul2-pinctrl.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: NXP S32G2 pin controller > + > +maintainers: > + - Ghennadi Procopciuc > + - Chester Lin > + > +description: | > + S32G2 pinmux is implemented in SIUL2 (System Integration Unit Lite2), > + whose memory map is split into two regions: > + SIUL2_0 @ 0x4009c000 > + SIUL2_1 @ 0x44010000 > + > + Every SIUL2 region has multiple register types, and here only MSCR and > + IMCR registers need to be revealed for kernel to configure pinmux. > + > + Please note that some register indexes are reserved in S32G2, such as > + MSCR102-MSCR111, MSCR123-MSCR143, IMCR84-IMCR118 and IMCR398-IMCR429. > + > +properties: > + compatible: > + enum: > + - nxp,s32g2-siul2-pinctrl > + > + reg: > + description: | > + A list of MSCR/IMCR register regions to be reserved. > + - MSCR (Multiplexed Signal Configuration Register) > + An MSCR register can configure the associated pin as either a GPIO pin > + or a function output pin depends on the selected signal source. > + - IMCR (Input Multiplexed Signal Configuration Register) > + An IMCR register can configure the associated pin as function input > + pin depends on the selected signal source. > + items: > + - description: MSCR registers group 0 in SIUL2_0 > + - description: MSCR registers group 1 in SIUL2_1 > + - description: MSCR registers group 2 in SIUL2_1 > + - description: IMCR registers group 0 in SIUL2_0 > + - description: IMCR registers group 1 in SIUL2_1 > + - description: IMCR registers group 2 in SIUL2_1 > + > +patternProperties: > + '-pins$': > + type: object > + additionalProperties: false > + > + patternProperties: > + '-grp[0-9]$': > + type: object > + allOf: > + - $ref: pinmux-node.yaml# > + - $ref: pincfg-node.yaml# > + description: | > + Pinctrl node's client devices specify pin muxes using subnodes, > + which in turn use the standard properties below. > + > + properties: > + bias-disable: true > + bias-high-impedance: true > + bias-pull-up: true > + bias-pull-down: true > + drive-open-drain: true > + input-enable: true > + output-enable: true > + > + pinmux: > + description: | > + An integer array for representing pinmux configurations of > + a device. Each integer consists of a PIN_ID and a 4-bit > + selected signal source(SSS) as IOMUX setting, which is > + calculated as: pinmux = (PIN_ID << 4 | SSS) > + > + slew-rate: > + description: | > + 0: 208MHz > + 1-3: Reserved > + 4: 166MHz > + 5: 150MHz > + 6: 133MHz > + 7: 83MHz > + enum: [0, 4, 5, 6, 7] You have known values, then use them. This is much more readable in DTS. Best regards, Krzysztof _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel