Message ID | 20220927173702.5200-1-krzysztof.kozlowski@linaro.org |
---|---|
Headers | show |
Series | pinctrl/arm64: qcom: continued - fix Qualcomm TLMM pinctrl schema warnings | expand |
On Tue, 27 Sep 2022 19:36:35 +0200, Krzysztof Kozlowski wrote: > Certain pins, like SDcard related, do not have functions and such should > not be required. Add a check for this in common Qualcomm TLMM pin > controller schema. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,tlmm-common.yaml | 20 +++++++++++++++---- > 1 file changed, 16 insertions(+), 4 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:37 +0200, Krzysztof Kozlowski wrote: > The pin controller driver has BLSP functions from 0 to 5, not 1 to 6. > Add missing blsp0_i2c, blsp0_spi (already used in ipq6018-cp01-c1) and > blsp0_uart. Drop blsp6_i2c and blsp6_spi. > > This fixes dtbs_check warning: > > ipq6018-cp01-c1.dtb: pinctrl@1000000: spi-0-state: 'oneOf' conditional failed, one must be fixed: > 'bias-pull-down', 'drive-strength', 'function', 'pins' do not match any of the regexes: '-pins$', 'pinctrl-[0-9]+' > 'blsp0_spi' is not one of ['adsp_ext', 'alsp_int', ..... > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > > --- > > Changes since v2: > 1. New patch > --- > .../devicetree/bindings/pinctrl/qcom,ipq6018-pinctrl.yaml | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:39 +0200, Krzysztof Kozlowski wrote: > The TLMM pin controller follows generic pin-controller bindings, so > should have subnodes with '-state' and '-pins'. Otherwise the subnodes > (level one and two) are not properly matched. This method also unifies > the bindings with other Qualcomm TLMM and LPASS pinctrl bindings. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,ipq6018-pinctrl.yaml | 15 +++++++++++---- > 1 file changed, 11 insertions(+), 4 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:42 +0200, Krzysztof Kozlowski wrote: > The TLMM pin controller follows generic pin-controller bindings, so > should have subnodes with '-state' and '-pins'. Otherwise the subnodes > (level one and two) are not properly matched. This method also unifies > the bindings with other Qualcomm TLMM and LPASS pinctrl bindings. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,msm8226-pinctrl.yaml | 14 +++++++++++--- > 1 file changed, 11 insertions(+), 3 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:44 +0200, Krzysztof Kozlowski wrote: > The MSM8226 pinctrl driver supports input-enable, blsp_i2c4, blsp_uart4 > and sdc3 functions and DTS already uses it: > > qcom-msm8226-samsung-s3ve3g.dtb: pinctrl@fd510000: 'blsp1-i2c1', 'blsp1-i2c2', 'blsp1-i2c3', 'blsp1-i2c4', 'blsp1-i2c5' ... > qcom-apq8026-lg-lenok.dtb: pinctrl@fd510000: touch-state: 'oneOf' conditional failed, one must be fixed: > 'input-enable' does not match any of the regexes: 'pinctrl-[0-9]+' > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,msm8226-pinctrl.yaml | 10 ++++------ > 1 file changed, 4 insertions(+), 6 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:47 +0200, Krzysztof Kozlowski wrote: > Certain pins, like SDcard related, do not have functions and such should > not be required. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > > --- > > v1 was reviewed by Rob, but patch was changed since that time, so not > adding Rob's tag. > --- > Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml | 1 - > 1 file changed, 1 deletion(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:48 +0200, Krzysztof Kozlowski wrote: > Bindings example should be indented with 4-spaces. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,msm8909-tlmm.yaml | 60 +++++++++---------- > 1 file changed, 30 insertions(+), 30 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:50 +0200, Krzysztof Kozlowski wrote: > Reference common Qualcomm TLMM pin controller schema, to bring other > regular schemas and additional checks, like function required only for > GPIOs. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > > --- > > v1 was reviewed by Rob, but patch was changed since that time, so not > adding Rob's tag. > --- > .../devicetree/bindings/pinctrl/qcom,msm8953-pinctrl.yaml | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:52 +0200, Krzysztof Kozlowski wrote: > Certain pins, like SDcard related, do not have functions and such should > not be required. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > > --- > > v1 was reviewed by Rob, but patch was changed since that time, so not > adding Rob's tag. > --- > .../devicetree/bindings/pinctrl/qcom,mdm9607-pinctrl.yaml | 1 - > 1 file changed, 1 deletion(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:54 +0200, Krzysztof Kozlowski wrote: > The TLMM pin controller follows generic pin-controller bindings, so > should have subnodes with '-state' and '-pins'. Otherwise the subnodes > (level one and two) are not properly matched. This method also unifies > the bindings with other Qualcomm TLMM and LPASS pinctrl bindings. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,qcm2290-pinctrl.yaml | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:56 +0200, Krzysztof Kozlowski wrote: > The TLMM pin controller follows generic pin-controller bindings, so > should have subnodes with '-state' and '-pins'. Otherwise the subnodes > (level one and two) are not properly matched. > > qcom-sdx55-telit-fn980-tlb.dtb: pinctrl@f100000: 'pcie_ep_clkreq_default', 'pcie_ep_perst_default', 'pcie_ep_wake_default' do not match any of the regexes: '-pins$', 'pinctrl-[0-9]+' > > This method also unifies the bindings with other Qualcomm TLMM and LPASS > pinctrl bindings. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,sdx55-pinctrl.yaml | 14 +++++++++++--- > 1 file changed, 11 insertions(+), 3 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:58 +0200, Krzysztof Kozlowski wrote: > Bindings example should be indented with 4-spaces. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,sdx55-pinctrl.yaml | 34 +++++++++---------- > 1 file changed, 17 insertions(+), 17 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:36:59 +0200, Krzysztof Kozlowski wrote: > The TLMM pin controller follows generic pin-controller bindings, so > should have subnodes with '-state' and '-pins'. Otherwise the subnodes > (level one and two) are not properly matched. This method also unifies > the bindings with other Qualcomm TLMM and LPASS pinctrl bindings. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../devicetree/bindings/pinctrl/qcom,sdx65-pinctrl.yaml | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, 27 Sep 2022 19:37:01 +0200, Krzysztof Kozlowski wrote: > The TLMM pin controller follows generic pin-controller bindings, so > should have subnodes with '-state' and '-pins'. Otherwise the subnodes > (level one and two) are not properly matched. This method also unifies > the bindings with other Qualcomm TLMM and LPASS pinctrl bindings. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > --- > .../bindings/pinctrl/qcom,sc7280-pinctrl.yaml | 14 +++++++++++--- > 1 file changed, 11 insertions(+), 3 deletions(-) > Reviewed-by: Rob Herring <robh@kernel.org>
On Tue, Sep 27, 2022 at 07:36:35PM +0200, Krzysztof Kozlowski wrote: > Certain pins, like SDcard related, do not have functions and such should > not be required. Add a check for this in common Qualcomm TLMM pin > controller schema. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> Thanks for moving this to the common schema! FWIW: Reviewed-by: Stephan Gerhold <stephan@gerhold.net> > --- > .../bindings/pinctrl/qcom,tlmm-common.yaml | 20 +++++++++++++++---- > 1 file changed, 16 insertions(+), 4 deletions(-) > > diff --git a/Documentation/devicetree/bindings/pinctrl/qcom,tlmm-common.yaml b/Documentation/devicetree/bindings/pinctrl/qcom,tlmm-common.yaml > index c88c8dcb69d9..e1354f0c64f8 100644 > --- a/Documentation/devicetree/bindings/pinctrl/qcom,tlmm-common.yaml > +++ b/Documentation/devicetree/bindings/pinctrl/qcom,tlmm-common.yaml > @@ -65,10 +65,6 @@ additionalProperties: true > > $defs: > qcom-tlmm-state: > - allOf: > - - $ref: pincfg-node.yaml# > - - $ref: pinmux-node.yaml# > - > properties: > drive-strength: > enum: [2, 4, 6, 8, 10, 12, 14, 16] > @@ -82,5 +78,21 @@ $defs: > output-high: true > output-low: true > > + allOf: > + - $ref: pincfg-node.yaml# > + - $ref: pinmux-node.yaml# > + > + - if: > + properties: > + pins: > + items: > + pattern: "^gpio" > + then: > + required: > + - function > + else: > + properties: > + function: false > + > additionalProperties: true > ... > -- > 2.34.1 >
On Tue, Sep 27, 2022 at 07:36:47PM +0200, Krzysztof Kozlowski wrote: > Certain pins, like SDcard related, do not have functions and such should > not be required. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> > Reviewed-by: Stephan Gerhold <stephan@gerhold.net> > --- > > v1 was reviewed by Rob, but patch was changed since that time, so not > adding Rob's tag. > --- > Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml b/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml > index b1735918fa90..08e2dd5cbebe 100644 > --- a/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml > +++ b/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml > @@ -113,7 +113,6 @@ $defs: > > required: > - pins > - - function > > additionalProperties: false > > -- > 2.34.1 >
On Tue, Sep 27, 2022 at 07:36:48PM +0200, Krzysztof Kozlowski wrote: > Bindings example should be indented with 4-spaces. > > Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Reviewed-by: Bjorn Andersson <andersson@kernel.org> Reviewed-by: Stephan Gerhold <stephan@gerhold.net> > --- > .../bindings/pinctrl/qcom,msm8909-tlmm.yaml | 60 +++++++++---------- > 1 file changed, 30 insertions(+), 30 deletions(-) > > diff --git a/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml b/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml > index 08e2dd5cbebe..9c647e24fa9a 100644 > --- a/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml > +++ b/Documentation/devicetree/bindings/pinctrl/qcom,msm8909-tlmm.yaml > @@ -118,35 +118,35 @@ $defs: > > examples: > - | > - #include <dt-bindings/interrupt-controller/arm-gic.h> > - > - pinctrl@1000000 { > - compatible = "qcom,msm8909-tlmm"; > - reg = <0x1000000 0x300000>; > - interrupts = <GIC_SPI 208 IRQ_TYPE_LEVEL_HIGH>; > - gpio-controller; > - #gpio-cells = <2>; > - gpio-ranges = <&tlmm 0 0 117>; > - interrupt-controller; > - #interrupt-cells = <2>; > - > - gpio-wo-subnode-state { > - pins = "gpio1"; > - function = "gpio"; > - }; > - > - uart-w-subnodes-state { > - rx-pins { > - pins = "gpio4"; > - function = "blsp_uart1"; > - bias-pull-up; > - }; > - > - tx-pins { > - pins = "gpio5"; > - function = "blsp_uart1"; > - bias-disable; > - }; > - }; > + #include <dt-bindings/interrupt-controller/arm-gic.h> > + > + pinctrl@1000000 { > + compatible = "qcom,msm8909-tlmm"; > + reg = <0x1000000 0x300000>; > + interrupts = <GIC_SPI 208 IRQ_TYPE_LEVEL_HIGH>; > + gpio-controller; > + #gpio-cells = <2>; > + gpio-ranges = <&tlmm 0 0 117>; > + interrupt-controller; > + #interrupt-cells = <2>; > + > + gpio-wo-subnode-state { > + pins = "gpio1"; > + function = "gpio"; > }; > + > + uart-w-subnodes-state { > + rx-pins { > + pins = "gpio4"; > + function = "blsp_uart1"; > + bias-pull-up; > + }; > + > + tx-pins { > + pins = "gpio5"; > + function = "blsp_uart1"; > + bias-disable; > + }; > + }; > + }; > ... > -- > 2.34.1 >