Commit 289354f2 authored by Jakub Kicinski's avatar Jakub Kicinski
Browse files

net: partial revert of the "Make timestamping selectable: series

Revert following commits:

commit acec05fb ("net_tstamp: Add TIMESTAMPING SOFTWARE and HARDWARE mask")
commit 11d55be0 ("net: ethtool: Add a command to expose current time stamping layer")
commit bb8645b0 ("netlink: specs: Introduce new netlink command to get current timestamp")
commit d905f9c7 ("net: ethtool: Add a command to list available time stamping layers")
commit aed5004e ("netlink: specs: Introduce new netlink command to list available time stamping layers")
commit 51bdf316 ("net: Replace hwtstamp_source by timestamping layer")
commit 0f7f463d ("net: Change the API of PHY default timestamp to MAC")
commit 091fab12 ("net: ethtool: ts: Update GET_TS to reply the current selected timestamp")
commit 152c75e1 ("net: ethtool: ts: Let the active time stamping layer be selectable")
commit ee60ea6b ("netlink: specs: Introduce time stamping set command")

They need more time for reviews.

Link: https://lore.kernel.org/all/20231118183529.6e67100c@kernel.org/


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 055dd751
Loading
Loading
Loading
Loading
+0 −57
Original line number Diff line number Diff line
@@ -939,26 +939,6 @@ attribute-sets:
      -
        name: burst-tmr
        type: u32
  -
    name: ts
    attributes:
      -
        name: header
        type: nest
        nested-attributes: header
      -
        name: ts-layer
        type: u32
  -
    name: ts-list
    attributes:
      -
        name: header
        type: nest
        nested-attributes: header
      -
        name: ts-list-layer
        type: binary

operations:
  enum-model: directional
@@ -1709,40 +1689,3 @@ operations:
      name: mm-ntf
      doc: Notification for change in MAC Merge configuration.
      notify: mm-get
    -
      name: ts-get
      doc: Get current timestamp

      attribute-set: ts

      do:
        request:
          attributes:
            - header
        reply:
          attributes: &ts
            - header
            - ts-layer
    -
      name: ts-list-get
      doc: Get list of timestamp devices available on an interface

      attribute-set: ts-list

      do:
        request:
          attributes:
            - header
        reply:
          attributes:
            - header
            - ts-list-layer
    -
      name: ts-set
      doc: Set the timestamp device

      attribute-set: ts

      do:
        request:
          attributes: *ts
+0 −63
Original line number Diff line number Diff line
@@ -225,9 +225,6 @@ Userspace to kernel:
  ``ETHTOOL_MSG_RSS_GET``               get RSS settings
  ``ETHTOOL_MSG_MM_GET``                get MAC merge layer state
  ``ETHTOOL_MSG_MM_SET``                set MAC merge layer parameters
  ``ETHTOOL_MSG_TS_GET``                get current timestamping
  ``ETHTOOL_MSG_TS_LIST_GET``           list available timestampings
  ``ETHTOOL_MSG_TS_SET``                set current timestamping
  ===================================== =================================

Kernel to userspace:
@@ -271,8 +268,6 @@ Kernel to userspace:
  ``ETHTOOL_MSG_PSE_GET_REPLY``            PSE parameters
  ``ETHTOOL_MSG_RSS_GET_REPLY``            RSS settings
  ``ETHTOOL_MSG_MM_GET_REPLY``             MAC merge layer status
  ``ETHTOOL_MSG_TS_GET_REPLY``             current timestamping
  ``ETHTOOL_MSG_TS_LIST_GET_REPLY``        available timestampings
  ======================================== =================================

``GET`` requests are sent by userspace applications to retrieve device
@@ -1999,61 +1994,6 @@ The attributes are propagated to the driver through the following structure:
.. kernel-doc:: include/linux/ethtool.h
    :identifiers: ethtool_mm_cfg

TS_GET
======

Gets current timestamping.

Request contents:

  =================================  ======  ====================
  ``ETHTOOL_A_TS_HEADER``            nested  request header
  =================================  ======  ====================

Kernel response contents:

  =======================  ======  ==============================
  ``ETHTOOL_A_TS_HEADER``  nested  reply header
  ``ETHTOOL_A_TS_LAYER``   u32     current timestamping
  =======================  ======  ==============================

This command get the current timestamp layer.

TS_LIST_GET
===========

Get the list of available timestampings.

Request contents:

  =================================  ======  ====================
  ``ETHTOOL_A_TS_HEADER``            nested  request header
  =================================  ======  ====================

Kernel response contents:

  ===========================  ======  ==============================
  ``ETHTOOL_A_TS_HEADER``      nested  reply header
  ``ETHTOOL_A_TS_LIST_LAYER``  binary  available timestampings
  ===========================  ======  ==============================

This command lists all the possible timestamp layer available.

TS_SET
======

Modify the selected timestamping.

Request contents:

  =======================  ======  ===================
  ``ETHTOOL_A_TS_HEADER``  nested  reply header
  ``ETHTOOL_A_TS_LAYER``   u32     timestamping
  =======================  ======  ===================

This command set the timestamping with one that should be listed by the
TSLIST_GET command.

Request translation
===================

@@ -2160,7 +2100,4 @@ are netlink only.
  n/a                                 ``ETHTOOL_MSG_PLCA_GET_STATUS``
  n/a                                 ``ETHTOOL_MSG_MM_GET``
  n/a                                 ``ETHTOOL_MSG_MM_SET``
  n/a                                 ``ETHTOOL_MSG_TS_GET``
  n/a                                 ``ETHTOOL_MSG_TS_LIST_GET``
  n/a                                 ``ETHTOOL_MSG_TS_SET``
  =================================== =====================================
+3 −3
Original line number Diff line number Diff line
@@ -470,15 +470,15 @@ static int lan966x_port_hwtstamp_set(struct net_device *dev,
	struct lan966x_port *port = netdev_priv(dev);
	int err;

	if (cfg->source != MAC_TIMESTAMPING &&
	    cfg->source != PHY_TIMESTAMPING)
	if (cfg->source != HWTSTAMP_SOURCE_NETDEV &&
	    cfg->source != HWTSTAMP_SOURCE_PHYLIB)
		return -EOPNOTSUPP;

	err = lan966x_ptp_setup_traps(port, cfg);
	if (err)
		return err;

	if (cfg->source == MAC_TIMESTAMPING) {
	if (cfg->source == HWTSTAMP_SOURCE_NETDEV) {
		if (!port->lan966x->ptp)
			return -EOPNOTSUPP;

+0 −3
Original line number Diff line number Diff line
@@ -931,9 +931,6 @@ struct bcm_ptp_private *bcm_ptp_probe(struct phy_device *phydev)
		return ERR_CAST(clock);
	priv->ptp_clock = clock;

	/* Timestamp selected by default to keep legacy API */
	phydev->default_timestamp = true;

	priv->phydev = phydev;
	bcm_ptp_init(priv);

+0 −3
Original line number Diff line number Diff line
@@ -1450,9 +1450,6 @@ static int dp83640_probe(struct phy_device *phydev)
	phydev->mii_ts = &dp83640->mii_ts;
	phydev->priv = dp83640;

	/* Timestamp selected by default to keep legacy API */
	phydev->default_timestamp = true;

	spin_lock_init(&dp83640->rx_lock);
	skb_queue_head_init(&dp83640->rx_queue);
	skb_queue_head_init(&dp83640->tx_queue);
Loading