All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Eduard Bostina <egbostina@gmail.com>
Cc: Conor Dooley <conor+dt@kernel.org>,
	devicetree@vger.kernel.org,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Linus Walleij <linusw@kernel.org>,
	linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
	daniel.baluta@nxp.com, simona.toaca@nxp.com,
	goledhruva@gmail.com, m-chawdhry@ti.com
Subject: Re: [PATCH v2] dt-bindings: pinctrl: Convert TI DA850 pupd to DT schema
Date: Tue, 11 Aug 2026 13:06:21 -0500	[thread overview]
Message-ID: <20260811180621.GA2749647-robh@kernel.org> (raw)
In-Reply-To: <20260811111023.721262-1-egbostina@gmail.com>

On Tue, Aug 11, 2026 at 11:10:23AM +0000, Eduard Bostina wrote:
> Convert the Texas Instruments DA850/OMAP-L138/AM18x pullup/down
> controller bindings to DT schema.
> 
> Signed-off-by: Eduard Bostina <egbostina@gmail.com>
> ---
> Changes in v2:
> - Excluded the 'phandle' property from the pin group node pattern so
>   it is no longer validated as a pin configuration node. This fixes
>   the 'make dt_binding_check' failure.
> 
> Link to v1:
> https://lore.kernel.org/all/20260811092057.687155-1-egbostina@gmail.com/
> 
>  .../bindings/pinctrl/ti,da850-pupd.txt        | 55 --------------
>  .../bindings/pinctrl/ti,da850-pupd.yaml       | 74 +++++++++++++++++++
>  2 files changed, 74 insertions(+), 55 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/pinctrl/ti,da850-pupd.txt
>  create mode 100644 Documentation/devicetree/bindings/pinctrl/ti,da850-pupd.yaml


> diff --git a/Documentation/devicetree/bindings/pinctrl/ti,da850-pupd.yaml b/Documentation/devicetree/bindings/pinctrl/ti,da850-pupd.yaml
> new file mode 100644
> index 000000000000..059da050e611
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/pinctrl/ti,da850-pupd.yaml
> @@ -0,0 +1,74 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/pinctrl/ti,da850-pupd.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Texas Instruments DA850/OMAP-L138/AM18x Pin Configuration
> +
> +maintainers:
> +  - Eduard Bostina <egbostina@gmail.com>
> +
> +description:
> +  These SoCs have a separate controller for setting bias (internal pullup/down).
> +  Bias can only be selected for groups rather than individual pins.
> +  The controller node also acts as a container for pin group configuration nodes.
> +  The names of these groups are ignored.
> +
> +properties:
> +  compatible:
> +    const: ti,da850-pupd
> +
> +  reg:
> +    maxItems: 1
> +
> +  pinctrl-0: true
> +  pinctrl-names: true
> +
> +patternProperties:
> +  "-groups$":
> +    type: object
> +    additionalProperties: false
> +    patternProperties:
> +      "^(?!phandle$)[a-zA-Z0-9_-]+$":

Looks like '^(disable|pull-(up|down))$' would work here. Actual users 
only have 'disable'.


> +        $ref: /schemas/pinctrl/pincfg-node.yaml#
> +        properties:
> +          groups:
> +            $ref: /schemas/types.yaml#/definitions/string-array
> +            description: An array of strings containing the name of a pin group.
> +            items:
> +              pattern: "^cp([0-9]|[1-2][0-9]|3[0-1])$"
> +          bias-disable: true
> +          bias-pull-up: true
> +          bias-pull-down: true
> +        unevaluatedProperties: false

Better to use 'additionalProperties: false' here since you listed the 
only valid properties.

> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    pinconf: pin-controller@22c00c {
> +        compatible = "ti,da850-pupd";
> +        reg = <0x22c00c 0x8>;
> +        pinctrl-0 = <&pinconf_bias_groups>;
> +        pinctrl-names = "default";
> +
> +        pinconf_bias_groups: bias-groups {
> +            pull-up {
> +                groups = "cp30", "cp31";
> +                bias-pull-up;
> +            };
> +            pull-down {
> +                groups = "cp29", "cp28";
> +                bias-pull-down;
> +            };
> +            disable {
> +                groups = "cp27", "cp26";
> +                bias-disable;
> +            };
> +        };
> +    };
> -- 
> 2.43.0
> 
> 

      reply	other threads:[~2026-08-11 18:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-11 11:10 [PATCH v2] dt-bindings: pinctrl: Convert TI DA850 pupd to DT schema Eduard Bostina
2026-08-11 18:06 ` Rob Herring [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260811180621.GA2749647-robh@kernel.org \
    --to=robh@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=daniel.baluta@nxp.com \
    --cc=devicetree@vger.kernel.org \
    --cc=egbostina@gmail.com \
    --cc=goledhruva@gmail.com \
    --cc=krzk+dt@kernel.org \
    --cc=linusw@kernel.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m-chawdhry@ti.com \
    --cc=simona.toaca@nxp.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.