Re: [PATCH v5 01/15] dt-bindings: clock: split qcom,gcc.yaml to common and specific schema

Rob Herring
2022-03-23T13:55:49Z

On Thu, Feb 24, 2022 at 10:48 AM Ansuel Smith <ansuelsmth@gmail.com> wrote:
>
> Split qcom,gcc.yaml to common and specific schema to use it as a
> template for schema that needs to use the gcc bindings and require
> to add additional bindings.
>
> Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
> ---
> .../bindings/clock/qcom,gcc-other.yaml | 76 +++++++++++++++++++

This now throws errors in linux-next:

Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/jsonschema/validators.py",
line 816, in resolve_from_url
document = self.resolve_remote(url)
File "/usr/local/lib/python3.8/dist-packages/jsonschema/validators.py",
line 923, in resolve_remote
result = json.loads(url.read().decode("utf-8"))
File "/usr/lib/python3.8/json/__init__.py", line 357, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.8/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.8/json/decoder.py", line 355, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/bin/dt-doc-validate", line 70, in <module>
ret = check_doc(f)
File "/usr/local/bin/dt-doc-validate", line 36, in check_doc
for error in
sorted(dtschema.DTValidator.iter_schema_errors(testtree), key=lambda
e: e.linecol):
File "/usr/local/lib/python3.8/dist-packages/dtschema/lib.py", line
1016, in iter_schema_errors
meta_schema = cls.resolver.resolve_from_url(schema['$schema'])
File "/usr/local/lib/python3.8/dist-packages/jsonschema/validators.py",
line 818, in resolve_from_url
raise exceptions.RefResolutionError(exc)
jsonschema.exceptions.RefResolutionError: Expecting value: line 1
column 1 (char 0)
./Documentation/devicetree/bindings/clock/qcom,gcc-other.yaml:
mapping values are not allowed in this context
in "<unicode string>", line 17, column 11

> .../devicetree/bindings/clock/qcom,gcc.yaml | 59 +-------------
> 2 files changed, 80 insertions(+), 55 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/clock/qcom,gcc-other.yaml
>
> diff --git a/Documentation/devicetree/bindings/clock/qcom,gcc-other.yaml b/Documentation/devicetree/bindings/clock/qcom,gcc-other.yaml
> new file mode 100644
> index 000000000000..4e5903bcd70d
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/clock/qcom,gcc-other.yaml
> @@ -0,0 +1,76 @@
> +# SPDX-License-Identifier: GPL-2.0-only
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/clock/qcom,gcc-other.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Qualcomm Global Clock & Reset Controller Binding
> +
> +maintainers:
> + - Stephen Boyd <sboyd@kernel.org>
> + - Taniya Das <tdas@codeaurora.org>
> +
> +description:
> + Qualcomm global clock control module which supports the clocks, resets and
> + power domains.
> +
> + See also:

I think the problem is here. You need a '|' after 'description' to
preserve formatting and ignore what looks like a mapping.

> + - dt-bindings/clock/qcom,gcc-apq8084.h
> + - dt-bindings/reset/qcom,gcc-apq8084.h
> + - dt-bindings/clock/qcom,gcc-ipq4019.h
> + - dt-bindings/clock/qcom,gcc-ipq6018.h
> + - dt-bindings/reset/qcom,gcc-ipq6018.h
> + - dt-bindings/clock/qcom,gcc-ipq806x.h (qcom,gcc-ipq8064)
> + - dt-bindings/reset/qcom,gcc-ipq806x.h (qcom,gcc-ipq8064)
> + - dt-bindings/clock/qcom,gcc-msm8939.h
> + - dt-bindings/clock/qcom,gcc-msm8953.h
> + - dt-bindings/reset/qcom,gcc-msm8939.h
> + - dt-bindings/clock/qcom,gcc-msm8660.h
> + - dt-bindings/reset/qcom,gcc-msm8660.h
> + - dt-bindings/clock/qcom,gcc-msm8974.h (qcom,gcc-msm8226 and qcom,gcc-msm8974)
> + - dt-bindings/reset/qcom,gcc-msm8974.h (qcom,gcc-msm8226 and qcom,gcc-msm8974)
> + - dt-bindings/clock/qcom,gcc-mdm9607.h
> + - dt-bindings/clock/qcom,gcc-mdm9615.h
> + - dt-bindings/reset/qcom,gcc-mdm9615.h
> + - dt-bindings/clock/qcom,gcc-sdm660.h (qcom,gcc-sdm630 and qcom,gcc-sdm660)