diff options
-rw-r--r-- | net/packet/af_packet.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c index 1322d62b5d97..9c26dd9ee649 100644 --- a/net/packet/af_packet.c +++ b/net/packet/af_packet.c | |||
@@ -640,11 +640,10 @@ static int tpacket_rcv(struct sk_buff *skb, struct net_device *dev, struct packe | |||
640 | h->tp_snaplen = snaplen; | 640 | h->tp_snaplen = snaplen; |
641 | h->tp_mac = macoff; | 641 | h->tp_mac = macoff; |
642 | h->tp_net = netoff; | 642 | h->tp_net = netoff; |
643 | if (skb->tstamp.tv64 == 0) { | 643 | if (skb->tstamp.tv64) |
644 | __net_timestamp(skb); | 644 | tv = ktime_to_timeval(skb->tstamp); |
645 | sock_enable_timestamp(sk); | 645 | else |
646 | } | 646 | do_gettimeofday(&tv); |
647 | tv = ktime_to_timeval(skb->tstamp); | ||
648 | h->tp_sec = tv.tv_sec; | 647 | h->tp_sec = tv.tv_sec; |
649 | h->tp_usec = tv.tv_usec; | 648 | h->tp_usec = tv.tv_usec; |
650 | 649 | ||