From: Krzysztof Kozlowski <krzk@kernel.org>
To: Andrew Lunn <andrew@lunn.ch>, Jacky Chou <jacky_chou@aspeedtech.com>
Cc: Russell King <linux@armlinux.org.uk>,
Maxime Chevallier <maxime.chevallier@bootlin.com>,
"andrew+netdev@lunn.ch" <andrew+netdev@lunn.ch>,
"davem@davemloft.net" <davem@davemloft.net>,
"edumazet@google.com" <edumazet@google.com>,
"kuba@kernel.org" <kuba@kernel.org>,
"pabeni@redhat.com" <pabeni@redhat.com>,
"robh@kernel.org" <robh@kernel.org>,
"krzk+dt@kernel.org" <krzk+dt@kernel.org>,
"conor+dt@kernel.org" <conor+dt@kernel.org>,
"joel@jms.id.au" <joel@jms.id.au>,
"andrew@codeconstruct.com.au" <andrew@codeconstruct.com.au>,
"ratbert@faraday-tech.com" <ratbert@faraday-tech.com>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"linux-aspeed@lists.ozlabs.org" <linux-aspeed@lists.ozlabs.org>,
BMC-SW <BMC-SW@aspeedtech.com>
Subject: Re: 回覆: 回覆: [net-next 4/4] net: ftgmac100: add RGMII delay for AST2600
Date: Tue, 18 Mar 2025 17:38:35 +0100 [thread overview]
Message-ID: <8762dea1-3a0d-4bc8-aacd-fc8a2b5e2714@kernel.org> (raw)
In-Reply-To: <5b448c6b-a37d-4028-a56d-2953fc0e743a@lunn.ch>
On 18/03/2025 14:51, Andrew Lunn wrote:
> On Tue, Mar 18, 2025 at 05:34:08AM +0000, Jacky Chou wrote:
>> Hi Andrew,
>>
>> Thank you for your reply.
>>
>>>> The RGMII delay of AST2600 has a lot of steps can be configured.
>>>
>>> Are they uniformly space? Then it should be a simple formula to calculate? Or
>>> a lookup table?
>>
>> There are fixed delay values by step. I list below.
>> AST2600 MAC0/1 one step delay = 45 ps
>> AST2600 MAC2/3 one step delay = 250 ps
>
> That is messy.
>
>> I calculate all step and emulate them.
>> The dt-binding will be like below.
>> rx-internal-delay-ps:
>> description:
>> Setting this property to a non-zero number sets the RX internal delay
>> for the MAC. ... skip ...
>> enum:
>> [45, 90, 135, 180, 225, 250, 270, 315, 360, 405, 450, 495, 500, 540, 585, 630, 675,
>> 720, 750, 765, 810, 855, 900, 945, 990, 1000, 1035, 1080, 1125, 1170, 1215, 1250,
>> 1260, 1305, 1350, 1395, 1440, 1500, 1750, 2000, 2250, 2500, 2750, 3000, 3250, 3500,
>> 3750, 4000, 4250, 4500, 4750, 5000, 5250, 5500, 5750, 6000, 6250, 6500, 6750, 7000,
>> 7250, 7500, 7750, 8000]
>
> Can the hardware do 0 ps?
>
> So this list is a superset of both 45ps and 250ps steps?
git grep multipleOf:
e.g.
oneOf:
- minimum: 45
maximum: ...
multipleOf: 45
- minimum: 1500
maximum: ...
multipleOf: 250
>
> Lets see what the DT Maintainers say, but it could be you need two
> different compatibles for mac0/1 to mac2/3 because they are not
> actually compatible! You can then have a list per compatible.
If this is the only, *only* difference, then just go with vendor
property matching register value... but oh, wait, how person reading and
writing the DTS would understand if "0x2" means 90 ps or 1750 ps? I
don't see how the original binding was helping here in total. Just
moving the burden from driver developer to DTS developer. :/
If different instances are not the same, means the devices are not the
same, so two compatibles seem reasonable.
Best regards,
Krzysztof
next prev parent reply other threads:[~2025-03-18 16:38 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-17 2:59 [net-next 0/4] Add AST2600 RGMII delay into ftgmac100 Jacky Chou
2025-03-17 2:59 ` [net-next 1/4] ARM: dts: aspeed-g6:add scu to mac for RGMII delay Jacky Chou
2025-03-17 12:47 ` Andrew Lunn
2025-03-18 11:44 ` 回覆: " Jacky Chou
2025-03-17 2:59 ` [net-next 2/4] ARM: dts: ast2600-evb: add default " Jacky Chou
2025-03-17 13:08 ` Andrew Lunn
2025-03-18 11:00 ` 回覆: " Jacky Chou
2025-03-18 14:03 ` Andrew Lunn
2025-03-20 8:02 ` 回覆: " Jacky Chou
2025-03-17 2:59 ` [net-next 3/4] dt-bindings: net: ftgmac100: add rgmii delay properties Jacky Chou
2025-03-17 4:31 ` Rob Herring (Arm)
2025-03-17 7:32 ` Krzysztof Kozlowski
2025-03-17 7:48 ` 回覆: " Jacky Chou
2025-03-17 12:44 ` Andrew Lunn
2025-03-17 13:21 ` Krzysztof Kozlowski
2025-03-17 2:59 ` [net-next 4/4] net: ftgmac100: add RGMII delay for AST2600 Jacky Chou
2025-03-17 8:53 ` Maxime Chevallier
2025-03-17 9:28 ` 回覆: " Jacky Chou
2025-03-17 11:09 ` Russell King (Oracle)
2025-03-17 11:33 ` 回覆: " Jacky Chou
2025-03-17 12:52 ` Andrew Lunn
2025-03-18 5:34 ` 回覆: " Jacky Chou
2025-03-18 13:51 ` Andrew Lunn
2025-03-18 16:38 ` Krzysztof Kozlowski [this message]
2025-03-20 8:06 ` 回覆: " Jacky Chou
2025-03-17 13:03 ` Andrew Lunn
2025-03-18 10:46 ` 回覆: " Jacky Chou
2025-03-18 13:44 ` Andrew Lunn
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=8762dea1-3a0d-4bc8-aacd-fc8a2b5e2714@kernel.org \
--to=krzk@kernel.org \
--cc=BMC-SW@aspeedtech.com \
--cc=andrew+netdev@lunn.ch \
--cc=andrew@codeconstruct.com.au \
--cc=andrew@lunn.ch \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=jacky_chou@aspeedtech.com \
--cc=joel@jms.id.au \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-aspeed@lists.ozlabs.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=maxime.chevallier@bootlin.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=ratbert@faraday-tech.com \
--cc=robh@kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).