summaryrefslogtreecommitdiffstats
path: root/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h
diff options
context:
space:
mode:
authorYangbo Lu <yangbo.lu@nxp.com>2021-04-27 06:21:59 +0200
committerDavid S. Miller <davem@davemloft.net>2021-04-27 23:10:15 +0200
commit5c5416f5d4c75fe6aba56f6c2c45a070b5e7cc78 (patch)
tree4695af6b67ad7e9e1fce5e93e93dd19be221ba01 /drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h
parentnet: dsa: no longer identify PTP packet in core driver (diff)
downloadlinux-5c5416f5d4c75fe6aba56f6c2c45a070b5e7cc78.tar.xz
linux-5c5416f5d4c75fe6aba56f6c2c45a070b5e7cc78.zip
net: dsa: no longer clone skb in core driver
It was a waste to clone skb directly in dsa_skb_tx_timestamp(). For one-step timestamping, a clone was not needed. For any failure of port_txtstamp (this may usually happen), the skb clone had to be freed. So this patch moves skb cloning for tx timestamp out of dsa core, and let drivers clone skb in port_txtstamp if they really need. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> Tested-by: Kurt Kanzenbach <kurt@linutronix.de> Acked-by: Richard Cochran <richardcochran@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h')
-rw-r--r--drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h b/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h
index 728cd5dc650f..71af77efb28b 100644
--- a/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h
+++ b/drivers/net/dsa/hirschmann/hellcreek_hwtstamp.h
@@ -44,8 +44,8 @@ int hellcreek_port_hwtstamp_get(struct dsa_switch *ds, int port,
bool hellcreek_port_rxtstamp(struct dsa_switch *ds, int port,
struct sk_buff *clone, unsigned int type);
-bool hellcreek_port_txtstamp(struct dsa_switch *ds, int port,
- struct sk_buff *clone);
+void hellcreek_port_txtstamp(struct dsa_switch *ds, int port,
+ struct sk_buff *skb);
int hellcreek_get_ts_info(struct dsa_switch *ds, int port,
struct ethtool_ts_info *info);