[NETFILTER]: xt_time should not assume CONFIG_KTIME_SCALAR
It is not correct to assume one can get nsec from a ktime directly by using .tv64 field. Signed-off-by: Eric Dumazet <dada1@cosmosbay.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
022cbae611
commit
53756524e4
1 changed files with 1 additions and 1 deletions
|
@ -170,7 +170,7 @@ static bool xt_time_match(const struct sk_buff *skb,
|
|||
if (skb->tstamp.tv64 == 0)
|
||||
__net_timestamp((struct sk_buff *)skb);
|
||||
|
||||
stamp = skb->tstamp.tv64;
|
||||
stamp = ktime_to_ns(skb->tstamp);
|
||||
do_div(stamp, NSEC_PER_SEC);
|
||||
|
||||
if (info->flags & XT_TIME_LOCAL_TZ)
|
||||
|
|
Loading…
Reference in a new issue