RX software timestamp for all
Subsystems (40)
cover RX software timestamp for all
All devices support SOF_TIMESTAMPING_RX_SOFTWARE by virtue of net_timestamp_check() being called in the device independent code. Following Willem's suggestion [1], make it so drivers do not have to handle SOF_TIMESTAMPING_RX_SOFTWARE and SOF_TIMESTAMPING_SOFTWARE, nor setting of the PHC index to -1.
All drivers will now report RX software timestamp as supported.
[1] https://lore.kernel.org/netdev/[email protected]/
Thanks,
Gal
Gal Pressman (2):
ethtool: RX software timestamp for all
net: Remove setting of RX software timestamp from drivers
drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ---- .../net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 -- .../marvell/octeontx2/nic/otx2_ethtool.c | 2 -- .../net/ethernet/mellanox/mlxsw/spectrum.c | 6 ++++++ .../ethernet/mellanox/mlxsw/spectrum_ptp.h | 20 ------------------- .../net/ethernet/microchip/lan743x_ethtool.c | 4 ---- .../microchip/lan966x/lan966x_ethtool.c | 11 ++++------ .../microchip/sparx5/sparx5_ethtool.c | 11 ++++------ drivers/net/ethernet/mscc/ocelot_ptp.c | 12 ++++------- .../ethernet/pensando/ionic/ionic_ethtool.c | 2 -- drivers/net/ethernet/qlogic/qede/qede_ptp.c | 9 +-------- drivers/net/ethernet/renesas/ravb_main.c | 4 ++-- drivers/net/ethernet/renesas/rswitch.c | 2 -- drivers/net/ethernet/renesas/rtsn.c | 2 -- drivers/net/ethernet/sfc/ethtool.c | 5 ----- drivers/net/ethernet/sfc/siena/ethtool.c | 5 ----- .../ethernet/stmicro/stmmac/stmmac_ethtool.c | 4 ++-- drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 2 -- drivers/net/ethernet/ti/cpsw_ethtool.c | 7 +------ drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 2 -- drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- net/ethtool/common.c | 19 +++++++++--------- 47 files changed, 57 insertions(+), 217 deletions(-)
Signature · 1 line
2.40.1
PATCH 1/2 ethtool: RX software timestamp for all
All devices support SOF_TIMESTAMPING_RX_SOFTWARE by virtue of net_timestamp_check() being called in the device independent code.
Move the responsibility of reporting SOF_TIMESTAMPING_RX_SOFTWARE and SOF_TIMESTAMPING_SOFTWARE, and setting PHC index to -1 to the core. Device drivers no longer need to use them.
--- net/ethtool/common.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-)
net/ethtool/common.c +10 -9
@@ -695,20 +695,21 @@ int __ethtool_get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_info {const struct ethtool_ops *ops = dev->ethtool_ops;struct phy_device *phydev = dev->phydev; +int err =0 ;memset (info,0 ,sizeof (*info)); info->cmd =ETHTOOL_GET_TS_INFO ; - -if (phy_is_default_hwtstamp (phydev) &&phy_has_tsinfo (phydev)) -return phy_ts_info (phydev, info); -if (ops->get_ts_info) -return ops->get_ts_info (dev, info); - - info->so_timestamping =SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; info->phc_index =-1 ; -return 0 ; +if (phy_is_default_hwtstamp (phydev) &&phy_has_tsinfo (phydev)) + err =phy_ts_info (phydev, info); +else if (ops->get_ts_info) + err = ops->get_ts_info (dev, info); + + info->so_timestamping |=SOF_TIMESTAMPING_RX_SOFTWARE | +SOF_TIMESTAMPING_SOFTWARE ; + +return err; }int ethtool_get_phc_vclocks (struct net_device *dev,int **vclock_index)
Signature · 1 line
2.40.1
PATCH 2/2 net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanThe responsibility for reporting of RX software timestamp has moved to the core layer (see __ethtool_get_ts_info()), remove usage from the device drivers.
--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ---- .../net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 -- .../marvell/octeontx2/nic/otx2_ethtool.c | 2 -- .../net/ethernet/mellanox/mlxsw/spectrum.c | 6 ++++++ .../ethernet/mellanox/mlxsw/spectrum_ptp.h | 20 ------------------- .../net/ethernet/microchip/lan743x_ethtool.c | 4 ---- .../microchip/lan966x/lan966x_ethtool.c | 11 ++++------ .../microchip/sparx5/sparx5_ethtool.c | 11 ++++------ drivers/net/ethernet/mscc/ocelot_ptp.c | 12 ++++------- .../ethernet/pensando/ionic/ionic_ethtool.c | 2 -- drivers/net/ethernet/qlogic/qede/qede_ptp.c | 9 +-------- drivers/net/ethernet/renesas/ravb_main.c | 4 ++-- drivers/net/ethernet/renesas/rswitch.c | 2 -- drivers/net/ethernet/renesas/rtsn.c | 2 -- drivers/net/ethernet/sfc/ethtool.c | 5 ----- drivers/net/ethernet/sfc/siena/ethtool.c | 5 ----- .../ethernet/stmicro/stmmac/stmmac_ethtool.c | 4 ++-- drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 2 -- drivers/net/ethernet/ti/cpsw_ethtool.c | 7 +------ drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 2 -- drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)
drivers/net/bonding/bond_main.c +0 -3
@@ -5770,9 +5770,6 @@ static int bond_ethtool_get_ts_info(struct net_device *bond_dev,if (real_dev) { ret =ethtool_get_ts_info_by_layer (real_dev, info); }else { - info->phc_index =-1 ; - info->so_timestamping =SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ;/* Check if all slaves support software tx timestamping */ rcu_read_lock ();bond_for_each_slave_rcu (bond, slave, iter) {
drivers/net/can/dev/dev.c +0 -3
@@ -380,12 +380,9 @@ int can_ethtool_op_get_ts_info_hwts(struct net_device *dev, { info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_ON ); info->rx_filters =BIT (HWTSTAMP_FILTER_ALL );
drivers/net/can/peak_canfd/peak_canfd.c +0 -3
@@ -781,11 +781,8 @@ static int peak_get_ts_info(struct net_device *dev, { info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_OFF ); info->rx_filters =BIT (HWTSTAMP_FILTER_ALL );
drivers/net/can/usb/peak_usb/pcan_usb_core.c +0 -3
@@ -901,11 +901,8 @@ int pcan_get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_info *info { info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_OFF ); info->rx_filters =BIT (HWTSTAMP_FILTER_ALL );
drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c +0 -4
@@ -582,16 +582,12 @@ static int xgbe_get_ts_info(struct net_device *netdev,struct xgbe_prv_data *pdata =netdev_priv (netdev); ts_info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (pdata->ptp_clock) ts_info->phc_index =ptp_clock_index (pdata->ptp_clock); -else - ts_info->phc_index =-1 ; ts_info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON ); ts_info->rx_filters = (1 << HWTSTAMP_FILTER_NONE) |
drivers/net/ethernet/broadcom/bnx2x/bnx2x_ethtool.c +0 -4
@@ -3640,16 +3640,12 @@ static int bnx2x_get_ts_info(struct net_device *dev,if (bp->flags &PTP_SUPPORTED ) { info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (bp->ptp_clock) info->phc_index =ptp_clock_index (bp->ptp_clock); -else - info->phc_index =-1 ; info->rx_filters = (1 <<HWTSTAMP_FILTER_NONE ) | (1 << HWTSTAMP_FILTER_PTP_V1_L4_EVENT) |
drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c +1 -4
@@ -5040,11 +5040,8 @@ static int bnxt_get_ts_info(struct net_device *dev,struct bnxt_ptp_cfg *ptp; ptp = bp->ptp_cfg; - info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; + info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE ; - info->phc_index =-1 ;if (!ptp)return 0 ;
drivers/net/ethernet/broadcom/tg3.c +1 -5
@@ -6145,9 +6145,7 @@ static int tg3_get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_info {struct tg3 *tp =netdev_priv (dev); - info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; + info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE ;if (tg3_flag (tp,PTP_CAPABLE )) { info->so_timestamping |= SOF_TIMESTAMPING_TX_HARDWARE |
@@ -6157,8 +6155,6 @@ static int tg3_get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_infoif (tp->ptp_clock) info->phc_index =ptp_clock_index (tp->ptp_clock); -else - info->phc_index =-1 ; info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON );
drivers/net/ethernet/cadence/macb_main.c +2 -3
@@ -3410,8 +3410,6 @@ static int gem_get_ts_info(struct net_device *dev, info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
@@ -3423,7 +3421,8 @@ static int gem_get_ts_info(struct net_device *dev, (1 <<HWTSTAMP_FILTER_NONE ) | (1 <<HWTSTAMP_FILTER_ALL ); - info->phc_index = bp->ptp_clock ?ptp_clock_index (bp->ptp_clock) :-1 ; +if (bp->ptp_clock) + info->phc_index =ptp_clock_index (bp->ptp_clock);return 0 ; }
drivers/net/ethernet/cavium/liquidio/lio_ethtool.c +7 -9
@@ -2496,37 +2496,31 @@ static int lio_set_intr_coalesce(struct net_device *netdev,return ret; } +#ifdef PTP_HARDWARE_TIMESTAMPING static int lio_get_ts_info (struct net_device *netdev,struct kernel_ethtool_ts_info *info) {struct lio *lio =GET_LIO (netdev); info->so_timestamping = -#ifdef PTP_HARDWARE_TIMESTAMPING SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE | -SOF_TIMESTAMPING_TX_SOFTWARE | -#endif -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +SOF_TIMESTAMPING_TX_SOFTWARE ;if (lio->ptp_clock) info->phc_index =ptp_clock_index (lio->ptp_clock); -else - info->phc_index =-1 ; -#ifdef PTP_HARDWARE_TIMESTAMPING info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON ); info->rx_filters = (1 <<HWTSTAMP_FILTER_NONE ) | (1 <<HWTSTAMP_FILTER_PTP_V1_L4_EVENT ) | (1 <<HWTSTAMP_FILTER_PTP_V2_L2_EVENT ) | (1 <<HWTSTAMP_FILTER_PTP_V2_L4_EVENT ); -#endif return 0 ; } +#endif /* Return register dump len. */ static int lio_get_regs_len (struct net_device *dev)
@@ -3146,7 +3140,9 @@ static const struct ethtool_ops lio_ethtool_ops = { .set_coalesce = lio_set_intr_coalesce, .get_priv_flags = lio_get_priv_flags, .set_priv_flags = lio_set_priv_flags, +#ifdef PTP_HARDWARE_TIMESTAMPING .get_ts_info = lio_get_ts_info, +#endif };static const struct ethtool_ops lio_vf_ethtool_ops = {
@@ -3169,7 +3165,9 @@ static const struct ethtool_ops lio_vf_ethtool_ops = { .set_coalesce = lio_set_intr_coalesce, .get_priv_flags = lio_get_priv_flags, .set_priv_flags = lio_set_priv_flags, +#ifdef PTP_HARDWARE_TIMESTAMPING .get_ts_info = lio_get_ts_info, +#endif };void liquidio_set_ethtool_ops (struct net_device *netdev)
drivers/net/ethernet/cavium/thunder/nicvf_ethtool.c +0 -2
@@ -844,8 +844,6 @@ static int nicvf_get_ts_info(struct net_device *netdev,return ethtool_op_get_ts_info (netdev, info); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c +3 -8
@@ -1556,12 +1556,9 @@ static int get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_info *tsstruct adapter *adapter = pi->adapter; ts_info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; - - ts_info->so_timestamping |=SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_TX_HARDWARE | -SOF_TIMESTAMPING_RAW_HARDWARE ; +SOF_TIMESTAMPING_RX_HARDWARE | +SOF_TIMESTAMPING_TX_HARDWARE | +SOF_TIMESTAMPING_RAW_HARDWARE ; ts_info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON );
@@ -1575,8 +1572,6 @@ static int get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_info *tsif (adapter->ptp_clock) ts_info->phc_index =ptp_clock_index (adapter->ptp_clock); -else - ts_info->phc_index =-1 ;return 0 ; }
drivers/net/ethernet/cisco/enic/enic_ethtool.c +1 -3
@@ -601,9 +601,7 @@ static int enic_set_rxfh(struct net_device *netdev,static int enic_get_ts_info (struct net_device *netdev,struct kernel_ethtool_ts_info *info) { - info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; + info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; }
drivers/net/ethernet/engleder/tsnep_ethtool.c +0 -4
@@ -310,16 +310,12 @@ static int tsnep_ethtool_get_ts_info(struct net_device *netdev,struct tsnep_adapter *adapter =netdev_priv (netdev); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (adapter->ptp_clock) info->phc_index =ptp_clock_index (adapter->ptp_clock); -else - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_OFF ) |BIT (HWTSTAMP_TX_ON );
drivers/net/ethernet/freescale/enetc/enetc_ethtool.c +2 -8
@@ -849,17 +849,13 @@ static int enetc_get_ts_info(struct net_device *ndev,if (phc_idx) { info->phc_index = *phc_idx;symbol_put (enetc_phc_index); - }else { - info->phc_index =-1 ; }#ifdef CONFIG_FSL_ENETC_PTP_CLOCK info->so_timestamping =SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE | -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +SOF_TIMESTAMPING_TX_SOFTWARE ; info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 << HWTSTAMP_TX_ON) |
@@ -867,9 +863,7 @@ static int enetc_get_ts_info(struct net_device *ndev, info->rx_filters = (1 <<HWTSTAMP_FILTER_NONE ) | (1 <<HWTSTAMP_FILTER_ALL );#else - info->so_timestamping =SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; + info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE ;#endif return 0 ; }
drivers/net/ethernet/freescale/fec_main.c +0 -4
@@ -2775,15 +2775,11 @@ static int fec_enet_get_ts_info(struct net_device *ndev,if (fep->bufdesc_ex) { info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (fep->ptp_clock) info->phc_index =ptp_clock_index (fep->ptp_clock); -else - info->phc_index =-1 ; info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON );
drivers/net/ethernet/freescale/gianfar_ethtool.c +2 -8
@@ -1455,12 +1455,8 @@ static int gfar_get_ts_info(struct net_device *dev,struct device_node *ptp_node;struct ptp_qoriq *ptp =NULL ; - info->phc_index =-1 ; -if (!(priv->device_flags &FSL_GIANFAR_DEV_HAS_TIMER )) { - info->so_timestamping =SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; + info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; }
@@ -1478,9 +1474,7 @@ static int gfar_get_ts_info(struct net_device *dev, info->so_timestamping =SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +SOF_TIMESTAMPING_TX_SOFTWARE ; info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON ); info->rx_filters = (1 << HWTSTAMP_FILTER_NONE) |
drivers/net/ethernet/fungible/funeth/funeth_ethtool.c +1 -4
@@ -1042,12 +1042,9 @@ static int fun_set_rxfh(struct net_device *netdev,static int fun_get_ts_info (struct net_device *netdev,struct kernel_ethtool_ts_info *info) { - info->so_timestamping =SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_RX_HARDWARE | + info->so_timestamping =SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_OFF ); info->rx_filters =BIT (HWTSTAMP_FILTER_NONE ) |BIT (HWTSTAMP_FILTER_ALL );return 0 ;
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ptp.c +0 -4
@@ -389,16 +389,12 @@ int hclge_ptp_get_ts_info(struct hnae3_handle *handle, } info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (hdev->ptp->clock) info->phc_index =ptp_clock_index (hdev->ptp->clock); -else - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_OFF ) |BIT (HWTSTAMP_TX_ON );
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +0 -4
@@ -2555,16 +2555,12 @@ static int i40e_get_ts_info(struct net_device *dev,return ethtool_op_get_ts_info (dev, info); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (pf->ptp_clock) info->phc_index =ptp_clock_index (pf->ptp_clock); -else - info->phc_index =-1 ; info->tx_types =BIT (HWTSTAMP_TX_OFF ) |BIT (HWTSTAMP_TX_ON );
drivers/net/ethernet/intel/ice/ice_ethtool.c +0 -2
@@ -3792,8 +3792,6 @@ ice_get_ts_info(struct net_device *dev, struct kernel_ethtool_ts_info *info)return ethtool_op_get_ts_info (dev, info); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/intel/igb/igb_ethtool.c +1 -7
@@ -2387,15 +2387,11 @@ static int igb_get_ts_info(struct net_device *dev,if (adapter->ptp_clock) info->phc_index =ptp_clock_index (adapter->ptp_clock); -else - info->phc_index =-1 ;switch (adapter->hw.mac.type) {case e1000_82575: info->so_timestamping = -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ;case e1000_82576:case e1000_82580:
@@ -2405,8 +2401,6 @@ static int igb_get_ts_info(struct net_device *dev,case e1000_i211: info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/intel/igc/igc_ethtool.c +0 -4
@@ -1565,15 +1565,11 @@ static int igc_ethtool_get_ts_info(struct net_device *dev,if (adapter->ptp_clock) info->phc_index =ptp_clock_index (adapter->ptp_clock); -else - info->phc_index =-1 ;switch (adapter->hw.mac.type) {case igc_i225: info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c +0 -4
@@ -3196,16 +3196,12 @@ static int ixgbe_get_ts_info(struct net_device *dev, info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (adapter->ptp_clock) info->phc_index =ptp_clock_index (adapter->ptp_clock); -else - info->phc_index =-1 ; info->tx_types = BIT(HWTSTAMP_TX_OFF) |
drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c +0 -2
@@ -5268,8 +5268,6 @@ static int mvpp2_ethtool_get_ts_info(struct net_device *dev, info->phc_index =mvpp22_tai_ptp_clock_index (port->priv->tai); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/marvell/octeontx2/nic/otx2_ethtool.c +0 -2
@@ -962,8 +962,6 @@ static int otx2_get_ts_info(struct net_device *netdev,return ethtool_op_get_ts_info (netdev, info); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/mellanox/mlxsw/spectrum.c +6 -0
@@ -2784,7 +2784,9 @@ static const struct mlxsw_sp_ptp_ops mlxsw_sp1_ptp_ops = { .hwtstamp_get = mlxsw_sp1_ptp_hwtstamp_get, .hwtstamp_set = mlxsw_sp1_ptp_hwtstamp_set, .shaper_work = mlxsw_sp1_ptp_shaper_work, +#if IS_REACHABLE(CONFIG_PTP_1588_CLOCK) .get_ts_info = mlxsw_sp1_ptp_get_ts_info, +#endif .get_stats_count = mlxsw_sp1_get_stats_count, .get_stats_strings = mlxsw_sp1_get_stats_strings, .get_stats = mlxsw_sp1_get_stats,
@@ -2801,7 +2803,9 @@ static const struct mlxsw_sp_ptp_ops mlxsw_sp2_ptp_ops = { .hwtstamp_get = mlxsw_sp2_ptp_hwtstamp_get, .hwtstamp_set = mlxsw_sp2_ptp_hwtstamp_set, .shaper_work = mlxsw_sp2_ptp_shaper_work, +#if IS_REACHABLE(CONFIG_PTP_1588_CLOCK) .get_ts_info = mlxsw_sp2_ptp_get_ts_info, +#endif .get_stats_count = mlxsw_sp2_get_stats_count, .get_stats_strings = mlxsw_sp2_get_stats_strings, .get_stats = mlxsw_sp2_get_stats,
@@ -2818,7 +2822,9 @@ static const struct mlxsw_sp_ptp_ops mlxsw_sp4_ptp_ops = { .hwtstamp_get = mlxsw_sp2_ptp_hwtstamp_get, .hwtstamp_set = mlxsw_sp2_ptp_hwtstamp_set, .shaper_work = mlxsw_sp2_ptp_shaper_work, +#if IS_REACHABLE(CONFIG_PTP_1588_CLOCK) .get_ts_info = mlxsw_sp2_ptp_get_ts_info, +#endif .get_stats_count = mlxsw_sp2_get_stats_count, .get_stats_strings = mlxsw_sp2_get_stats_strings, .get_stats = mlxsw_sp2_get_stats,
drivers/net/ethernet/mellanox/mlxsw/spectrum_ptp.h +0 -20
@@ -11,14 +11,6 @@ struct mlxsw_sp;struct mlxsw_sp_port ;struct mlxsw_sp_ptp_clock ; -static inline int mlxsw_sp_ptp_get_ts_info_noptp (struct kernel_ethtool_ts_info *info) -{ - info->so_timestamping =SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; - info->phc_index =-1 ; -return 0 ; -} -#if IS_REACHABLE (CONFIG_PTP_1588_CLOCK ) struct mlxsw_sp_ptp_clock *
@@ -151,12 +143,6 @@ static inline void mlxsw_sp1_ptp_shaper_work(struct work_struct *work) { } -static inline int mlxsw_sp1_ptp_get_ts_info (struct mlxsw_sp *mlxsw_sp, -struct kernel_ethtool_ts_info *info) -{ -return mlxsw_sp_ptp_get_ts_info_noptp (info); -} -static inline int mlxsw_sp1_get_stats_count (void ) {return 0 ;
@@ -226,12 +212,6 @@ mlxsw_sp2_ptp_hwtstamp_set(struct mlxsw_sp_port *mlxsw_sp_port,return -EOPNOTSUPP ; } -static inline int mlxsw_sp2_ptp_get_ts_info (struct mlxsw_sp *mlxsw_sp, -struct kernel_ethtool_ts_info *info) -{ -return mlxsw_sp_ptp_get_ts_info_noptp (info); -} - static inline int mlxsw_sp2_ptp_txhdr_construct(struct mlxsw_core *mlxsw_core, struct mlxsw_sp_port *mlxsw_sp_port,
drivers/net/ethernet/microchip/lan743x_ethtool.c +0 -4
@@ -1034,16 +1034,12 @@ static int lan743x_ethtool_get_ts_info(struct net_device *netdev,struct lan743x_adapter *adapter =netdev_priv (netdev); ts_info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (adapter->ptp.ptp_clock) ts_info->phc_index =ptp_clock_index (adapter->ptp.ptp_clock); -else - ts_info->phc_index =-1 ; ts_info->tx_types =BIT (HWTSTAMP_TX_OFF ) | BIT(HWTSTAMP_TX_ON) |
drivers/net/ethernet/microchip/lan966x/lan966x_ethtool.c +4 -7
@@ -549,16 +549,13 @@ static int lan966x_get_ts_info(struct net_device *dev, phc = &lan966x->phc[LAN966X_PHC_PORT ]; - info->phc_index = phc->clock ?ptp_clock_index (phc->clock) :-1 ; -if (info->phc_index ==-1 ) { - info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +if (phc->clock) { + info->phc_index =ptp_clock_index (phc->clock); + }else { + info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; } info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/microchip/sparx5/sparx5_ethtool.c +4 -7
@@ -1194,16 +1194,13 @@ static int sparx5_get_ts_info(struct net_device *dev, phc = &sparx5->phc[SPARX5_PHC_PORT ]; - info->phc_index = phc->clock ?ptp_clock_index (phc->clock) :-1 ; -if (info->phc_index ==-1 ) { - info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +if (phc->clock) { + info->phc_index =ptp_clock_index (phc->clock); + }else { + info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; } info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/mscc/ocelot_ptp.c +4 -8
@@ -582,17 +582,13 @@ EXPORT_SYMBOL(ocelot_hwstamp_set);int ocelot_get_ts_info (struct ocelot *ocelot,int port,struct kernel_ethtool_ts_info *info) { - info->phc_index = ocelot->ptp_clock ? -ptp_clock_index (ocelot->ptp_clock) :-1 ; -if (info->phc_index ==-1 ) { - info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +if (ocelot->ptp_clock) { + info->phc_index =ptp_clock_index (ocelot->ptp_clock); + }else { + info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; } info->so_timestamping |=SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/pensando/ionic/ionic_ethtool.c +0 -2
@@ -989,8 +989,6 @@ static int ionic_get_ts_info(struct net_device *netdev, info->phc_index =ptp_clock_index (lif->phc->ptp); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/qlogic/qede/qede_ptp.c +1 -8
@@ -326,25 +326,18 @@ int qede_ptp_get_ts_info(struct qede_dev *edev, struct kernel_ethtool_ts_info *istruct qede_ptp *ptp = edev->ptp;if (!ptp) { - info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; - info->phc_index =-1 ; + info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; } info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (ptp->clock) info->phc_index =ptp_clock_index (ptp->clock); -else - info->phc_index =-1 ; info->rx_filters =BIT (HWTSTAMP_FILTER_NONE ) | BIT(HWTSTAMP_FILTER_PTP_V1_L4_EVENT) |
drivers/net/ethernet/renesas/ravb_main.c +2 -2
@@ -1744,8 +1744,6 @@ static int ravb_get_ts_info(struct net_device *ndev, info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
@@ -1756,6 +1754,8 @@ static int ravb_get_ts_info(struct net_device *ndev, (1 <<HWTSTAMP_FILTER_ALL );if (hw_info->gptp || hw_info->ccc_gac) info->phc_index =ptp_clock_index (priv->ptp.clock); +else + info->phc_index =0 ;return 0 ; }
drivers/net/ethernet/renesas/rswitch.c +0 -2
@@ -1815,8 +1815,6 @@ static int rswitch_get_ts_info(struct net_device *ndev, struct kernel_ethtool_ts info->phc_index =ptp_clock_index (rdev->priv->ptp_priv->clock); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/renesas/rtsn.c +0 -2
@@ -1219,8 +1219,6 @@ static int rtsn_get_ts_info(struct net_device *ndev, info->phc_index =ptp_clock_index (priv->ptp_priv->clock); info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/sfc/ethtool.c +0 -5
@@ -230,11 +230,6 @@ static int efx_ethtool_get_ts_info(struct net_device *net_dev, {struct efx_nic *efx =efx_netdev_priv (net_dev); -/* Software capabilities */ - ts_info->so_timestamping = (SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ); - ts_info->phc_index =-1 ; -efx_ptp_get_ts_info (efx, ts_info);return 0 ; }
drivers/net/ethernet/sfc/siena/ethtool.c +0 -5
@@ -230,11 +230,6 @@ static int efx_ethtool_get_ts_info(struct net_device *net_dev, {struct efx_nic *efx =netdev_priv (net_dev); -/* Software capabilities */ - ts_info->so_timestamping = (SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ); - ts_info->phc_index =-1 ; -efx_siena_ptp_get_ts_info (efx, ts_info);return 0 ; }
drivers/net/ethernet/stmicro/stmmac/stmmac_ethtool.c +2 -2
@@ -1207,13 +1207,13 @@ static int stmmac_get_ts_info(struct net_device *dev, info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (priv->ptp_clock) info->phc_index =ptp_clock_index (priv->ptp_clock); +else + info->phc_index =0 ; info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 <<HWTSTAMP_TX_ON );
drivers/net/ethernet/ti/am65-cpsw-ethtool.c +0 -2
@@ -714,8 +714,6 @@ static int am65_cpsw_get_ethtool_ts_info(struct net_device *ndev,SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_TX_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; info->phc_index =am65_cpts_phc_index (common->cpts); info->tx_types =BIT (HWTSTAMP_TX_OFF ) |BIT (HWTSTAMP_TX_ON );
drivers/net/ethernet/ti/cpsw_ethtool.c +1 -6
@@ -725,8 +725,6 @@ int cpsw_get_ts_info(struct net_device *ndev, struct kernel_ethtool_ts_info *infSOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_TX_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; info->phc_index = cpsw->cpts->phc_index; info->tx_types =
@@ -741,10 +739,7 @@ int cpsw_get_ts_info(struct net_device *ndev, struct kernel_ethtool_ts_info *infint cpsw_get_ts_info (struct net_device *ndev,struct kernel_ethtool_ts_info *info) { info->so_timestamping = -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; - info->phc_index =-1 ; +SOF_TIMESTAMPING_TX_SOFTWARE ; info->tx_types =0 ; info->rx_filters =0 ;return 0 ;
drivers/net/ethernet/ti/icssg/icssg_ethtool.c +0 -2
@@ -118,8 +118,6 @@ static int emac_get_ts_info(struct net_device *ndev,SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_TX_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; info->phc_index =icss_iep_get_ptp_clock_idx (emac->iep);
drivers/net/ethernet/ti/netcp_ethss.c +1 -6
@@ -2012,8 +2012,6 @@ static int keystone_get_ts_info(struct net_device *ndev,SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_TX_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; info->phc_index = gbe_intf->gbe_dev->cpts->phc_index; info->tx_types =
@@ -2030,10 +2028,7 @@ static int keystone_get_ts_info(struct net_device *ndev, struct kernel_ethtool_ts_info *info) { info->so_timestamping = -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; - info->phc_index =-1 ; +SOF_TIMESTAMPING_TX_SOFTWARE ; info->tx_types =0 ; info->rx_filters =0 ;return 0 ;
drivers/net/ethernet/xscale/ixp4xx_eth.c +1 -3
@@ -1026,9 +1026,7 @@ static int ixp4xx_get_ts_info(struct net_device *dev,if (info->phc_index <0 ) { info->so_timestamping = -SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE ; +SOF_TIMESTAMPING_TX_SOFTWARE ;return 0 ; } info->so_timestamping =
drivers/ptp/ptp_ines.c +0 -4
@@ -562,12 +562,8 @@ static int ines_ts_info(struct mii_timestamper *mii_ts,SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_TX_SOFTWARE |SOF_TIMESTAMPING_RX_HARDWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_RAW_HARDWARE ; - info->phc_index =-1 ; - info->tx_types = (1 <<HWTSTAMP_TX_OFF ) | (1 << HWTSTAMP_TX_ON) |
Signature · 1 line
2.40.1
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
Quoted 47 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ---- .../net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 -- .../marvell/octeontx2/nic/otx2_ethtool.c | 2 -- .../net/ethernet/mellanox/mlxsw/spectrum.c | 6 ++++++ .../ethernet/mellanox/mlxsw/spectrum_ptp.h | 20 ------------------- .../net/ethernet/microchip/lan743x_ethtool.c | 4 ---- .../microchip/lan966x/lan966x_ethtool.c | 11 ++++------ .../microchip/sparx5/sparx5_ethtool.c | 11 ++++------ drivers/net/ethernet/mscc/ocelot_ptp.c | 12 ++++------- .../ethernet/pensando/ionic/ionic_ethtool.c | 2 -- drivers/net/ethernet/qlogic/qede/qede_ptp.c | 9 +-------- drivers/net/ethernet/renesas/ravb_main.c | 4 ++-- drivers/net/ethernet/renesas/rswitch.c | 2 -- drivers/net/ethernet/renesas/rtsn.c | 2 -- drivers/net/ethernet/sfc/ethtool.c | 5 ----- drivers/net/ethernet/sfc/siena/ethtool.c | 5 -----
Quoted 8 lines
.../ethernet/stmicro/stmmac/stmmac_ethtool.c | 4 ++-- drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 2 -- drivers/net/ethernet/ti/cpsw_ethtool.c | 7 +------ drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 2 -- drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)
regards,
Marc
Signature · 4 lines
Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung Nürnberg | Phone: +49-5121-206917-129 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-9 |
Re: [PATCH net-next 1/2] ethtool: RX software timestamp for all
In reply to Gal PressmanQuoted 7 lines · Gal Pressman
All devices support
SOF_TIMESTAMPING_RX_SOFTWAREby virtue ofnet_timestamp_check()being called in the device independent code.Move the responsibility of reporting
SOF_TIMESTAMPING_RX_SOFTWAREandSOF_TIMESTAMPING_SOFTWARE, and setting PHC index to -1 to the core. Device drivers no longer need to use them.
Quoted 5 lines
Suggested-by Willem de Bruijn <[email protected]>Co-developed-by Rahul Rameshbabu <[email protected]>Signed-off-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>
regards,
Marc
Signature · 4 lines
Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung Nürnberg | Phone: +49-5121-206917-129 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-9 |
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 47 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ---- .../net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 -- .../marvell/octeontx2/nic/otx2_ethtool.c | 2 -- .../net/ethernet/mellanox/mlxsw/spectrum.c | 6 ++++++ .../ethernet/mellanox/mlxsw/spectrum_ptp.h | 20 ------------------- .../net/ethernet/microchip/lan743x_ethtool.c | 4 ---- .../microchip/lan966x/lan966x_ethtool.c | 11 ++++------ .../microchip/sparx5/sparx5_ethtool.c | 11 ++++------ drivers/net/ethernet/mscc/ocelot_ptp.c | 12 ++++------- .../ethernet/pensando/ionic/ionic_ethtool.c | 2 -- drivers/net/ethernet/qlogic/qede/qede_ptp.c | 9 +-------- drivers/net/ethernet/renesas/ravb_main.c | 4 ++-- drivers/net/ethernet/renesas/rswitch.c | 2 -- drivers/net/ethernet/renesas/rtsn.c | 2 -- drivers/net/ethernet/sfc/ethtool.c | 5 ----- drivers/net/ethernet/sfc/siena/ethtool.c | 5 -----
Quoted 8 lines
.../ethernet/stmicro/stmmac/stmmac_ethtool.c | 4 ++-- drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 2 -- drivers/net/ethernet/ti/cpsw_ethtool.c | 7 +------ drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 2 -- drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)
Thanks,
Gerhard
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 9 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>---
for drivers/net/ethernet/pensando/ionic
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanHi Gal,
Thanks for your work.
Quoted 15 lines · Gal Pressman
drivers/net/ethernet/renesas/ravb_main.c +0
-2@@ -1744,8 +1744,6 @@ static int ravb_get_ts_info(struct net_device *ndev, info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;
drivers/net/ethernet/renesas/ravb_main.c static int ravb_get_ts_info(struct net_device *ndev, · line 1758
Quoted 5 lines
drivers/net/ethernet/renesas/ravb_main.c +2
-0@@ -1756,6 +1754,8 @@ static int ravb_get_ts_info(struct net_device *ndev, (1 <<HWTSTAMP_FILTER_ALL );if (hw_info->gptp || hw_info->ccc_gac) info->phc_index =ptp_clock_index (priv->ptp.clock); +else + info->phc_index =0 ;
I understand this work keeps things the same as they where before and that this change do not alter the existing behavior. But should not phc_index be left untouched here (kept at -1) as there are no ptp clock?
I think this might have been introduced in commit 7e09a052dc4e ("ravb:
Exclude gPTP feature support for RZ/G2L") when the driver excluded ptp support for some devices. I suspect the so_timestamping mask should also depend on this check and only advertise hardware clocks if it indeed exists?
If my assumption is correct I can fix this on top. For this change the existing behavior is kept, so for drivers/net/ethernet/renesas,
Quoted 3 lines
drivers/net/ethernet/renesas/ravb_main.c +0
-0return 0 ; }
Signature · 2 lines
Kind Regards, Niklas Söderlund
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 19 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 --
Quoted 8 lines
.../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ----
for drivers/net/ethernet/hisilicon/hns3/
RE: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 2 lines
.../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ----
Many thanks.
For drivers/net/ethernet/freescale/fec and enetc.
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 8 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>---
for drivers/net/ethernet/marvell/octeontx2/
RE: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 38 lines
[Some people who received this message don't often get email from [email protected]. Learn why this is important at
https://aka.ms/LearnAboutSenderIdentification ]EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>---
drivers/net/ethernet/microchip/lan743x_ethtool.c +0
-4@@ -1034,16 +1034,12 @@ static int lan743x_ethtool_get_ts_info(structnet_device *netdev, struct lan743x_adapter *adapter = netdev_priv(netdev); ts_info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;if (adapter->ptp.ptp_clock) ts_info->phc_index =ptp_clock_index (adapter->ptp.ptp_clock); -else - ts_info->phc_index =-1 ; ts_info->tx_types = BIT(HWTSTAMP_TX_OFF) |
Quoted 1 line
BIT(HWTSTAMP_TX_ON)|
for drivers/net/ethernet/microchip/lan743x_ethtool.c
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal Pressmandrivers/net/ethernet/mellanox/mlxsw/spectrum_ptp.h
Quoted 9 lines · Gal Pressman
drivers/net/ethernet/mellanox/mlxsw/spectrum.c +0
-0drivers/net/ethernet/mellanox/mlxsw/spectrum_ptp.h +0
-0
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 7 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>
for:
drivers/net/ethernet/ti/am65-cpsw-ethtool.cdrivers/net/ethernet/ti/cpsw_ethtool.cdrivers/net/ethernet/ti/icssg/icssg_ethtool.c
Re: [PATCH net-next 1/2] ethtool: RX software timestamp for all
In reply to Gal PressmanQuoted 7 lines · Gal Pressman
All devices support
SOF_TIMESTAMPING_RX_SOFTWAREby virtue ofnet_timestamp_check()being called in the device independent code.Move the responsibility of reporting
SOF_TIMESTAMPING_RX_SOFTWAREandSOF_TIMESTAMPING_SOFTWARE, and setting PHC index to -1 to the core. Device drivers no longer need to use them.
Quoted 5 lines
Suggested-by Willem de Bruijn <[email protected]>Co-developed-by Rahul Rameshbabu <[email protected]>Signed-off-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Niklas SöderlundQuoted 22 lines · Niklas Söderlund
Hi Gal,
Thanks for your work.
Quoted 16 lines · Gal Pressman
drivers/net/ethernet/renesas/ravb_main.c +0
-2@@ -1744,8 +1744,6 @@ static int ravb_get_ts_info(struct net_device *ndev, info->so_timestamping =SOF_TIMESTAMPING_TX_SOFTWARE | -SOF_TIMESTAMPING_RX_SOFTWARE | -SOF_TIMESTAMPING_SOFTWARE |SOF_TIMESTAMPING_TX_HARDWARE |SOF_TIMESTAMPING_RX_HARDWARE |SOF_TIMESTAMPING_RAW_HARDWARE ;@@ -1756,6 +1754,8 @@ static int ravb_get_ts_info(struct net_device *ndev, (1 <<HWTSTAMP_FILTER_ALL );
Quoted 8 lines
drivers/net/ethernet/renesas/ravb_main.c static int ravb_get_ts_info(struct net_device *ndev, · line 1758
Quoted 4 lines
drivers/net/ethernet/renesas/ravb_main.c +2
-0if (hw_info->gptp || hw_info->ccc_gac) info->phc_index =ptp_clock_index (priv->ptp.clock); +else + info->phc_index =0 ;I understand this work keeps things the same as they where before and that this change do not alter the existing behavior. But should not
phc_indexbe left untouched here (kept at -1) as there are no ptp clock?
Yes, setting the phc_index to zero felt bad and is likely a bug, but this patch is probably not the place to fix it.
Quoted 9 lines
I think this might have been introduced in commit
7e09a052dc4e("ravb:
Exclude gPTP feature support for RZ/G2L") when the driver excluded ptp support for some devices. I suspect theso_timestampingmask should also depend on this check and only advertise hardware clocks if it indeed exists?If my assumption is correct I can fix this on top. For this change the existing behavior is kept, so for
drivers/net/ethernet/renesas,
Sounds good to me.
Quoted 2 lines
Reviewed-by Niklas Söderlund <[email protected]>
Thank you Niklas!
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 24 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ----
Quoted 8 lines
.../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ----
Richard Cochran
maintainerRe: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 3 lines · Gal Pressman
drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 ---
...
Quoted 4 lines
drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)
This needs to be broken out into one patch per driver. That way, one can easily track the Acks.
Thanks,
Richard
RE: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 7 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>
Quoted 13 lines
--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++-------
for cxgb4 changes
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Richard CochranQuoted 8 lines · Richard Cochran
Quoted 3 lines · Gal Pressman
drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 ---...
Quoted 7 lines
Quoted 4 lines
drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)This needs to be broken out into one patch per driver. That way, one can easily track the Acks.
I would, but it's not allowed to post series with more than 15 patches.
Richard Cochran
maintainerRe: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
Quoted 1 line · Gal Pressman
I would, but it's not allowed to post series with more than 15 patches.
If that worries you, then you can post in batches.
Thanks,
Richard
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 47 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ---- .../net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 -- .../marvell/octeontx2/nic/otx2_ethtool.c | 2 -- .../net/ethernet/mellanox/mlxsw/spectrum.c | 6 ++++++ .../ethernet/mellanox/mlxsw/spectrum_ptp.h | 20 ------------------- .../net/ethernet/microchip/lan743x_ethtool.c | 4 ---- .../microchip/lan966x/lan966x_ethtool.c | 11 ++++------ .../microchip/sparx5/sparx5_ethtool.c | 11 ++++------ drivers/net/ethernet/mscc/ocelot_ptp.c | 12 ++++------- .../ethernet/pensando/ionic/ionic_ethtool.c | 2 -- drivers/net/ethernet/qlogic/qede/qede_ptp.c | 9 +-------- drivers/net/ethernet/renesas/ravb_main.c | 4 ++-- drivers/net/ethernet/renesas/rswitch.c | 2 -- drivers/net/ethernet/renesas/rtsn.c | 2 -- drivers/net/ethernet/sfc/ethtool.c | 5 ----- drivers/net/ethernet/sfc/siena/ethtool.c | 5 -----
Quoted 8 lines
.../ethernet/stmicro/stmmac/stmmac_ethtool.c | 4 ++-- drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 2 -- drivers/net/ethernet/ti/cpsw_ethtool.c | 7 +------ drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 2 -- drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)
For drivers/net/ethernet/sfc and drivers/net/ethernet/sfc/siena:
Re: [PATCH net-next 2/2] net: Remove setting of RX software timestamp from drivers
In reply to Gal PressmanQuoted 47 lines · Gal Pressman
The responsibility for reporting of RX software timestamp has moved to the core layer (see
__ethtool_get_ts_info()), remove usage from the device drivers.Reviewed-by Carolina Jubran <[email protected]>Reviewed-by Rahul Rameshbabu <[email protected]>Signed-off-by Gal Pressman <[email protected]>--- drivers/net/bonding/bond_main.c | 3 --- drivers/net/can/dev/dev.c | 3 --- drivers/net/can/peak_canfd/peak_canfd.c | 3 --- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 3 --- drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c | 4 ---- .../ethernet/broadcom/bnx2x/bnx2x_ethtool.c | 4 ---- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 5 +---- drivers/net/ethernet/broadcom/tg3.c | 6 +----- drivers/net/ethernet/cadence/macb_main.c | 5 ++--- .../ethernet/cavium/liquidio/lio_ethtool.c | 16 +++++++-------- .../ethernet/cavium/thunder/nicvf_ethtool.c | 2 -- .../ethernet/chelsio/cxgb4/cxgb4_ethtool.c | 11 +++------- .../net/ethernet/cisco/enic/enic_ethtool.c | 4 +--- drivers/net/ethernet/engleder/tsnep_ethtool.c | 4 ---- .../ethernet/freescale/enetc/enetc_ethtool.c | 10 ++-------- drivers/net/ethernet/freescale/fec_main.c | 4 ---- .../net/ethernet/freescale/gianfar_ethtool.c | 10 ++-------- .../ethernet/fungible/funeth/funeth_ethtool.c | 5 +---- .../hisilicon/hns3/hns3pf/hclge_ptp.c | 4 ---- .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 ---- drivers/net/ethernet/intel/ice/ice_ethtool.c | 2 -- drivers/net/ethernet/intel/igb/igb_ethtool.c | 8 +------- drivers/net/ethernet/intel/igc/igc_ethtool.c | 4 ---- .../net/ethernet/intel/ixgbe/ixgbe_ethtool.c | 4 ---- .../net/ethernet/marvell/mvpp2/mvpp2_main.c | 2 -- .../marvell/octeontx2/nic/otx2_ethtool.c | 2 -- .../net/ethernet/mellanox/mlxsw/spectrum.c | 6 ++++++ .../ethernet/mellanox/mlxsw/spectrum_ptp.h | 20 ------------------- .../net/ethernet/microchip/lan743x_ethtool.c | 4 ---- .../microchip/lan966x/lan966x_ethtool.c | 11 ++++------ .../microchip/sparx5/sparx5_ethtool.c | 11 ++++------ drivers/net/ethernet/mscc/ocelot_ptp.c | 12 ++++------- .../ethernet/pensando/ionic/ionic_ethtool.c | 2 -- drivers/net/ethernet/qlogic/qede/qede_ptp.c | 9 +-------- drivers/net/ethernet/renesas/ravb_main.c | 4 ++-- drivers/net/ethernet/renesas/rswitch.c | 2 -- drivers/net/ethernet/renesas/rtsn.c | 2 -- drivers/net/ethernet/sfc/ethtool.c | 5 ----- drivers/net/ethernet/sfc/siena/ethtool.c | 5 -----
Quoted 9 lines
.../ethernet/stmicro/stmmac/stmmac_ethtool.c | 4 ++-- drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 2 -- drivers/net/ethernet/ti/cpsw_ethtool.c | 7 +------ drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 2 -- drivers/net/ethernet/ti/netcp_ethss.c | 7 +------ drivers/net/ethernet/xscale/ixp4xx_eth.c | 4 +--- drivers/ptp/ptp_ines.c | 4 ---- 46 files changed, 47 insertions(+), 208 deletions(-)
drivers/net/ethernet/amd/xgbe/
Thanks,
Shyam