net-timestamp: Make the clone operation stand-alone from phy timestamping
The phy timestamping takes a different path than the regular timestamping does in that it will create a clone first so that the packets needing to be timestamped can be placed in a queue, or the context block could be used. In order to support these use cases I am pulling the core of the code out so it can be used in other drivers beyond just phy devices. In addition I have added a destructor named sock_efree which is meant to provide a simple way for dropping the reference to skb exceptions that aren't part of either the receive or send windows for the socket, and I have removed some duplication in spots where this destructor could be used in place of sock_edemux. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
37846ef018
commit
62bccb8cdb
@@ -1574,6 +1574,7 @@ struct sk_buff *sock_wmalloc(struct sock *sk, unsigned long size, int force,
|
||||
void sock_wfree(struct sk_buff *skb);
|
||||
void skb_orphan_partial(struct sk_buff *skb);
|
||||
void sock_rfree(struct sk_buff *skb);
|
||||
void sock_efree(struct sk_buff *skb);
|
||||
void sock_edemux(struct sk_buff *skb);
|
||||
|
||||
int sock_setsockopt(struct socket *sock, int level, int op,
|
||||
|
Reference in New Issue
Block a user