netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 net-next 0/7] Hardware operations for the SJA1105 DSA PTP clock
@ 2019-09-10  1:34 Vladimir Oltean
  2019-09-10  1:34 ` [PATCH v2 net-next 1/7] net: dsa: sja1105: Get rid of global declaration of struct ptp_clock_info Vladimir Oltean
                   ` (6 more replies)
  0 siblings, 7 replies; 12+ messages in thread
From: Vladimir Oltean @ 2019-09-10  1:34 UTC (permalink / raw)
  To: f.fainelli, vivien.didelot, andrew, davem, richardcochran
  Cc: netdev, Vladimir Oltean

This series performs the following changes to the PTP portion of the
driver:
- Deletes the timecounter/cyclecounter implementation of a free-running
  PHC and replaces it with actual hardware corrections of the PTP
  timestamping clock.
- Deletes the approximation of timecounter_init() with the argument of
  ktime_to_ns(ktime_get_real()) (aka system clock) that is currently
  done in sja1105_ptp_reset. Now that the PTP clock can keep the wall
  time in hardware, it makes sense to do so (and thus arises the need
  to restore the PTP time after resetting the switch).
- Profits from the fact that timecounter/cyclecounter code has been
  removed from sja1105_main.c, and goes a step further by doing some
  more cleanup and making the PTP Kconfig more self-contained. The
  cleanup also covers preparing the driver for the gettimex API
  (PTP_SYS_OFFSET_EXTENDED ioctl) - an API which at the moment does
  not have the best implementation available in the kernel for this
  switch, but for which the addition of a better API is trivial after
  the cleanup.

 drivers/net/dsa/sja1105/sja1105.h      |  18 +-
 drivers/net/dsa/sja1105/sja1105_main.c |  66 ++++--
 drivers/net/dsa/sja1105/sja1105_ptp.c  | 283 +++++++++++++------------
 drivers/net/dsa/sja1105/sja1105_ptp.h  |  78 +++++++
 drivers/net/dsa/sja1105/sja1105_spi.c  |  42 ++--
 5 files changed, 310 insertions(+), 177 deletions(-)

-- 

These are the PTP patches that have been split apart from:
https://www.spinics.net/lists/netdev/msg597214.html
("tc-taprio offload for SJA1105 DSA").
As such I have marked them as v2. There are no changes since the
tc-taprio patchset, it is only for better review-ability.

Vladimir Oltean (7):
  net: dsa: sja1105: Get rid of global declaration of struct
    ptp_clock_info
  net: dsa: sja1105: Change the PTP command access pattern
  net: dsa: sja1105: Switch to hardware operations for PTP
  net: dsa: sja1105: Implement the .gettimex64 system call for PTP
  net: dsa: sja1105: Restore PTP time after switch reset
  net: dsa: sja1105: Disallow management xmit during switch reset
  net: dsa: sja1105: Move PTP data to its own private structure

2.17.1


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2019-09-12 11:58 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-10  1:34 [PATCH v2 net-next 0/7] Hardware operations for the SJA1105 DSA PTP clock Vladimir Oltean
2019-09-10  1:34 ` [PATCH v2 net-next 1/7] net: dsa: sja1105: Get rid of global declaration of struct ptp_clock_info Vladimir Oltean
2019-09-10  1:34 ` [PATCH v2 net-next 2/7] net: dsa: sja1105: Change the PTP command access pattern Vladimir Oltean
2019-09-10  1:34 ` [PATCH v2 net-next 3/7] net: dsa: sja1105: Switch to hardware operations for PTP Vladimir Oltean
2019-09-12 10:12   ` David Miller
2019-09-12 10:17     ` Vladimir Oltean
2019-09-12 11:37       ` David Miller
2019-09-12 11:58         ` Vladimir Oltean
2019-09-10  1:34 ` [PATCH v2 net-next 4/7] net: dsa: sja1105: Implement the .gettimex64 system call " Vladimir Oltean
2019-09-10  1:34 ` [PATCH v2 net-next 5/7] net: dsa: sja1105: Restore PTP time after switch reset Vladimir Oltean
2019-09-10  1:35 ` [PATCH v2 net-next 6/7] net: dsa: sja1105: Disallow management xmit during " Vladimir Oltean
2019-09-10  1:35 ` [PATCH v2 net-next 7/7] net: dsa: sja1105: Move PTP data to its own private structure Vladimir Oltean

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).