]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
net: ping6: support packet timestamping
authorJakub Kicinski <kuba@kernel.org>
Thu, 10 Feb 2022 00:36:40 +0000 (16:36 -0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 10 Feb 2022 15:04:51 +0000 (15:04 +0000)
Nothing prevents the user from requesting timestamping
on ping6 sockets, yet timestamps are not going to be reported.
Plumb the flags through.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/ping.c

index 86a72f7a61cf3596c9b6732056cae948e7177dae..3228ccd8abf1c1fc52c2b2861d97dacdcaf54590 100644 (file)
@@ -113,6 +113,7 @@ static int ping_v6_sendmsg(struct sock *sk, struct msghdr *msg, size_t len)
 
        ipcm6_init_sk(&ipc6, np);
        ipc6.sockc.mark = sk->sk_mark;
+       ipc6.sockc.tsflags = sk->sk_tsflags;
        fl6.flowlabel = ip6_make_flowinfo(ipc6.tclass, fl6.flowlabel);
 
        dst = ip6_sk_dst_lookup_flow(sk, &fl6, daddr, false);