Commit b18fe47c authored by Kory Maincent's avatar Kory Maincent Committed by David S. Miller
Browse files

net: Make net_hwtstamp_validate accessible



Make the net_hwtstamp_validate function accessible in prevision to use
it from ethtool to validate the hwtstamp configuration before setting it.

Reviewed-by: default avatarFlorian Fainelli <florian.fainelli@broadcom.com>
Reviewed-by: default avatarJacob Keller <jacob.e.keller@intel.com>
Signed-off-by: default avatarKory Maincent <kory.maincent@bootlin.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5e51e50e
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -312,5 +312,6 @@ int dev_set_hwtstamp_phylib(struct net_device *dev,
			    struct netlink_ext_ack *extack);
int dev_get_hwtstamp_phylib(struct net_device *dev,
			    struct kernel_hwtstamp_config *cfg);
int net_hwtstamp_validate(const struct kernel_hwtstamp_config *cfg);

#endif
+1 −1
Original line number Diff line number Diff line
@@ -184,7 +184,7 @@ static int dev_ifsioc_locked(struct net *net, struct ifreq *ifr, unsigned int cm
	return err;
}

static int net_hwtstamp_validate(const struct kernel_hwtstamp_config *cfg)
int net_hwtstamp_validate(const struct kernel_hwtstamp_config *cfg)
{
	enum hwtstamp_tx_types tx_type;
	enum hwtstamp_rx_filters rx_filter;