[PATCH v2, 1/7] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for lat soc

Yunfei Dong posted 7 patches 2 years, 7 months ago
There is a newer version of this series
[PATCH v2, 1/7] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for lat soc
Posted by Yunfei Dong 2 years, 7 months ago
Adds decoder dt-bindings for compatible "mediatek,mtk-vcodec-lat-soc".

Signed-off-by: Yunfei Dong <yunfei.dong@mediatek.com>
---
 .../media/mediatek,vcodec-subdev-decoder.yaml | 49 +++++++++++++++++++
 1 file changed, 49 insertions(+)

diff --git a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
index 6415c9f29130..a3c892338ac0 100644
--- a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
+++ b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
@@ -189,6 +189,55 @@ patternProperties:
 
     additionalProperties: false
 
+  '^vcodec-lat-soc@[0-9a-f]+$':
+    type: object
+
+    properties:
+      compatible:
+        const: mediatek,mtk-vcodec-lat-soc
+
+      reg:
+        maxItems: 1
+
+      iommus:
+        minItems: 1
+        maxItems: 32
+        description: |
+          List of the hardware port in respective IOMMU block for current Socs.
+          Refer to bindings/iommu/mediatek,iommu.yaml.
+
+      clocks:
+        maxItems: 5
+
+      clock-names:
+        items:
+          - const: sel
+          - const: soc-vdec
+          - const: soc-lat
+          - const: vdec
+          - const: top
+
+      assigned-clocks:
+        maxItems: 1
+
+      assigned-clock-parents:
+        maxItems: 1
+
+      power-domains:
+        maxItems: 1
+
+    required:
+      - compatible
+      - reg
+      - iommus
+      - clocks
+      - clock-names
+      - assigned-clocks
+      - assigned-clock-parents
+      - power-domains
+
+    additionalProperties: false
+
 required:
   - compatible
   - reg
-- 
2.25.1

Re: [PATCH v2, 1/7] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for lat soc
Posted by Rob Herring 2 years, 7 months ago
On Fri, Jan 28, 2022 at 11:54:34AM +0800, Yunfei Dong wrote:
> Adds decoder dt-bindings for compatible "mediatek,mtk-vcodec-lat-soc".

What's lat soc? How does this relate to what's already there in this 
binding.

The subject space is limited, avoid saying the same thing twice 
(dt-bindings).

> 
> Signed-off-by: Yunfei Dong <yunfei.dong@mediatek.com>
> ---
>  .../media/mediatek,vcodec-subdev-decoder.yaml | 49 +++++++++++++++++++
>  1 file changed, 49 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
> index 6415c9f29130..a3c892338ac0 100644
> --- a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
> +++ b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-decoder.yaml
> @@ -189,6 +189,55 @@ patternProperties:
>  
>      additionalProperties: false
>  
> +  '^vcodec-lat-soc@[0-9a-f]+$':
> +    type: object
> +
> +    properties:
> +      compatible:
> +        const: mediatek,mtk-vcodec-lat-soc
> +
> +      reg:
> +        maxItems: 1
> +
> +      iommus:
> +        minItems: 1
> +        maxItems: 32
> +        description: |
> +          List of the hardware port in respective IOMMU block for current Socs.
> +          Refer to bindings/iommu/mediatek,iommu.yaml.
> +
> +      clocks:
> +        maxItems: 5
> +
> +      clock-names:
> +        items:
> +          - const: sel
> +          - const: soc-vdec
> +          - const: soc-lat
> +          - const: vdec
> +          - const: top
> +
> +      assigned-clocks:
> +        maxItems: 1
> +
> +      assigned-clock-parents:
> +        maxItems: 1
> +
> +      power-domains:
> +        maxItems: 1
> +
> +    required:
> +      - compatible
> +      - reg
> +      - iommus
> +      - clocks
> +      - clock-names
> +      - assigned-clocks
> +      - assigned-clock-parents
> +      - power-domains
> +
> +    additionalProperties: false
> +
>  required:
>    - compatible
>    - reg
> -- 
> 2.25.1
> 
> 
Re: [PATCH v2, 1/7] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for lat soc
Posted by yunfei.dong@mediatek.com 2 years, 7 months ago
Hi Rob,

Thanks for your suggestion.
On Wed, 2022-02-09 at 14:37 -0600, Rob Herring wrote:
> On Fri, Jan 28, 2022 at 11:54:34AM +0800, Yunfei Dong wrote:
> > Adds decoder dt-bindings for compatible "mediatek,mtk-vcodec-lat-
> > soc".
> 
> What's lat soc? How does this relate to what's already there in this 
> binding.
> 
lat soc is another hardware, is related with some vdec larb ports.
Won't be used to decode, but must to write it in dtsi, or hardware
can't work well.

Need to enable clock/power/iommus, no interrupt.
> The subject space is limited, avoid saying the same thing twice 
> (dt-bindings).
> 

