Mailing List Archive

[PATCH v4 1/2] dt-bindings: spi: add loongson spi
Add the Loongson platform spi binding with DT schema format using
json-schema.

Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
---
.../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
MAINTAINERS | 6 +++
2 files changed, 49 insertions(+)
create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml

diff --git a/Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml b/Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
new file mode 100644
index 000000000000..ee80049b1258
--- /dev/null
+++ b/Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
@@ -0,0 +1,43 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/spi/loongson,ls-spi.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Loongson SPI controller
+
+maintainers:
+ - Yinbo Zhu <zhuyinbo@loongson.cn>
+
+allOf:
+ - $ref: /schemas/spi/spi-controller.yaml#
+
+properties:
+ compatible:
+ enum:
+ - loongson,ls2k-spi
+ - loongson,ls7a-spi
+
+ reg:
+ maxItems: 1
+
+ clocks:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+ - clocks
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/clock/loongson,ls2k-clk.h>
+ spi0: spi@1fff0220{
+ compatible = "loongson,ls2k-spi";
+ reg = <0x1fff0220 0x10>;
+ clocks = <&clk LOONGSON2_BOOT_CLK>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+ };
diff --git a/MAINTAINERS b/MAINTAINERS
index 25a0981c74b6..9bc2158c735d 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -12157,6 +12157,12 @@ S: Maintained
F: Documentation/devicetree/bindings/clock/loongson,ls2k-clk.yaml
F: include/dt-bindings/clock/loongson,ls2k-clk.h

+LOONGSON SPI DRIVER
+M: Yinbo Zhu <zhuyinbo@loongson.cn>
+L: linux-spi@vger.kernel.org
+S: Maintained
+F: Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
+
LSILOGIC MPT FUSION DRIVERS (FC/SAS/SPI)
M: Sathya Prakash <sathya.prakash@broadcom.com>
M: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
--
2.20.1
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
This patch need depend on
https://lore.kernel.org/all/20230323025229.2971-1-zhuyinbo@loongson.cn/
then the spi yaml file will build successful, if no this clock patch
that spi yaml will build fail, so please test it that base on above
clock patch.
?? 2023/3/28 ????7:22, Yinbo Zhu ???:
> Add the Loongson platform spi binding with DT schema format using
> json-schema.
>
> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
> ---
> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
> MAINTAINERS | 6 +++
> 2 files changed, 49 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
>
> diff --git a/Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml b/Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
> new file mode 100644
> index 000000000000..ee80049b1258
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
> @@ -0,0 +1,43 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/spi/loongson,ls-spi.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Loongson SPI controller
> +
> +maintainers:
> + - Yinbo Zhu <zhuyinbo@loongson.cn>
> +
> +allOf:
> + - $ref: /schemas/spi/spi-controller.yaml#
> +
> +properties:
> + compatible:
> + enum:
> + - loongson,ls2k-spi
> + - loongson,ls7a-spi
> +
> + reg:
> + maxItems: 1
> +
> + clocks:
> + maxItems: 1
> +
> +required:
> + - compatible
> + - reg
> + - clocks
> +
> +unevaluatedProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/clock/loongson,ls2k-clk.h>
> + spi0: spi@1fff0220{
> + compatible = "loongson,ls2k-spi";
> + reg = <0x1fff0220 0x10>;
> + clocks = <&clk LOONGSON2_BOOT_CLK>;
> + #address-cells = <1>;
> + #size-cells = <0>;
> + };
> diff --git a/MAINTAINERS b/MAINTAINERS
> index 25a0981c74b6..9bc2158c735d 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -12157,6 +12157,12 @@ S: Maintained
> F: Documentation/devicetree/bindings/clock/loongson,ls2k-clk.yaml
> F: include/dt-bindings/clock/loongson,ls2k-clk.h
>
> +LOONGSON SPI DRIVER
> +M: Yinbo Zhu <zhuyinbo@loongson.cn>
> +L: linux-spi@vger.kernel.org
> +S: Maintained
> +F: Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
> +
> LSILOGIC MPT FUSION DRIVERS (FC/SAS/SPI)
> M: Sathya Prakash <sathya.prakash@broadcom.com>
> M: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
>
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
On Tue, 28 Mar 2023 19:22:09 +0800, Yinbo Zhu wrote:
> Add the Loongson platform spi binding with DT schema format using
> json-schema.
>
> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
> ---
> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
> MAINTAINERS | 6 +++
> 2 files changed, 49 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
>

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
Error: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dts:22.28-29 syntax error
FATAL ERROR: Unable to parse input tree
make[1]: *** [scripts/Makefile.lib:419: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dtb] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1512: dt_binding_check] Error 2

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20230328112210.23089-2-zhuyinbo@loongson.cn

The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
This patch need depend on
https://lore.kernel.org/all/20230323025229.2971-1-zhuyinbo@loongson.cn/
then the spi yaml file will build successful. That changelog had record it.

