packet: support for TX time stamps on RAW sockets

Enable the SO_TIMESTAMPING socket infrastructure for raw packet sockets.
We introduce PACKET_TX_TIMESTAMP for the control message cmsg_type.

Similar support for UDP and CAN sockets was added in commit
51f31cabe3

Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Richard Cochran 2010-04-07 22:41:28 +00:00 committed by David S. Miller
parent 7d53b80980
commit ed85b565b8
2 changed files with 61 additions and 1 deletions

View file

@ -47,6 +47,7 @@ struct sockaddr_ll {
#define PACKET_TX_RING 13
#define PACKET_LOSS 14
#define PACKET_VNET_HDR 15
#define PACKET_TX_TIMESTAMP 16
struct tpacket_stats {
unsigned int tp_packets;