diff options
author | Vladimir Oltean <vladimir.oltean@nxp.com> | 2023-08-07 22:33:20 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2023-08-10 01:59:21 +0300 |
commit | b63e78fca889e07931ec8f259701718a24e5052e (patch) | |
tree | d486889627adb4441379f617eca900ba55e8a140 /drivers/net/netdevsim/netdevsim.h | |
parent | 40b0425f8ba17c32cf7182975032a3999c364dfc (diff) | |
download | linux-b63e78fca889e07931ec8f259701718a24e5052e.tar.xz |
net: netdevsim: use mock PHC driver
I'd like to make netdevsim offload tc-taprio, but currently, this Qdisc
emits a ETHTOOL_GET_TS_INFO call to the driver to make sure that it has
a PTP clock, so that it is reasonably capable of offloading the schedule.
By using the mock PHC driver, that becomes possible.
Hardware timestamping is not necessary, and netdevsim does not support
packet I/O anyway.
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Link: https://lore.kernel.org/r/20230807193324.4128292-8-vladimir.oltean@nxp.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/netdevsim/netdevsim.h')
-rw-r--r-- | drivers/net/netdevsim/netdevsim.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/netdevsim/netdevsim.h b/drivers/net/netdevsim/netdevsim.h index 7be98b7dcca9..028c825b86db 100644 --- a/drivers/net/netdevsim/netdevsim.h +++ b/drivers/net/netdevsim/netdevsim.h @@ -19,6 +19,7 @@ #include <linux/kernel.h> #include <linux/list.h> #include <linux/netdevice.h> +#include <linux/ptp_mock.h> #include <linux/u64_stats_sync.h> #include <net/devlink.h> #include <net/udp_tunnel.h> @@ -93,6 +94,7 @@ struct netdevsim { struct net_device *netdev; struct nsim_dev *nsim_dev; struct nsim_dev_port *nsim_dev_port; + struct mock_phc *phc; u64 tx_packets; u64 tx_bytes; |