Best Regards,
Yunfei Dong
> > 
> > Signed-off-by: Yunfei Dong <yunfei.dong@mediatek.com>
> > ---
> >  .../media/mediatek,vcodec-subdev-decoder.yaml | 49
> > +++++++++++++++++++
> >  1 file changed, 49 insertions(+)
> > 
> > diff --git
> > a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-
> > decoder.yaml
> > b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-
> > decoder.yaml
> > index 6415c9f29130..a3c892338ac0 100644
> > --- a/Documentation/devicetree/bindings/media/mediatek,vcodec-
> > subdev-decoder.yaml
> > +++ b/Documentation/devicetree/bindings/media/mediatek,vcodec-
> > subdev-decoder.yaml
> > @@ -189,6 +189,55 @@ patternProperties:
> >  
> >      additionalProperties: false
> >  
> > +  '^vcodec-lat-soc@[0-9a-f]+$':
> > +    type: object
> > +
> > +    properties:
> > +      compatible:
> > +        const: mediatek,mtk-vcodec-lat-soc
> > +
> > +      reg:
> > +        maxItems: 1
> > +
> > +      iommus:
> > +        minItems: 1
> > +        maxItems: 32
> > +        description: |
> > +          List of the hardware port in respective IOMMU block for
> > current Socs.
> > +          Refer to bindings/iommu/mediatek,iommu.yaml.
> > +
> > +      clocks:
> > +        maxItems: 5
> > +
> > +      clock-names:
> > +        items:
> > +          - const: sel
> > +          - const: soc-vdec
> > +          - const: soc-lat
> > +          - const: vdec
> > +          - const: top
> > +
> > +      assigned-clocks:
> > +        maxItems: 1
> > +
> > +      assigned-clock-parents:
> > +        maxItems: 1
> > +
> > +      power-domains:
> > +        maxItems: 1
> > +
> > +    required:
> > +      - compatible
> > +      - reg
> > +      - iommus
> > +      - clocks
> > +      - clock-names
> > +      - assigned-clocks
> > +      - assigned-clock-parents
> > +      - power-domains
> > +
> > +    additionalProperties: false
> > +
> >  required:
> >    - compatible
> >    - reg
> > -- 
> > 2.25.1
> > 
> > 

Re: [PATCH v2, 1/7] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for lat soc
Posted by AngeloGioacchino Del Regno 2 years, 7 months ago
Il 10/02/22 04:06, yunfei.dong@mediatek.com ha scritto:
> Hi Rob,
> 
> Thanks for your suggestion.
> On Wed, 2022-02-09 at 14:37 -0600, Rob Herring wrote:
>> On Fri, Jan 28, 2022 at 11:54:34AM +0800, Yunfei Dong wrote:
>>> Adds decoder dt-bindings for compatible "mediatek,mtk-vcodec-lat-
>>> soc".
>>
>> What's lat soc? How does this relate to what's already there in this
>> binding.
>>
> lat soc is another hardware, is related with some vdec larb ports.
> Won't be used to decode, but must to write it in dtsi, or hardware
> can't work well.

Hello Yunfei,

as a suggestion, writing the meaning of the "LAT" acronym may also
help to clear some doubts around (please, also do that in the yaml file,
other than the commit description).

Thank you!
Angelo

> 
> Need to enable clock/power/iommus, no interrupt.
>> The subject space is limited, avoid saying the same thing twice
>> (dt-bindings).
>>
> 
> Best Regards,
> Yunfei Dong
>>>
>>> Signed-off-by: Yunfei Dong <yunfei.dong@mediatek.com>
>>> ---
>>>   .../media/mediatek,vcodec-subdev-decoder.yaml | 49
>>> +++++++++++++++++++
>>>   1 file changed, 49 insertions(+)
>>>
>>> diff --git
>>> a/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-
>>> decoder.yaml
>>> b/Documentation/devicetree/bindings/media/mediatek,vcodec-subdev-
>>> decoder.yaml
>>> index 6415c9f29130..a3c892338ac0 100644
>>> --- a/Documentation/devicetree/bindings/media/mediatek,vcodec-
>>> subdev-decoder.yaml
>>> +++ b/Documentation/devicetree/bindings/media/mediatek,vcodec-
>>> subdev-decoder.yaml
>>> @@ -189,6 +189,55 @@ patternProperties:
>>>   
>>>       additionalProperties: false
>>>   
>>> +  '^vcodec-lat-soc@[0-9a-f]+$':
>>> +    type: object
>>> +
>>> +    properties:
>>> +      compatible:
>>> +        const: mediatek,mtk-vcodec-lat-soc
>>> +
>>> +      reg:
>>> +        maxItems: 1
>>> +
>>> +      iommus:
>>> +        minItems: 1
>>> +        maxItems: 32
>>> +        description: |
>>> +          List of the hardware port in respective IOMMU block for
>>> current Socs.
>>> +          Refer to bindings/iommu/mediatek,iommu.yaml.
>>> +
>>> +      clocks:
>>> +        maxItems: 5
>>> +
>>> +      clock-names:
>>> +        items:
>>> +          - const: sel
>>> +          - const: soc-vdec
>>> +          - const: soc-lat
>>> +          - const: vdec
>>> +          - const: top
>>> +
>>> +      assigned-clocks:
>>> +        maxItems: 1
>>> +
>>> +      assigned-clock-parents:
>>> +        maxItems: 1
>>> +
>>> +      power-domains:
>>> +        maxItems: 1
>>> +
>>> +    required:
>>> +      - compatible
>>> +      - reg
>>> +      - iommus
>>> +      - clocks
>>> +      - clock-names
>>> +      - assigned-clocks
>>> +      - assigned-clock-parents
>>> +      - power-domains
>>> +
>>> +    additionalProperties: false
>>> +
>>>   required:
>>>     - compatible
>>>     - reg
>>> -- 
>>> 2.25.1
>>>
>>>
> 

