Re: [PATCH v3 6/8] socket: Add SO_TIMESTAMP[NS]_NEW
Willem de Bruijn <[email protected]>
| Newsgroups | gmane.linux.kernel,gmane.linux.network,gmane.linux.kernel.year-2038,gmane.linux.ports.alpha,gmane.linux.ports.mips.general,gmane.linux.ports.parisc,gmane.linux.drivers.rdma,gmane.linux.ports.sparc |
|---|---|
| Message-ID | <CAF=yD-L_KbVEbMaY6-3uA4Sp7gDMPEcF7+74J4TzukXb33t55w@mail.gmail.com> |
On Mon, Jan 7, 2019 at 10:29 PM Deepa Dinamani <[email protected]> wrote: > > Add SO_TIMESTAMP_NEW and SO_TIMESTAMPNS_NEW variants of > socket timestamp options. > These are the y2038 safe versions of the SO_TIMESTAMP_OLD > and SO_TIMESTAMPNS_OLD for all architectures. > > Note that the format of scm_timestamping.ts[0] is not changed > in this patch. > > Signed-off-by: Deepa Dinamani <[email protected]> > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > Cc: [email protected] > @@ -1864,20 +1864,39 @@ static void tcp_update_recv_tstamps(struct sk_buff *skb, > static void tcp_recv_timestamp(struct msghdr *msg, const struct sock *sk, > struct scm_timestamping *tss) > { > - struct __kernel_old_timeval tv; > bool has_timestamping = false; > + int new_tstamp = sock_flag(sk, SOCK_TSTAMP_NEW); nit: move above has_timestamping to maintain reverse christmas tree ordering