? 2023/3/28 ??8:57, Rob Herring ??:
>
> On Tue, 28 Mar 2023 19:22:09 +0800, Yinbo Zhu wrote:
>> Add the Loongson platform spi binding with DT schema format using
>> json-schema.
>>
>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
>> ---
>> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
>> MAINTAINERS | 6 +++
>> 2 files changed, 49 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
>>
>
> My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
> on your patch (DT_CHECKER_FLAGS is new in v5.13):
>
> yamllint warnings/errors:
>
> dtschema/dtc warnings/errors:
> Error: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dts:22.28-29 syntax error
> FATAL ERROR: Unable to parse input tree
> make[1]: *** [scripts/Makefile.lib:419: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dtb] Error 1
> make[1]: *** Waiting for unfinished jobs....
> make: *** [Makefile:1512: dt_binding_check] Error 2
>
> doc reference errors (make refcheckdocs):
>
> See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20230328112210.23089-2-zhuyinbo@loongson.cn
>
> The base for the series is generally the latest rc1. A different dependency
> should be noted in *this* patch.
>
> If you already ran 'make dt_binding_check' and didn't see the above
> error(s), then make sure 'yamllint' is installed and dt-schema is up to
> date:
>
> pip3 install dtschema --upgrade
>
> Please check and re-submit after running the above command yourself. Note
> that DT_SCHEMA_FILES can be set to your schema file to speed up checking
> your schema. However, it must be unset to test all examples with your schema.
>
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
On 29/03/2023 03:12, zhuyinbo wrote:
> This patch need depend on
> https://lore.kernel.org/all/20230323025229.2971-1-zhuyinbo@loongson.cn/
> then the spi yaml file will build successful. That changelog had record it.