Re: [PATCH v2, 1/7] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for lat soc
Posted by yunfei.dong@mediatek.com 2 years, 7 months ago
Hi AngeloGioacchino,

Thanks for your suggestion.
On Thu, 2022-02-10 at 09:40 +0100, AngeloGioacchino Del Regno wrote:
> Il 10/02/22 04:06, yunfei.dong@mediatek.com ha scritto:
> > Hi Rob,
> > 
> > Thanks for your suggestion.
> > On Wed, 2022-02-09 at 14:37 -0600, Rob Herring wrote:
> > > On Fri, Jan 28, 2022 at 11:54:34AM +0800, Yunfei Dong wrote:
> > > > Adds decoder dt-bindings for compatible "mediatek,mtk-vcodec-
> > > > lat-
> > > > soc".
> > > 
> > > What's lat soc? How does this relate to what's already there in
> > > this
> > > binding.
> > > 
> > 
> > lat soc is another hardware, is related with some vdec larb ports.
> > Won't be used to decode, but must to write it in dtsi, or hardware
> > can't work well.
> 
> Hello Yunfei,
> 
> as a suggestion, writing the meaning of the "LAT" acronym may also
I'm very sorry, I can't write the meaning of the "LAT" acronym. You can
regards it as an hardware.

> help to clear some doubts around (please, also do that in the yaml
> file,
> other than the commit description).
> 
I will add detail message for this hardware in next patch. And this
hardware only be used for mt8195 at now.

> Thank you!
> Angelo
> 
Best Regards,
Yunfei Dong
> > 
> > Need to enable clock/power/iommus, no interrupt.
> > > The subject space is limited, avoid saying the same thing twice
> > > (dt-bindings).
> > > 
> > 
> > Best Regards,
> > Yunfei Dong
> > > > 
> > > > Signed-off-by: Yunfei Dong <yunfei.dong@mediatek.com>
> > > > ---
> > > >   .../media/mediatek,vcodec-subdev-decoder.yaml | 49
> > > > +++++++++++++++++++
> > > >   1 file changed, 49 insertions(+)
> > > > 
> > > > diff --git
> > > > a/Documentation/devicetree/bindings/media/mediatek,vcodec-
> > > > subdev-
> > > > decoder.yaml
> > > > b/Documentation/devicetree/bindings/media/mediatek,vcodec-
> > > > subdev-
> > > > decoder.yaml
> > > > index 6415c9f29130..a3c892338ac0 100644
> > > > --- a/Documentation/devicetree/bindings/media/mediatek,vcodec-
> > > > subdev-decoder.yaml
> > > > +++ b/Documentation/devicetree/bindings/media/mediatek,vcodec-
> > > > subdev-decoder.yaml
> > > > @@ -189,6 +189,55 @@ patternProperties:
> > > >   
> > > >       additionalProperties: false
> > > >   
> > > > +  '^vcodec-lat-soc@[0-9a-f]+$':
> > > > +    type: object
> > > > +
> > > > +    properties:
> > > > +      compatible:
> > > > +        const: mediatek,mtk-vcodec-lat-soc
> > > > +
> > > > +      reg:
> > > > +        maxItems: 1
> > > > +
> > > > +      iommus:
> > > > +        minItems: 1
> > > > +        maxItems: 32
> > > > +        description: |
> > > > +          List of the hardware port in respective IOMMU block
> > > > for
> > > > current Socs.
> > > > +          Refer to bindings/iommu/mediatek,iommu.yaml.
> > > > +
> > > > +      clocks:
> > > > +        maxItems: 5
> > > > +
> > > > +      clock-names:
> > > > +        items:
> > > > +          - const: sel
> > > > +          - const: soc-vdec
> > > > +          - const: soc-lat
> > > > +          - const: vdec
> > > > +          - const: top
> > > > +
> > > > +      assigned-clocks:
> > > > +        maxItems: 1
> > > > +
> > > > +      assigned-clock-parents:
> > > > +        maxItems: 1
> > > > +
> > > > +      power-domains:
> > > > +        maxItems: 1
> > > > +
> > > > +    required:
> > > > +      - compatible
> > > > +      - reg
> > > > +      - iommus
> > > > +      - clocks
> > > > +      - clock-names
> > > > +      - assigned-clocks
> > > > +      - assigned-clock-parents
> > > > +      - power-domains
> > > > +
> > > > +    additionalProperties: false
> > > > +
> > > >   required:
> > > >     - compatible
> > > >     - reg
> > > > -- 
> > > > 2.25.1
> > > > 
> > > > 
> 
>