From: Ivan Vecera <ivecera@redhat.com>
To: Jakub Kicinski <kuba@kernel.org>, Jiri Pirko <jiri@resnulli.us>
Cc: netdev@vger.kernel.org, Andrew Lunn <andrew+netdev@lunn.ch>,
Arkadiusz Kubalewski <arkadiusz.kubalewski@intel.com>,
"David S. Miller" <davem@davemloft.net>,
Donald Hunter <donald.hunter@gmail.com>,
Eric Dumazet <edumazet@google.com>,
Jonathan Corbet <corbet@lwn.net>,
Leon Romanovsky <leon@kernel.org>, Mark Bloch <mbloch@nvidia.com>,
Michal Schmidt <mschmidt@redhat.com>,
Paolo Abeni <pabeni@redhat.com>,
Pasi Vaananen <pvaanane@redhat.com>, Petr Oros <poros@redhat.com>,
Prathosh Satish <Prathosh.Satish@microchip.com>,
Saeed Mahameed <saeedm@nvidia.com>,
Shuah Khan <skhan@linuxfoundation.org>,
Simon Horman <horms@kernel.org>, Tariq Toukan <tariqt@nvidia.com>,
Vadim Fedorenko <vadim.fedorenko@linux.dev>,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-rdma@vger.kernel.org
Subject: Re: [PATCH net-next v3 1/2] dpll: add fractional frequency offset to pin-parent-device
Date: Thu, 7 May 2026 08:12:01 +0200 [thread overview]
Message-ID: <541f767d-222b-4dfa-a95a-19a5ed7a46bf@redhat.com> (raw)
In-Reply-To: <20260506183342.767b5fbc@kernel.org>
On 5/7/26 3:33 AM, Jakub Kicinski wrote:
> On Mon, 4 May 2026 17:53:39 +0200 Ivan Vecera wrote:
>> + At top level this represents the RX vs TX symbol rate
>> + offset on the media associated with the pin.
>
> Isn't this a hacky hack? I'd think that pin is in or out.
> Having a freq offset between two pins or pin and parent's
> ref lock makes sense. This new interpretation sounds like
> we are trying to shove a difference between two pins into one?
The "RX vs TX symbol rate offset" description is not something I
introduced — it is the original documentation of the
fractional-frequency-offset attribute as defined by Jiri. The -ppt
variant was added later purely for higher precision. This patch just
unifies the documentation of both attributes.
I'm not sure I fully understand what the original "RX vs TX" semantics
were meant to capture. Jiri, could you clarify what you had in mind
and whether we should keep or change that description?
>> @@ -299,6 +299,10 @@ zl3073x_dpll_input_pin_ffo_get(const struct dpll_pin *dpll_pin, void *pin_priv,
>> {
>> struct zl3073x_dpll_pin *pin = pin_priv;
>>
>> + /* Only rx vs tx symbol rate FFO is supported */
>> + if (dpll)
>> + return -ENODATA;
>> +
>> *ffo = pin->freq_offset;
>
> It's easy for driver authors to forget this sort of validation.
> We should fail close, so it's better to have some "capability"
> bits or something for the driver to opt into getting given format
> of the call.
Regarding the fail-close concern — I agree that relying on drivers
to check dpll==NULL is fragile. A capability bit alone wouldn't help
though, since the driver still needs to distinguish which FFO context
is being requested.
I can think of two approaches:
1. An explicit bool parameter (e.g. `bool per_parent`) instead of
overloading the dpll pointer for context distinction.
2. Separate callbacks for each FFO context (e.g. ffo_get for the
top-level and ffo_parent_get for the per-parent).
Do you have a preference, or something else in mind?
Thanks,
Ivan
next prev parent reply other threads:[~2026-05-07 6:12 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-04 15:53 [PATCH net-next v3 0/2] dpll: rework fractional frequency offset reporting Ivan Vecera
2026-05-04 15:53 ` [PATCH net-next v3 1/2] dpll: add fractional frequency offset to pin-parent-device Ivan Vecera
2026-05-05 11:31 ` Jiri Pirko
2026-05-07 1:33 ` Jakub Kicinski
2026-05-07 6:12 ` Ivan Vecera [this message]
2026-05-07 14:47 ` Jakub Kicinski
2026-05-07 11:08 ` Jiri Pirko
2026-05-04 15:53 ` [PATCH net-next v3 2/2] dpll: zl3073x: report FFO as DPLL vs input reference offset Ivan Vecera
2026-05-05 14:34 ` Petr Oros
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=541f767d-222b-4dfa-a95a-19a5ed7a46bf@redhat.com \
--to=ivecera@redhat.com \
--cc=Prathosh.Satish@microchip.com \
--cc=andrew+netdev@lunn.ch \
--cc=arkadiusz.kubalewski@intel.com \
--cc=corbet@lwn.net \
--cc=davem@davemloft.net \
--cc=donald.hunter@gmail.com \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=jiri@resnulli.us \
--cc=kuba@kernel.org \
--cc=leon@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=mbloch@nvidia.com \
--cc=mschmidt@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=poros@redhat.com \
--cc=pvaanane@redhat.com \
--cc=saeedm@nvidia.com \
--cc=skhan@linuxfoundation.org \
--cc=tariqt@nvidia.com \
--cc=vadim.fedorenko@linux.dev \
/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