Thus it cannot be merged now. Do not resend it till dependency hits
mainline (since you decided not to go with Rob's advice).

Best regards,
Krzysztof
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
On 28/03/2023 13:22, Yinbo Zhu wrote:
> Add the Loongson platform spi binding with DT schema format using
> json-schema.
>
> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
> ---
> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
> MAINTAINERS | 6 +++

You decided not to use Rob's advice, thus this patch cannot be applied
now. Wait for the merge window to finish (so dependency is in mainline)
and send the patch then. Not earlier.

Best regards,
Krzysztof
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
? 2023/3/29 ??4:06, Krzysztof Kozlowski ??:
> On 28/03/2023 13:22, Yinbo Zhu wrote:
>> Add the Loongson platform spi binding with DT schema format using
>> json-schema.
>>
>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
>> ---
>> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
>> MAINTAINERS | 6 +++
>
> You decided not to use Rob's advice, thus this patch cannot be applied
> now. Wait for the merge window to finish (so dependency is in mainline)
> and send the patch then. Not earlier.
>
> Best regards,
> Krzysztof
> I'm sorry, I didn't understand Rob's suggestion in fact. I'll ask Rob
what I should do
later. If it did really no good solution, I will postpone my patch until the
dependent patch is merged into the mainline.

Thanks.
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
? 2023/3/28 ??8:57, Rob Herring ??:
>
> On Tue, 28 Mar 2023 19:22:09 +0800, Yinbo Zhu wrote:
>> Add the Loongson platform spi binding with DT schema format using
>> json-schema.
>>
>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
>> ---
>> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
>> MAINTAINERS | 6 +++
>> 2 files changed, 49 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
>>
>
> My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
> on your patch (DT_CHECKER_FLAGS is new in v5.13):
>
> yamllint warnings/errors:
>
> dtschema/dtc warnings/errors:
> Error: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dts:22.28-29 syntax error
> FATAL ERROR: Unable to parse input tree
> make[1]: *** [scripts/Makefile.lib:419: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dtb] Error 1
> make[1]: *** Waiting for unfinished jobs....
> make: *** [Makefile:1512: dt_binding_check] Error 2
>
> doc reference errors (make refcheckdocs):
>
> See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20230328112210.23089-2-zhuyinbo@loongson.cn
>
> The base for the series is generally the latest rc1. A different dependency
> should be noted in *this* patch.
Hi Rob,

I'm sorry, actually, I don't know what the specific operation I should
do when I received the check warning
from your bot. Does it means that I should add dependency note into this
patch's changelog ? or something else, I really
don't know. Actually, I'm always bothered by these things that how to
resolve the dependency issue for two
dependent patches that do not belong to the same series.

Thanks.
>
> If you already ran 'make dt_binding_check' and didn't see the above
> error(s), then make sure 'yamllint' is installed and dt-schema is up to
> date:
>
> pip3 install dtschema --upgrade
>
> Please check and re-submit after running the above command yourself. Note
> that DT_SCHEMA_FILES can be set to your schema file to speed up checking
> your schema. However, it must be unset to test all examples with your schema.
>
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
? 2023/3/29 ??4:05, Krzysztof Kozlowski ??:
> On 29/03/2023 03:12, zhuyinbo wrote:
>> This patch need depend on
>> https://lore.kernel.org/all/20230323025229.2971-1-zhuyinbo@loongson.cn/
>> then the spi yaml file will build successful. That changelog had record it.
>
> Thus it cannot be merged now. Do not resend it till dependency hits
> mainline (since you decided not to go with Rob's advice).
>
> Best regards,
> Krzysztof
>
okay, I got it.

Thanks.
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
On 29/03/2023 12:39, zhuyinbo wrote:
>
>
> ? 2023/3/28 ??8:57, Rob Herring ??:
>>
>> On Tue, 28 Mar 2023 19:22:09 +0800, Yinbo Zhu wrote:
>>> Add the Loongson platform spi binding with DT schema format using
>>> json-schema.
>>>
>>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
>>> ---
>>> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
>>> MAINTAINERS | 6 +++
>>> 2 files changed, 49 insertions(+)
>>> create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
>>>
>>
>> My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
>> on your patch (DT_CHECKER_FLAGS is new in v5.13):
>>
>> yamllint warnings/errors:
>>
>> dtschema/dtc warnings/errors:
>> Error: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dts:22.28-29 syntax error
>> FATAL ERROR: Unable to parse input tree
>> make[1]: *** [scripts/Makefile.lib:419: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dtb] Error 1
>> make[1]: *** Waiting for unfinished jobs....
>> make: *** [Makefile:1512: dt_binding_check] Error 2
>>
>> doc reference errors (make refcheckdocs):
>>
>> See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20230328112210.23089-2-zhuyinbo@loongson.cn
>>
>> The base for the series is generally the latest rc1. A different dependency
>> should be noted in *this* patch.
> Hi Rob,
>
> I'm sorry, actually, I don't know what the specific operation I should
> do when I received the check warning
> from your bot. Does it means that I should add dependency note into this
> patch's changelog ?

Yes, this is explicitly mentioned in the sentence you quoted.

> or something else, I really
> don't know. Actually, I'm always bothered by these things that how to
> resolve the dependency issue for two
> dependent patches that do not belong to the same series.

Another approach, as Rob suggested last time, would be to just get rid
of the dependency and open-code the clock IDs...

Best regards,
Krzysztof
Re: [PATCH v4 1/2] dt-bindings: spi: add loongson spi [ In reply to ]
? 2023/3/29 ??7:37, Krzysztof Kozlowski ??:
> On 29/03/2023 12:39, zhuyinbo wrote:
>>
>>
>> ? 2023/3/28 ??8:57, Rob Herring ??:
>>>
>>> On Tue, 28 Mar 2023 19:22:09 +0800, Yinbo Zhu wrote:
>>>> Add the Loongson platform spi binding with DT schema format using
>>>> json-schema.
>>>>
>>>> Signed-off-by: Yinbo Zhu <zhuyinbo@loongson.cn>
>>>> ---
>>>> .../bindings/spi/loongson,ls-spi.yaml | 43 +++++++++++++++++++
>>>> MAINTAINERS | 6 +++
>>>> 2 files changed, 49 insertions(+)
>>>> create mode 100644 Documentation/devicetree/bindings/spi/loongson,ls-spi.yaml
>>>>
>>>
>>> My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
>>> on your patch (DT_CHECKER_FLAGS is new in v5.13):
>>>
>>> yamllint warnings/errors:
>>>
>>> dtschema/dtc warnings/errors:
>>> Error: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dts:22.28-29 syntax error
>>> FATAL ERROR: Unable to parse input tree
>>> make[1]: *** [scripts/Makefile.lib:419: Documentation/devicetree/bindings/spi/loongson,ls-spi.example.dtb] Error 1
>>> make[1]: *** Waiting for unfinished jobs....
>>> make: *** [Makefile:1512: dt_binding_check] Error 2
>>>
>>> doc reference errors (make refcheckdocs):
>>>
>>> See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20230328112210.23089-2-zhuyinbo@loongson.cn
>>>
>>> The base for the series is generally the latest rc1. A different dependency
>>> should be noted in *this* patch.
>> Hi Rob,
>>
>> I'm sorry, actually, I don't know what the specific operation I should
>> do when I received the check warning
>> from your bot. Does it means that I should add dependency note into this
>> patch's changelog ?
>
> Yes, this is explicitly mentioned in the sentence you quoted.
okay, I got it, thanks!
>
>> or something else, I really
>> don't know. Actually, I'm always bothered by these things that how to
>> resolve the dependency issue for two
>> dependent patches that do not belong to the same series.
>
> Another approach, as Rob suggested last time, would be to just get rid
> of the dependency and open-code the clock IDs...
Thank you very much for your suggestion, I will open-code the clock
IDs and fix that checkpatch issue then resend this series patch.
>
> Best regards,
> Krzysztof
>