Thank you for your contribution! Sashiko AI review found 3 potential issue(s) 
to consider:
- [Medium] dt-bindings: required 'compatible' property is undefined in 
tegra-dbi schema
- [Medium] dt-bindings: invalid example root node causes validation failure
- [Medium] dt-bindings: missing generational constraint for dbi interface
--

commit 9f9bbe3a4b81a4564064134d8bb28bd826d68aac
Author: Svyatoslav Ryhel <[email protected]>

dt-bindings: display: tegra: Document 8-bit CPU parallel interface

Document 8-bit CPU parallel MIPI DBI Type B interface provided by
Tegra20/30 SoCs display controller.

> diff --git 
> a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra-dbi.yaml 
> b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra-dbi.yaml
> new file mode 100644
> index 0000000000000..184c33d436308
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra-dbi.yaml
[ ... ]
> +properties:
> +  dc-gpios:
> +    description: Data/command selection pin.

[Severity: Medium]
The properties block completely omits a definition for the required
compatible property.

Because unevaluatedProperties is set to false, wouldn't providing the
compatible property fail validation since it is undefined in this block?

[ ... ]
> +required:
> +  - compatible
> +  - dc-gpios

[Severity: Medium]
This incorrectly requires the compatible property for the dbi node.

Since it is required here, wouldn't omitting it also fail validation,
making it impossible to satisfy the schema?

[ ... ]
> +examples:
> +  - |
> +    #include <dt-bindings/gpio/gpio.h>
> +
> +    dc@54200000 {
> +        reg = <0x54200000 0x00040000>;
> +
> +        dbi {

[Severity: Medium]
Is the example rooted at the parent dc node instead of the dbi node, causing
dt-schema to apply the dbi schema to the parent node and fail?

Since the schema lacks a select or top-level compatible constraint, dt-schema
will automatically evaluate the example's root node against this schema.

Because the dc node contains properties like reg and dbi that are not defined
in the schema, and lacks required properties, won't this cause a schema
validation error?

> diff --git 
> a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-dc.yaml 
> b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-dc.yaml
> index 69be95afd5627..bb280f8dbfc7c 100644
> --- a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-dc.yaml
> +++ b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-dc.yaml
[ ... ]
> @@ -76,6 +76,9 @@ properties:
>      $ref: /schemas/types.yaml#/definitions/phandle-array
>      description: A list of phandles of outputs that this display controller 
> can drive.
>  
> +  dbi:
> +    $ref: /schemas/display/tegra/nvidia,tegra-dbi.yaml#
> +

[Severity: Medium]
Does this unconditionally allow the dbi node for all Tegra DC variants,
violating the hardware constraint?

The commit message explicitly states the 8-bit CPU (MIPI DBI) interface is a
feature of Tegra20/30 SoCs. Since nvidia,tegra20-dc.yaml covers later
generations, should this be conditionally constrained to Tegra20 and Tegra30
using an allOf -> if block?

-- 
Sashiko AI review ยท 
https://sashiko.dev/#/patchset/[email protected]?part=3

Reply via email to