From: sundeep subbaraya <sundeep.lkml@gmail.com>
To: Jakub Kicinski <kuba@kernel.org>
Cc: David Miller <davem@davemloft.net>,
richardcochran@gmail.com, netdev@vger.kernel.org,
sgoutham@marvell.com, Aleksey Makarov <amakarov@marvell.com>,
Subbaraya Sundeep <sbhatta@marvell.com>
Subject: Re: [PATCH v2 net-next 3/3] octeontx2-pf: Add support for PTP clock
Date: Thu, 9 Jul 2020 18:24:42 +0530 [thread overview]
Message-ID: <CALHRZupLPK22=fia+sRNG5k0HDe7xjxfCOB+tFN5fhZOf4K_-Q@mail.gmail.com> (raw)
In-Reply-To: <20200708104056.1ed85daf@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Hi Jakub,
On Wed, Jul 8, 2020 at 11:10 PM Jakub Kicinski <kuba@kernel.org> wrote:
>
> On Wed, 8 Jul 2020 22:20:18 +0530 sundeep.lkml@gmail.com wrote:
> > From: Aleksey Makarov <amakarov@marvell.com>
> >
> > This patch adds PTP clock and uses it in Octeontx2
> > network device. PTP clock uses mailbox calls to
> > access the hardware counter on the RVU side.
> >
> > Co-developed-by: Subbaraya Sundeep <sbhatta@marvell.com>
> > Signed-off-by: Subbaraya Sundeep <sbhatta@marvell.com>
> > Signed-off-by: Aleksey Makarov <amakarov@marvell.com>
> > Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
>
> Please address the new sparse warnings as well:
>
> drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c:130:42: warning: cast to restricted __be64
>
Sure. There are some already existing in octeontx2/ for those I will
fix and submit after this patch set.
> > +static inline void otx2_set_rxtstamp(struct otx2_nic *pfvf,
> > + struct sk_buff *skb, void *data)
> > +{
>
> Please don't use static inline in C files, compiler will know which
> static functions to inline, and static inline covers up unused code.
>
Sure.
Thanks,
Sundeep
> > + u64 tsns;
> > + int err;
> > +
> > + if (!(pfvf->flags & OTX2_FLAG_RX_TSTAMP_ENABLED))
> > + return;
> > +
> > + /* The first 8 bytes is the timestamp */
> > + err = otx2_ptp_tstamp2time(pfvf, be64_to_cpu(*(u64 *)data), &tsns);
> > + if (err)
> > + return;
> > +
> > + skb_hwtstamps(skb)->hwtstamp = ns_to_ktime(tsns);
> > +}
prev parent reply other threads:[~2020-07-09 12:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-08 16:50 [PATCH v2 net-next 0/3] Add PTP support for Octeontx2 sundeep.lkml
2020-07-08 16:50 ` [PATCH v2 net-next 1/3] octeontx2-af: Support to enable/disable HW timestamping sundeep.lkml
2020-07-08 16:50 ` [PATCH v2 net-next 2/3] octeontx2-af: Add support for Marvell PTP coprocessor sundeep.lkml
2020-07-08 16:50 ` [PATCH v2 net-next 3/3] octeontx2-pf: Add support for PTP clock sundeep.lkml
2020-07-08 17:40 ` Jakub Kicinski
2020-07-09 12:54 ` sundeep subbaraya [this message]
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='CALHRZupLPK22=fia+sRNG5k0HDe7xjxfCOB+tFN5fhZOf4K_-Q@mail.gmail.com' \
--to=sundeep.lkml@gmail.com \
--cc=amakarov@marvell.com \
--cc=davem@davemloft.net \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=richardcochran@gmail.com \
--cc=sbhatta@marvell.com \
--cc=sgoutham@marvell.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).