diff mbox series

[1/5] media: dt-bindings: add the required property 'additionalProperties'

Message ID 20201204093813.1275-2-thunder.leizhen@huawei.com
State New
Headers show
Series fix dt_binding_check warnings | expand

Commit Message

Leizhen (ThunderTown) Dec. 4, 2020, 9:38 a.m. UTC
When I do dt_binding_check for any YAML file, below wanring is always
reported:

xxx/media/coda.yaml: 'additionalProperties' is a required property
xxx/media/coda.yaml: ignoring, error in schema:
warning: no schema found in file: xxx/media/coda.yaml

There are three properties defined in allOf, they should be explicitly
declared. Otherwise, "additionalProperties: false" will prohibit them.

Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
---
 Documentation/devicetree/bindings/media/coda.yaml | 6 ++++++
 1 file changed, 6 insertions(+)

Comments

Philipp Zabel Dec. 4, 2020, 10:56 a.m. UTC | #1
On Fri, 2020-12-04 at 17:38 +0800, Zhen Lei wrote:
> When I do dt_binding_check for any YAML file, below wanring is always
> reported:
> 
> xxx/media/coda.yaml: 'additionalProperties' is a required property
> xxx/media/coda.yaml: ignoring, error in schema:
> warning: no schema found in file: xxx/media/coda.yaml
> 
> There are three properties defined in allOf, they should be explicitly
> declared. Otherwise, "additionalProperties: false" will prohibit them.
> 
> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>

Thank you, there already is a patch to fix this:

https://lore.kernel.org/linux-media/20201117200752.4004368-1-robh@kernel.org/

regards
Philipp
Leizhen (ThunderTown) Dec. 6, 2020, 5:32 a.m. UTC | #2
On 2020/12/4 18:56, Philipp Zabel wrote:
> On Fri, 2020-12-04 at 17:38 +0800, Zhen Lei wrote:
>> When I do dt_binding_check for any YAML file, below wanring is always
>> reported:
>>
>> xxx/media/coda.yaml: 'additionalProperties' is a required property
>> xxx/media/coda.yaml: ignoring, error in schema:
>> warning: no schema found in file: xxx/media/coda.yaml
>>
>> There are three properties defined in allOf, they should be explicitly
>> declared. Otherwise, "additionalProperties: false" will prohibit them.
>>
>> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
> 
> Thank you, there already is a patch to fix this:
> 
> https://lore.kernel.org/linux-media/20201117200752.4004368-1-robh@kernel.org/

OK. I found it temporarily during do a JSON conversion,I have not subscribed the
dt-binding maillist.

> 
> regards
> Philipp
> 
> .
>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/media/coda.yaml b/Documentation/devicetree/bindings/media/coda.yaml
index 7bac0057faf7319..199b0826cd01cb6 100644
--- a/Documentation/devicetree/bindings/media/coda.yaml
+++ b/Documentation/devicetree/bindings/media/coda.yaml
@@ -52,6 +52,10 @@  properties:
     description: phandle pointing to the SRAM device node
     maxItems: 1
 
+  interrupts: true
+  interrupt-names: true
+  power-domains: true
+
 required:
   - compatible
   - reg
@@ -96,6 +100,8 @@  allOf:
           description: phandle pointing to the PU power domain
           maxItems: 1
 
+additionalProperties: false
+
 examples:
   - |
     vpu: video-codec@63ff4000 {