Re: [RFC v1 2/4] pinctrl: add polarfire soc mssio pinctrl driver

From: Linus Walleij
Date: Mon Nov 24 2025 - 19:10:50 EST


On Fri, Nov 21, 2025 at 12:21 PM Conor Dooley <conor@xxxxxxxxxx> wrote:

> ngl, I forget if there's a shorthand for the bias part, so I just want
> to know if is this an accurate summary of what's exclusive?
>
> diff --git a/Documentation/devicetree/bindings/pinctrl/pincfg-node.yaml b/Documentation/devicetree/bindings/pinctrl/pincfg-node.yaml
> index cbfcf215e571..6865472ac124 100644
> --- a/Documentation/devicetree/bindings/pinctrl/pincfg-node.yaml
> +++ b/Documentation/devicetree/bindings/pinctrl/pincfg-node.yaml
> @@ -153,4 +153,66 @@ properties:
> pin. Typically indicates how many double-inverters are
> used to delay the signal.
>
> +allOf:
> + - if:
> + required:
> + - output-disable
> + then:
> + properties:
> + output-enable: false
> + output-impedance-ohms: false

Looks right.

> + - if:
> + required:
> + - output-low
> + then:
> + properties:
> + output-high: false

Looks right.

> + - if:
> + required:
> + - low-power-enable
> + then:
> + properties:
> + low-power-disable: false

Looks right.

> + - if:
> + required:
> + - input-schmitt-disable
> + then:
> + properties:
> + input-schmitt-enable: false
> + input-schmitt-microvolt: false

Looks right.

> + - if:
> + required:
> + - drive-open-source
> + then:
> + properties:
> + drive-open-drain: false

drive-push-pull is mutually exclusive
with each of these as well.

> + - if:
> + anyOf:
> + - required:
> + - bias-disable
> + - required:
> + - bias-high-impedance
> + - required:
> + - bias-hold
> + - required:
> + - bias-up
> + - required:
> + - bias-down
> + - required:
> + - bias-pull-pin-default
> + then:
> + oneOf:
> + - required:
> + - bias-disable
> + - required:
> + - bias-high-impedance
> + - required:
> + - bias-hold
> + - required:
> + - bias-up
> + - required:
> + - bias-down
> + - required:
> + - bias-pull-pin-default

These is a bunch of "pull" infixes missing from the
above.

After looking at it for a while I concluded this
is right as well, if just the right names are added.
I would add a comment like

# We can only ever allow exactly one of these,
# they are all mutually exclusive.

Additionally:

drive-strength and drive-strength-microamp are mutually
exclusive.

input-enable and input-disable are mutually exclusive.

low-power-enable and low-power-disable are mutually
exclusive.

input-schmitt need to be added as deprecated.

Can you cook a patch? Maybe test it on the existing
device trees first to see that it doesn't wreac havoc.

Yours,
Linus Walleij