mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Arınç ÜNAL" <arinc.unal@arinc9.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
	Andrew Lunn <andrew@lunn.ch>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Vladimir Oltean <olteanv@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	AngeloGioacchino Del Regno 
	<angelogioacchino.delregno@collabora.com>,
	Daniel Golle <daniel@makrotopia.org>,
	Landen Chao <Landen.Chao@mediatek.com>,
	DENG Qingfang <dqfext@gmail.com>,
	Sean Wang <sean.wang@mediatek.com>
Cc: erkin.bozoglu@xeront.com, netdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org
Subject: Re: [PATCH 3/7] dt-bindings: net: dsa: mediatek,mt7530: add port bindings for MT7988
Date: Thu, 6 Apr 2023 22:18:51 +0300	[thread overview]
Message-ID: <5b3a10ff-e960-1c6e-3482-cb25200c83c6@arinc9.com> (raw)
In-Reply-To: <23c8c4b5-baaa-b72b-4103-b415d970acf2@linaro.org>

On 6.04.2023 22:07, Krzysztof Kozlowski wrote:
> On 06/04/2023 10:01, arinc9.unal@gmail.com wrote:
>> From: Arınç ÜNAL <arinc.unal@arinc9.com>
>>
>> The switch on MT7988 has got only port 6 as a CPU port. The only phy-mode
>> to be used is internal. Add this.
>>
>> Some bindings are incorrect for this switch now, so move them to more
>> specific places.
>>
>> Address the incorrect information of which ports can be used as a user
>> port. Any port can be used as a user port.
>>
>> Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
>> ---
>>   .../bindings/net/dsa/mediatek,mt7530.yaml     | 63 ++++++++++++++-----
>>   1 file changed, 46 insertions(+), 17 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
>> index 7045a98d9593..605888ce2bc6 100644
>> --- a/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
>> +++ b/Documentation/devicetree/bindings/net/dsa/mediatek,mt7530.yaml
>> @@ -160,22 +160,6 @@ patternProperties:
>>         "^(ethernet-)?port@[0-9]+$":
>>           type: object
>>   
>> -        properties:
>> -          reg:
>> -            description:
>> -              Port address described must be 5 or 6 for CPU port and from 0 to 5
>> -              for user ports.
>> -
>> -        allOf:
>> -          - if:
>> -              required: [ ethernet ]
>> -            then:
>> -              properties:
>> -                reg:
>> -                  enum:
>> -                    - 5
>> -                    - 6
>> -
> 
> I have doubts that the binding is still maintainable/reviewable. First,
> why do you need all above patterns after removal of entire contents?

The 'type: object' item is still globally used. I'd have to define that 
on each definitions, I suppose?

> 
> Second, amount of if-then-if-then located in existing blocks (not
> top-level) is quite big. I counted if-then-using defs, where defs has
> patternProps-patternProps-if-then-if-then-properties.... OMG. :)

Yup, not much to do if we want to keep the information. I'm still 
maintaining this though. ¯\_(ツ)_/¯

Arınç

  reply	other threads:[~2023-04-06 19:19 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-06  8:01 [PATCH 1/7] dt-bindings: net: dsa: mediatek,mt7530: correct brand name arinc9.unal
2023-04-06  8:01 ` [PATCH 2/7] dt-bindings: net: dsa: mediatek,mt7530: improve MCM and MT7988 information arinc9.unal
2023-04-06  9:46   ` Daniel Golle
2023-04-06 19:00   ` Krzysztof Kozlowski
2023-04-06  8:01 ` [PATCH 3/7] dt-bindings: net: dsa: mediatek,mt7530: add port bindings for MT7988 arinc9.unal
2023-04-06  9:46   ` Daniel Golle
2023-04-06 19:07   ` Krzysztof Kozlowski
2023-04-06 19:18     ` Arınç ÜNAL [this message]
2023-04-07  9:07       ` Krzysztof Kozlowski
2023-04-07  9:46         ` Arınç ÜNAL
2023-04-12 16:39           ` Krzysztof Kozlowski
2023-04-12 17:44             ` Arınç ÜNAL
2023-04-06  8:01 ` [PATCH 4/7] dt-bindings: net: dsa: mediatek,mt7530: allow delayed rgmii phy-modes arinc9.unal
2023-04-06  9:48   ` Daniel Golle
2023-04-06  8:01 ` [PATCH 5/7] dt-bindings: net: dsa: mediatek,mt7530: disallow reset without mediatek,mcm arinc9.unal
2023-04-06  9:48   ` Daniel Golle
2023-04-06 19:08   ` Krzysztof Kozlowski
2023-04-06 19:19     ` Arınç ÜNAL
2023-04-07  9:07       ` Krzysztof Kozlowski
2023-04-06  8:01 ` [PATCH 6/7] dt-bindings: net: dsa: mediatek,mt7530: disallow core-supply and io-supply arinc9.unal
2023-04-06  9:49   ` Daniel Golle
2023-04-06  8:01 ` [PATCH 7/7] dt-bindings: net: dsa: mediatek,mt7530: allow mediatek,mcm on MT7531 arinc9.unal
2023-04-06  9:49   ` Daniel Golle
2023-04-06  9:46 ` [PATCH 1/7] dt-bindings: net: dsa: mediatek,mt7530: correct brand name Daniel Golle
2023-04-06 19:00 ` Krzysztof Kozlowski
2023-04-06 19:23   ` Arınç ÜNAL

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5b3a10ff-e960-1c6e-3482-cb25200c83c6@arinc9.com \
    --to=arinc.unal@arinc9.com \
    --cc=Landen.Chao@mediatek.com \
    --cc=andrew@lunn.ch \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=daniel@makrotopia.org \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=dqfext@gmail.com \
    --cc=edumazet@google.com \
    --cc=erkin.bozoglu@xeront.com \
    --cc=f.fainelli@gmail.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=kuba@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=matthias.bgg@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=pabeni@redhat.com \
    --cc=robh+dt@kernel.org \
    --cc=sean.wang@mediatek.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®