From: Richard Cochran <richardcochran@gmail.com>
To: Bryan.Whitehead@microchip.com
Cc: davem@davemloft.net, netdev@vger.kernel.org,
UNGLinuxDriver@microchip.com
Subject: Re: [PATCH v2 net-next 9/9] lan743x: Add PTP support
Date: Wed, 18 Jul 2018 13:55:54 -0700 [thread overview]
Message-ID: <20180718205554.odob5pnzmct6klho@localhost> (raw)
In-Reply-To: <90A7E81AE28BAE4CBDDB3B35F187D2644073B039@CHN-SV-EXMX02.mchp-main.com>
On Wed, Jul 18, 2018 at 08:04:08PM +0000, Bryan.Whitehead@microchip.com wrote:
> Thank you for your detailed feedback. I'm working on it now, but I feel it will take a little extra time to complete. Therefor I'm planning to remove PTP support from this patch series, and resubmit it in a new patch later.
Ok.
> > > + if (cleanup) {
> > > + lan743x_ptp_unrequest_tx_timestamp(tx->adapter);
> > > + dev_kfree_skb(buffer_info->skb);
> > > + } else {
> > > + lan743x_ptp_tx_timestamp_skb(tx->adapter,
> > > + buffer_info->skb,
> > > + (buffer_info->flags &
> > > +
> > TX_BUFFER_INFO_FLAG_IGNORE_SYNC)
> > > + != 0);
> >
> > This is poor coding style. Please find a better way.
>
> Can you clarify what is poor and what would be better?
> For example, should I change "X != 0" to "X ? true : false".
Look at this:
lan743x_ptp_tx_timestamp_skb(tx->adapter,
buffer_info->skb,
(buffer_info->flags &
TX_BUFFER_INFO_FLAG_IGNORE_SYNC)
!= 0);
Can't you reduce
(buffer_info->flags & TX_BUFFER_INFO_FLAG_IGNORE_SYNC) != 0
into a local variable:
lan743x_ptp_tx_timestamp_skb(tx->adapter, buffer_info->skb, xyz);
?
> So you mean PPS is not intended to generate a physical signal?
Yes.
> It is only intended to call ptp_clock_event?
Yes.
> I can configure the hardware to generate an interrupt each second and then call
> ptp_clock_event. Would that satisfy the pps requirements?
Yes.
> Regarding PTP_CLK_REQ_PEROUT. Is that intended for physical signals?
Yes.
Thanks,
Richard
next prev parent reply other threads:[~2018-07-18 21:35 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-12 19:04 [PATCH v2 net-next 0/9] lan743x: Add features to lan743x driver Bryan Whitehead
2018-07-12 19:04 ` [PATCH v2 net-next 1/9] lan743x: Add support for ethtool get_drvinfo Bryan Whitehead
2018-07-12 22:28 ` Andrew Lunn
2018-07-12 19:04 ` [PATCH v2 net-next 2/9] lan743x: Add support for ethtool link settings Bryan Whitehead
2018-07-12 22:29 ` Andrew Lunn
2018-07-12 19:05 ` [PATCH v2 net-next 3/9] lan743x: Add support for ethtool statistics Bryan Whitehead
2018-07-12 22:31 ` Andrew Lunn
2018-07-12 19:05 ` [PATCH v2 net-next 4/9] lan743x: Add support for ethtool message level Bryan Whitehead
2018-07-12 22:31 ` Andrew Lunn
2018-07-12 19:05 ` [PATCH v2 net-next 5/9] lan743x: Add support for ethtool eeprom access Bryan Whitehead
2018-07-12 22:35 ` Andrew Lunn
2018-07-12 19:05 ` [PATCH v2 net-next 6/9] lan743x: Add power management support Bryan Whitehead
2018-07-12 22:42 ` Andrew Lunn
2018-07-18 20:05 ` Bryan.Whitehead
2018-07-12 19:05 ` [PATCH v2 net-next 7/9] lan743x: Add EEE support Bryan Whitehead
2018-07-12 22:49 ` Andrew Lunn
2018-07-13 16:35 ` Bryan.Whitehead
2018-07-12 19:05 ` [PATCH v2 net-next 8/9] lan743x: Add RSS support Bryan Whitehead
2018-07-12 19:05 ` [PATCH v2 net-next 9/9] lan743x: Add PTP support Bryan Whitehead
2018-07-13 3:31 ` Richard Cochran
2018-07-18 20:04 ` Bryan.Whitehead
2018-07-18 20:55 ` Richard Cochran [this message]
2018-07-18 21:05 ` Bryan.Whitehead
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=20180718205554.odob5pnzmct6klho@localhost \
--to=richardcochran@gmail.com \
--cc=Bryan.Whitehead@microchip.com \
--cc=UNGLinuxDriver@microchip.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.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).