devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matej Vasilevski <matej.vasilevski@seznam.cz>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: Pavel Pisa <pisa@cmp.felk.cvut.cz>,
	Ondrej Ille <ondrej.ille@gmail.com>,
	Wolfgang Grandegger <wg@grandegger.com>,
	Marc Kleine-Budde <mkl@pengutronix.de>,
	"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>,
	linux-can@vger.kernel.org, netdev@vger.kernel.org,
	devicetree@vger.kernel.org
Subject: Re: [PATCH v2 2/3] dt-bindings: can: ctucanfd: add another clock for HW timestamping
Date: Wed, 3 Aug 2022 00:41:46 +0200	[thread overview]
Message-ID: <20220802224146.GA4457@hopium> (raw)
In-Reply-To: <cb88bd4a-5f42-477d-c419-c4d90bf06b1f@linaro.org>

On Tue, Aug 02, 2022 at 09:49:03AM +0200, Krzysztof Kozlowski wrote:
> On 01/08/2022 20:46, Matej Vasilevski wrote:
> > Add second clock phandle to specify the timestamping clock.
> > You can even use the same clock as the core, or define a fixed-clock
> > if you need something custom.
> > 
> > Signed-off-by: Matej Vasilevski <matej.vasilevski@seznam.cz>
> > ---
> >  .../bindings/net/can/ctu,ctucanfd.yaml        | 23 +++++++++++++++----
> >  1 file changed, 19 insertions(+), 4 deletions(-)
> > 
> > diff --git a/Documentation/devicetree/bindings/net/can/ctu,ctucanfd.yaml b/Documentation/devicetree/bindings/net/can/ctu,ctucanfd.yaml
> > index 4635cb96fc64..90390530f909 100644
> > --- a/Documentation/devicetree/bindings/net/can/ctu,ctucanfd.yaml
> > +++ b/Documentation/devicetree/bindings/net/can/ctu,ctucanfd.yaml
> > @@ -44,9 +44,23 @@ properties:
> >  
> >    clocks:
> >      description: |
> > -      phandle of reference clock (100 MHz is appropriate
> > -      for FPGA implementation on Zynq-7000 system).
> > -    maxItems: 1
> > +      Phandle of reference clock (100 MHz is appropriate for FPGA
> > +      implementation on Zynq-7000 system). If you wish to use timestamps
> > +      from the controller, add a second phandle with the clock used for
> > +      timestamping. The timestamping clock is optional, if you don't
> > +      add it here, the driver will use the primary clock frequency for
> > +      timestamp calculations. If you need something custom, define
> > +      a fixed-clock oscillator and reference it.
> 
> This should not be a guide how to write DTS, but description of
> hardware. The references to driver are also not really appropriate in
> the bindings (are you 100% sure that all other operating systems and SW
> have driver which behaves like this...)
> 

Hello Krzysztof,

thanks for your comment. I'll rewrite it so that it only describes
the hardware.

Best regards,
Matej

> > +    minItems: 1
> > +    items:
> > +      - description: core clock
> > +      - description: timestamping clock
> > +
> > +  clock-names:
> > +    minItems: 1
> > +    items:
> > +      - const: core-clk
> > +      - const: ts-clk
> >  
> >  required:
> >    - compatible
> > @@ -61,6 +75,7 @@ examples:
> >      ctu_can_fd_0: can@43c30000 {
> >        compatible = "ctu,ctucanfd";
> >        interrupts = <0 30 4>;
> > -      clocks = <&clkc 15>;
> > +      clocks = <&clkc 15>, <&clkc 16>;
> > +      clock-names = "core-clk", "ts-clk";
> >        reg = <0x43c30000 0x10000>;
> >      };
> 
> 
> Best regards,
> Krzysztof

  reply	other threads:[~2022-08-02 22:44 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-01 18:46 [PATCH v2 0/3] can: ctucanfd: hardware rx timestamps reporting Matej Vasilevski
2022-08-01 18:46 ` [PATCH v2 1/3] can: ctucanfd: add HW timestamps to RX and error CAN frames Matej Vasilevski
2022-08-01 20:42   ` Pavel Pisa
2022-08-02  3:43   ` Vincent Mailhol
2022-08-02  6:42     ` Matej Vasilevski
2022-08-02  7:37     ` Pavel Pisa
2022-08-03  9:04       ` Marc Kleine-Budde
2022-08-04  8:08         ` Pavel Pisa
2022-08-12 14:35       ` Vincent Mailhol
2022-08-12 15:19         ` Pavel Pisa
2022-08-26 22:26           ` Vincent Mailhol
2022-08-02  9:29   ` Marc Kleine-Budde
2022-08-02 10:26     ` Marc Kleine-Budde
2022-08-02 16:20     ` Pavel Pisa
2022-08-03  8:37       ` Marc Kleine-Budde
2022-08-04  8:08         ` Pavel Pisa
2022-08-04  9:11           ` Marc Kleine-Budde
2022-08-03  0:09     ` Matej Vasilevski
2022-08-03  6:11       ` Pavel Pisa
2022-08-03  8:53       ` Marc Kleine-Budde
2022-08-17 23:14         ` Matej Vasilevski
2022-08-18  9:24           ` Marc Kleine-Budde
2022-08-18 16:03             ` Matej Vasilevski
2022-08-01 18:46 ` [PATCH v2 2/3] dt-bindings: can: ctucanfd: add another clock for HW timestamping Matej Vasilevski
2022-08-01 19:12   ` Pavel Pisa
2022-08-02  7:49   ` Krzysztof Kozlowski
2022-08-02 22:41     ` Matej Vasilevski [this message]
2022-08-01 18:46 ` [PATCH v2 3/3] doc: ctucanfd: RX frames timestamping for platform devices Matej Vasilevski
2022-08-01 19:12   ` Pavel Pisa
2022-08-02  7:06 ` [PATCH v2 0/3] can: ctucanfd: hardware rx timestamps reporting Marc Kleine-Budde

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=20220802224146.GA4457@hopium \
    --to=matej.vasilevski@seznam.cz \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=edumazet@google.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=kuba@kernel.org \
    --cc=linux-can@vger.kernel.org \
    --cc=mkl@pengutronix.de \
    --cc=netdev@vger.kernel.org \
    --cc=ondrej.ille@gmail.com \
    --cc=pabeni@redhat.com \
    --cc=pisa@cmp.felk.cvut.cz \
    --cc=robh+dt@kernel.org \
    --cc=wg@grandegger.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;
as well as URLs for NNTP newsgroup(s).