From: Alexander Duyck <alexander.duyck@gmail.com>
To: Richard Cochran <richardcochran@gmail.com>,
Alexander Duyck <alexander.h.duyck@intel.com>
Cc: davem@davemloft.net, nhorman@redhat.com, netdev@vger.kernel.org,
john.fastabend@gmail.com, matthew.vick@intel.com,
jeffrey.t.kirsher@intel.com, sassmann@redhat.com
Subject: Re: [net-next PATCH 29/29] fm10k: Add support for PTP
Date: Sat, 20 Sep 2014 16:36:45 -0700 [thread overview]
Message-ID: <541E0F8D.3040900@gmail.com> (raw)
In-Reply-To: <20140920211647.GB5258@netboy>
On 09/20/2014 02:16 PM, Richard Cochran wrote:
> On Fri, Sep 19, 2014 at 11:32:24AM -0700, Alexander Duyck wrote:
>> Because the value cannot be adjusted directly. The timesource for the
>> switch is shared by all ports and host interfaces. As such we have to
>> maintain a software offset per host to avoid corrupting the other clocks.
> So any host can set the time, but only one may adjust the frequency?
Yes. Essentially the one who should be adjusting the frequency should
be the host interface that is providing traffic for the control plane
processor. That way the control plane processor can act as a boundary
clock and can adjust the frequency to match the port it has decided to
be a slave on.
In the case of the ordinary clock host interfaces they will be slaves to
the boundary clock and since they share the same clock source anyway
they shouldn't need any frequency adjustments, or at least that is how
it is supposed to work. The other reason for using the software offset
is that it can be very time intensive as you have to stop the clock,
update the staring value for each host interface and the Ethernet ports,
and then you can resume the clock. It can be a rather time consuming
process doing it that way versus just maintaining an offset in software.
Tx timestamps from the host interface are actually identical to the Rx
timestamps on the receiving host interface in the case of traffic going
between two fm10k host interfaces on the same switch. So what you end
up with is that any two hosts should be able to perfectly synchronize
their clocks with just the follow-up to the first sync message. I've
done some testing for this with an FPGA and actually it has proven out
as ptp4l did one offset adjustment on the follow-up and then indicated 0
adjustments from there forward. It is one of the reasons why I believe
we should be able to disable the frequency adjustment for interfaces
configured as ordinary clocks.
> Regarding the overflow, probably you can remove the daily check, since
> you only need a single clock read every 300 years, and that is
> reasonable to expect in any case.
Yeah, I figured that out after I recalled that the overflow check is
only really necessary if the mask is less than 64 bits.
Thanks,
Alex
next prev parent reply other threads:[~2014-09-20 23:36 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-18 22:35 [net-next PATCH 00/29] Add support for the Intel FM10000 Ethernet Switch Host Interface Alexander Duyck
2014-09-18 22:35 ` [net-next PATCH 01/29] fm10k: Add skeletal frame for Intel(R) FM10000 Ethernet Switch Host Interface Driver Alexander Duyck
2014-09-18 22:35 ` [net-next PATCH 02/29] fm10k: Add register defines and basic structures Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 03/29] fm10k: Add support for TLV message parsing and generation Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 04/29] fm10k: Add support for basic interaction with hardware Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 05/29] fm10k: Add support for mailbox Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 06/29] fm10k: Implement PF <-> SM mailbox operations Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 07/29] fm10k: Add support for PF Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 08/29] fm10k: Add support for configuring PF interface Alexander Duyck
2014-09-18 22:36 ` [net-next PATCH 09/29] fm10k: Add netdev Alexander Duyck
2014-09-18 22:37 ` [net-next PATCH 10/29] fm10k: Add support for L2 filtering Alexander Duyck
2014-09-18 22:37 ` [net-next PATCH 11/29] fm10k: Add support for ndo_open/stop Alexander Duyck
2014-09-18 22:37 ` [net-next PATCH 12/29] fm10k: Add interrupt support Alexander Duyck
2014-09-18 22:37 ` [net-next PATCH 13/29] fm10k: add support for Tx/Rx rings Alexander Duyck
2014-09-18 22:37 ` [net-next PATCH 14/29] fm10k: Add service task to handle delayed events Alexander Duyck
2014-09-18 22:37 ` [net-next PATCH 15/29] fm10k: Add Tx/Rx hardware ring bring-up/tear-down Alexander Duyck
2014-09-18 22:38 ` [net-next PATCH 16/29] fm10k: Add transmit and receive fastpath and interrupt handlers Alexander Duyck
2014-09-18 22:38 ` [net-next PATCH 17/29] fm10k: Add ethtool support Alexander Duyck
2014-09-18 22:38 ` [net-next PATCH 18/29] fm10k: Add support for PCI power management and error handling Alexander Duyck
2014-09-18 22:38 ` [net-next PATCH 19/29] fm10k: Add support for multiple queues Alexander Duyck
2014-09-18 22:38 ` [net-next PATCH 20/29] fm10k: Add support for netdev offloads Alexander Duyck
2014-09-18 22:39 ` [net-next PATCH 21/29] fm10k: Add support for MACVLAN acceleration Alexander Duyck
2014-09-18 22:39 ` [net-next PATCH 22/29] fm10k: Add support for PF <-> VF mailbox Alexander Duyck
2014-09-18 22:39 ` [net-next PATCH 23/29] fm10k: Add support for VF Alexander Duyck
2014-09-18 22:39 ` [net-next PATCH 24/29] fm10k: Add support for SR-IOV to PF core files Alexander Duyck
2014-09-18 22:39 ` [net-next PATCH 25/29] fm10k: Add support for SR-IOV to driver Alexander Duyck
2014-09-18 22:40 ` [net-next PATCH 26/29] fm10k: Add support for IEEE DCBx Alexander Duyck
2014-09-18 22:40 ` [net-next PATCH 27/29] fm10k: Add support for debugfs Alexander Duyck
2014-09-18 22:40 ` [net-next PATCH 28/29] fm10k: Add support for ptp to hw specific files Alexander Duyck
2014-09-19 7:38 ` Richard Cochran
2014-09-19 14:36 ` Alexander Duyck
2014-09-19 15:19 ` Richard Cochran
2014-09-19 15:34 ` Alexander Duyck
2014-09-18 22:40 ` [net-next PATCH 29/29] fm10k: Add support for PTP Alexander Duyck
2014-09-19 17:35 ` Richard Cochran
2014-09-19 18:32 ` Alexander Duyck
2014-09-20 21:07 ` Richard Cochran
2014-09-20 21:37 ` Joe Perches
2014-09-20 21:16 ` Richard Cochran
2014-09-20 23:36 ` Alexander Duyck [this message]
2014-09-22 11:03 ` David Laight
2014-09-22 14:21 ` Alexander Duyck
2014-09-19 7:55 ` [net-next PATCH 00/29] Add support for the Intel FM10000 Ethernet Switch Host Interface Jiri Pirko
2014-09-19 14:43 ` Alexander Duyck
2014-09-19 10:57 ` Jamal Hadi Salim
2014-09-19 14:54 ` Alexander Duyck
2014-09-19 16:58 ` Alexei Starovoitov
2014-09-19 18:22 ` Alexander Duyck
2014-09-19 23:52 ` Alexander Duyck
2014-09-20 2:03 ` David Miller
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=541E0F8D.3040900@gmail.com \
--to=alexander.duyck@gmail.com \
--cc=alexander.h.duyck@intel.com \
--cc=davem@davemloft.net \
--cc=jeffrey.t.kirsher@intel.com \
--cc=john.fastabend@gmail.com \
--cc=matthew.vick@intel.com \
--cc=netdev@vger.kernel.org \
--cc=nhorman@redhat.com \
--cc=richardcochran@gmail.com \
--cc=sassmann@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.