lkml.org 
[lkml]   [2020]   [Oct]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v3 01/24] dt-bindings: iommu: mediatek: Convert IOMMU to DT schema
On Tue, 6 Oct 2020 at 06:27, Yong Wu <yong.wu@mediatek.com> wrote:
>
> On Fri, 2020-10-02 at 13:07 +0200, Krzysztof Kozlowski wrote:
> > On Wed, Sep 30, 2020 at 03:06:24PM +0800, Yong Wu wrote:
> > > Convert MediaTek IOMMU to DT schema.
> > >
> > > Signed-off-by: Yong Wu <yong.wu@mediatek.com>
> > > ---
> > > .../bindings/iommu/mediatek,iommu.txt | 103 ------------
> > > .../bindings/iommu/mediatek,iommu.yaml | 154 ++++++++++++++++++
> > > 2 files changed, 154 insertions(+), 103 deletions(-)
> > > delete mode 100644 Documentation/devicetree/bindings/iommu/mediatek,iommu.txt
> > > create mode 100644 Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml
> > >
>
> [...]
>
> > > +properties:
> > > + compatible:
> > > + oneOf:
> > > + - enum:
> > > + - mediatek,mt2701-m4u # mt2701 generation one HW
> > > + - mediatek,mt2712-m4u # mt2712 generation two HW
> > > + - mediatek,mt6779-m4u # mt6779 generation two HW
> > > + - mediatek,mt8173-m4u # mt8173 generation two HW
> > > + - mediatek,mt8183-m4u # mt8183 generation two HW
> > > +
> > > + - description: mt7623 generation one HW
> > > + items:
> > > + - const: mediatek,mt7623-m4u
> > > + - const: mediatek,mt2701-m4u
> > > +
> > > + reg:
> > > + maxItems: 1
> > > +
> > > + interrupts:
> > > + maxItems: 1
> > > +
> > > + clocks:
> > > + description: |
> > > + bclk is optional. here is the list which require this bclk:
> > > + mt2701, mt2712, mt7623 and mt8173.
> >
> > Similarly to my comment in other patch, this should be part of schema
> > within 'if-then'.
>
> Thanks for the review.
>
> I will change like this:
>
> =============
> clocks:
> items:
> - description: bclk is the block clock.
>
> clock-names:
> items:
> - const: bclk
>
> required:
> - compatible
> - reg
> - interrupts
> - mediatek,larbs
> - '#iommu-cells'
> if:
> properties:
> compatible:
> contains:
> enum:
> - mediatek,mt2701-m4u
> - mediatek,mt2712-m4u
> - mediatek,mt8173-m4u
>
> then:
> required:
> - clocks
> ==============
>
> If this is not right, please tell me.
> (dt_binding_check is ok.)

Looks fine, except "if" should be part of some "allOf" block.

Best regards,
Krzysztof

\
 
 \ /
  Last update: 2020-10-12 19:09    [W:0.102 / U:9.456 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site