From: Deepa Dinamani <deepa.kernel@gmail.com> To: davem@davemloft.net, linux-kernel@vger.kernel.org Cc: netdev@vger.kernel.org, viro@zeniv.linux.org.uk, arnd@arndb.de, y2038@lists.linaro.org, chris@zankel.net, fenghua.yu@intel.com, tglx@linutronix.de, schwidefsky@de.ibm.com, linux-ia64@vger.kernel.org, linux-xtensa@linux-xtensa.org, linux-s390@vger.kernel.org, deller@gmx.de, dhowells@redhat.com, jejb@parisc-linux.org, ralf@linux-mips.org, rth@twiddle.net, linux-afs@lists.infradead.org, linux-alpha@vger.kernel.org, linux-arch@vger.kernel.org, linux-mips@linux-mips.org, linux-parisc@vger.kernel.org, linux-rdma@vger.kernel.org, sparclinux@vger.kernel.org, isdn@linux-pingi.de, ubraun@linux.ibm.com Subject: [PATCH 0/8] net: y2038-safe socket timestamps Date: Fri, 23 Nov 2018 18:20:27 -0800 [thread overview] Message-ID: <20181124022035.17519-1-deepa.kernel@gmail.com> (raw) The series introduces new socket timestamps that are y2038 safe. The time data types used for the existing socket timestamp options: SO_TIMESTAMP, SO_TIMESTAMPNS and SO_TIMESTAMPING are not y2038 safe. The series introduces SO_TIMESTAMP_NEW, SO_TIMESTAMPNS_NEW and SO_TIMESTAMPING_NEW to replace these. These new timestamps can be used on all architectures. The alternative considered was to extend the sys_setsockopt() by using the flags. We did not receive any strong opinions about either of the approaches. Hence, this was chosen, as glibc folks preferred this. The series does not deal with updating the internal kernel socket calls like rxrpc to make them y2038 safe. This will be dealt with separately. Note that the timestamps behavior already does not match the man page specific behavior: SIOCGSTAMP This ioctl should only be used if the socket option SO_TIMESTAMP is not set on the socket. Otherwise, it returns the timestamp of the last packet that was received while SO_TIMESTAMP was not set, or it fails if no such packet has been received, (i.e., ioctl(2) returns -1 with errno set to ENOENT). The recommendation is to update the man page to remove the above statement. The overview of the series is as below: 1. Delete asm specific socket.h when possible. 2. Support SO/SCM_TIMESTAMP* options only in userspace. 3. Rename current SO/SCM_TIMESTAMP* to SO/SCM_TIMESTAMP*_OLD. 3. Alter socket options so that SOCK_RCVTSTAMPNS does not rely on SOCK_RCVTSTAMP. 4. Introduce y2038 safe types for socket timestamp. 5. Introduce new y2038 safe socket options SO/SCM_TIMESTAMP*_NEW. Deepa Dinamani (8): arch: Use asm-generic/socket.h when possible sockopt: Rename SO_TIMESTAMP* to SO_TIMESTAMP*_OLD socket: Disentangle SOCK_RCVTSTAMPNS from SOCK_RCVTSTAMP arch: sparc: Override struct __kernel_old_timeval socket: Use old_timeval types for socket timestamps socket: Add struct sock_timeval socket: Add SO_TIMESTAMP[NS]_NEW socket: Add SO_TIMESTAMPING_NEW arch/alpha/include/uapi/asm/socket.h | 35 ++++-- arch/ia64/include/uapi/asm/Kbuild | 1 + arch/ia64/include/uapi/asm/socket.h | 120 ------------------ arch/mips/include/uapi/asm/socket.h | 34 ++++-- arch/parisc/include/uapi/asm/socket.h | 34 ++++-- arch/s390/include/uapi/asm/Kbuild | 1 + arch/s390/include/uapi/asm/socket.h | 117 ------------------ arch/sparc/include/uapi/asm/posix_types.h | 10 ++ arch/sparc/include/uapi/asm/socket.h | 36 ++++-- arch/x86/include/uapi/asm/Kbuild | 1 + arch/x86/include/uapi/asm/socket.h | 1 - arch/xtensa/include/asm/Kbuild | 1 + arch/xtensa/include/uapi/asm/Kbuild | 1 + arch/xtensa/include/uapi/asm/socket.h | 122 ------------------- drivers/isdn/mISDN/socket.c | 2 +- include/linux/skbuff.h | 24 +++- include/linux/socket.h | 7 ++ include/net/sock.h | 5 +- include/uapi/asm-generic/socket.h | 35 ++++-- include/uapi/linux/errqueue.h | 4 + include/uapi/linux/time.h | 7 ++ net/bluetooth/hci_sock.c | 4 +- net/compat.c | 12 +- net/core/scm.c | 27 ++++ net/core/sock.c | 142 ++++++++++++++-------- net/ipv4/tcp.c | 82 ++++++++----- net/rds/af_rds.c | 10 +- net/rds/recv.c | 18 ++- net/rxrpc/local_object.c | 2 +- net/smc/af_smc.c | 3 +- net/socket.c | 68 +++++++---- net/unix/af_unix.c | 4 +- 32 files changed, 449 insertions(+), 521 deletions(-) delete mode 100644 arch/ia64/include/uapi/asm/socket.h delete mode 100644 arch/s390/include/uapi/asm/socket.h delete mode 100644 arch/x86/include/uapi/asm/socket.h delete mode 100644 arch/xtensa/include/uapi/asm/socket.h base-commit: b124b524bc97868cc2b5656e6ffa21a9b752b7e0 -- 2.17.1 Cc: chris@zankel.net Cc: fenghua.yu@intel.com Cc: tglx@linutronix.de Cc: schwidefsky@de.ibm.com Cc: linux-ia64@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: linux-s390@vger.kernel.org Cc: deller@gmx.de Cc: dhowells@redhat.com Cc: jejb@parisc-linux.org Cc: ralf@linux-mips.org Cc: rth@twiddle.net Cc: linux-afs@lists.infradead.org Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-parisc@vger.kernel.org Cc: linux-rdma@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: isdn@linux-pingi.de Cc: jejb@parisc-linux.org Cc: ralf@linux-mips.org Cc: rth@twiddle.net Cc: linux-alpha@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-parisc@vger.kernel.org Cc: linux-rdma@vger.kernel.org Cc: netdev@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: chris@zankel.net Cc: fenghua.yu@intel.com Cc: rth@twiddle.net Cc: tglx@linutronix.de Cc: ubraun@linux.ibm.com Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-s390@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org
WARNING: multiple messages have this Message-ID (diff)
From: Deepa Dinamani <deepa.kernel@gmail.com> To: davem@davemloft.net, linux-kernel@vger.kernel.org Cc: netdev@vger.kernel.org, viro@zeniv.linux.org.uk, arnd@arndb.de, y2038@lists.linaro.org, chris@zankel.net, fenghua.yu@intel.com, tglx@linutronix.de, schwidefsky@de.ibm.com, linux-ia64@vger.kernel.org, linux-xtensa@linux-xtensa.org, linux-s390@vger.kernel.org, deller@gmx.de, dhowells@redhat.com, jejb@parisc-linux.org, ralf@linux-mips.org, rth@twiddle.net, linux-afs@lists.infradead.org, linux-alpha@vger.kernel.org, linux-arch@vger.kernel.org, linux-mips@linux-mips.org, linux-parisc@vger.kernel.org, linux-rdma@vger.kernel.org, sparclinux@vger.kernel.org, isdn@linux-pingi.de, ubraun@linux.ibm.com Subject: [PATCH 0/8] net: y2038-safe socket timestamps Date: Sat, 24 Nov 2018 02:20:27 +0000 [thread overview] Message-ID: <20181124022035.17519-1-deepa.kernel@gmail.com> (raw) The series introduces new socket timestamps that are y2038 safe. The time data types used for the existing socket timestamp options: SO_TIMESTAMP, SO_TIMESTAMPNS and SO_TIMESTAMPING are not y2038 safe. The series introduces SO_TIMESTAMP_NEW, SO_TIMESTAMPNS_NEW and SO_TIMESTAMPING_NEW to replace these. These new timestamps can be used on all architectures. The alternative considered was to extend the sys_setsockopt() by using the flags. We did not receive any strong opinions about either of the approaches. Hence, this was chosen, as glibc folks preferred this. The series does not deal with updating the internal kernel socket calls like rxrpc to make them y2038 safe. This will be dealt with separately. Note that the timestamps behavior already does not match the man page specific behavior: SIOCGSTAMP This ioctl should only be used if the socket option SO_TIMESTAMP is not set on the socket. Otherwise, it returns the timestamp of the last packet that was received while SO_TIMESTAMP was not set, or it fails if no such packet has been received, (i.e., ioctl(2) returns -1 with errno set to ENOENT). The recommendation is to update the man page to remove the above statement. The overview of the series is as below: 1. Delete asm specific socket.h when possible. 2. Support SO/SCM_TIMESTAMP* options only in userspace. 3. Rename current SO/SCM_TIMESTAMP* to SO/SCM_TIMESTAMP*_OLD. 3. Alter socket options so that SOCK_RCVTSTAMPNS does not rely on SOCK_RCVTSTAMP. 4. Introduce y2038 safe types for socket timestamp. 5. Introduce new y2038 safe socket options SO/SCM_TIMESTAMP*_NEW. Deepa Dinamani (8): arch: Use asm-generic/socket.h when possible sockopt: Rename SO_TIMESTAMP* to SO_TIMESTAMP*_OLD socket: Disentangle SOCK_RCVTSTAMPNS from SOCK_RCVTSTAMP arch: sparc: Override struct __kernel_old_timeval socket: Use old_timeval types for socket timestamps socket: Add struct sock_timeval socket: Add SO_TIMESTAMP[NS]_NEW socket: Add SO_TIMESTAMPING_NEW arch/alpha/include/uapi/asm/socket.h | 35 ++++-- arch/ia64/include/uapi/asm/Kbuild | 1 + arch/ia64/include/uapi/asm/socket.h | 120 ------------------ arch/mips/include/uapi/asm/socket.h | 34 ++++-- arch/parisc/include/uapi/asm/socket.h | 34 ++++-- arch/s390/include/uapi/asm/Kbuild | 1 + arch/s390/include/uapi/asm/socket.h | 117 ------------------ arch/sparc/include/uapi/asm/posix_types.h | 10 ++ arch/sparc/include/uapi/asm/socket.h | 36 ++++-- arch/x86/include/uapi/asm/Kbuild | 1 + arch/x86/include/uapi/asm/socket.h | 1 - arch/xtensa/include/asm/Kbuild | 1 + arch/xtensa/include/uapi/asm/Kbuild | 1 + arch/xtensa/include/uapi/asm/socket.h | 122 ------------------- drivers/isdn/mISDN/socket.c | 2 +- include/linux/skbuff.h | 24 +++- include/linux/socket.h | 7 ++ include/net/sock.h | 5 +- include/uapi/asm-generic/socket.h | 35 ++++-- include/uapi/linux/errqueue.h | 4 + include/uapi/linux/time.h | 7 ++ net/bluetooth/hci_sock.c | 4 +- net/compat.c | 12 +- net/core/scm.c | 27 ++++ net/core/sock.c | 142 ++++++++++++++-------- net/ipv4/tcp.c | 82 ++++++++----- net/rds/af_rds.c | 10 +- net/rds/recv.c | 18 ++- net/rxrpc/local_object.c | 2 +- net/smc/af_smc.c | 3 +- net/socket.c | 68 +++++++---- net/unix/af_unix.c | 4 +- 32 files changed, 449 insertions(+), 521 deletions(-) delete mode 100644 arch/ia64/include/uapi/asm/socket.h delete mode 100644 arch/s390/include/uapi/asm/socket.h delete mode 100644 arch/x86/include/uapi/asm/socket.h delete mode 100644 arch/xtensa/include/uapi/asm/socket.h base-commit: b124b524bc97868cc2b5656e6ffa21a9b752b7e0 -- 2.17.1 Cc: chris@zankel.net Cc: fenghua.yu@intel.com Cc: tglx@linutronix.de Cc: schwidefsky@de.ibm.com Cc: linux-ia64@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: linux-s390@vger.kernel.org Cc: deller@gmx.de Cc: dhowells@redhat.com Cc: jejb@parisc-linux.org Cc: ralf@linux-mips.org Cc: rth@twiddle.net Cc: linux-afs@lists.infradead.org Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-parisc@vger.kernel.org Cc: linux-rdma@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: isdn@linux-pingi.de Cc: jejb@parisc-linux.org Cc: ralf@linux-mips.org Cc: rth@twiddle.net Cc: linux-alpha@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-parisc@vger.kernel.org Cc: linux-rdma@vger.kernel.org Cc: netdev@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: chris@zankel.net Cc: fenghua.yu@intel.com Cc: rth@twiddle.net Cc: tglx@linutronix.de Cc: ubraun@linux.ibm.com Cc: linux-alpha@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-mips@linux-mips.org Cc: linux-s390@vger.kernel.org Cc: linux-xtensa@linux-xtensa.org Cc: sparclinux@vger.kernel.org
next reply other threads:[~2018-11-24 2:20 UTC|newest] Thread overview: 63+ messages / expand[flat|nested] mbox.gz Atom feed top 2018-11-24 2:20 Deepa Dinamani [this message] 2018-11-24 2:20 ` [PATCH 0/8] net: y2038-safe socket timestamps Deepa Dinamani 2018-11-24 2:20 ` [PATCH 1/8] arch: Use asm-generic/socket.h when possible Deepa Dinamani 2018-11-24 2:20 ` Deepa Dinamani 2018-11-24 2:20 ` [PATCH 2/8] sockopt: Rename SO_TIMESTAMP* to SO_TIMESTAMP*_OLD Deepa Dinamani 2018-11-24 2:20 ` Deepa Dinamani 2018-11-25 3:58 ` Willem de Bruijn 2018-11-25 3:58 ` Willem de Bruijn 2018-11-30 22:38 ` Deepa Dinamani 2018-11-30 22:38 ` Deepa Dinamani 2018-11-30 23:33 ` Willem de Bruijn 2018-11-30 23:33 ` Willem de Bruijn 2018-11-24 2:20 ` [PATCH 3/8] socket: Disentangle SOCK_RCVTSTAMPNS from SOCK_RCVTSTAMP Deepa Dinamani 2018-11-25 3:59 ` Willem de Bruijn 2018-11-25 5:06 ` Deepa Dinamani 2018-11-25 14:18 ` Willem de Bruijn 2018-11-25 18:19 ` David Miller 2018-11-30 22:16 ` Deepa Dinamani 2018-11-30 23:31 ` Willem de Bruijn 2018-11-24 2:20 ` [PATCH 4/8] arch: sparc: Override struct __kernel_old_timeval Deepa Dinamani 2018-11-24 2:20 ` Deepa Dinamani 2018-11-24 2:20 ` [PATCH 5/8] socket: Use old_timeval types for socket timestamps Deepa Dinamani 2018-11-24 2:20 ` [PATCH 6/8] socket: Add struct sock_timeval Deepa Dinamani 2018-11-24 19:37 ` Willem de Bruijn 2018-11-24 19:37 ` Willem de Bruijn 2018-11-25 2:09 ` David Miller 2018-11-25 4:52 ` Deepa Dinamani 2018-11-25 4:52 ` Deepa Dinamani 2018-11-25 20:50 ` Arnd Bergmann 2018-11-26 16:33 ` Deepa Dinamani 2018-11-24 2:20 ` [PATCH 7/8] socket: Add SO_TIMESTAMP[NS]_NEW Deepa Dinamani 2018-11-24 2:20 ` Deepa Dinamani 2018-11-25 3:59 ` Willem de Bruijn 2018-11-25 3:59 ` Willem de Bruijn 2018-11-25 4:17 ` Willem de Bruijn 2018-11-25 4:17 ` Willem de Bruijn 2018-11-25 4:17 ` Willem de Bruijn 2018-11-25 5:28 ` Deepa Dinamani 2018-11-25 5:28 ` Deepa Dinamani 2018-11-25 5:28 ` Deepa Dinamani 2018-11-25 5:55 ` Deepa Dinamani 2018-11-25 5:55 ` Deepa Dinamani 2018-11-25 5:55 ` Deepa Dinamani 2018-11-25 14:38 ` Willem de Bruijn 2018-11-25 14:38 ` Willem de Bruijn 2018-11-25 14:33 ` Willem de Bruijn 2018-11-25 14:33 ` Willem de Bruijn 2018-11-25 14:33 ` Willem de Bruijn 2018-11-25 22:35 ` Arnd Bergmann 2018-11-25 22:35 ` Arnd Bergmann 2018-11-26 0:25 ` Willem de Bruijn 2018-11-26 0:25 ` Willem de Bruijn 2018-11-30 22:43 ` Deepa Dinamani 2018-11-30 22:43 ` Deepa Dinamani 2018-11-30 23:37 ` Willem de Bruijn 2018-11-30 23:37 ` Willem de Bruijn 2018-11-30 23:37 ` Willem de Bruijn 2018-11-24 2:20 ` [PATCH 8/8] socket: Add SO_TIMESTAMPING_NEW Deepa Dinamani 2018-11-24 2:20 ` Deepa Dinamani 2018-11-25 4:00 ` Willem de Bruijn 2018-11-25 4:00 ` Willem de Bruijn 2018-11-25 5:07 ` Deepa Dinamani 2018-11-25 5:07 ` Deepa Dinamani
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20181124022035.17519-1-deepa.kernel@gmail.com \ --to=deepa.kernel@gmail.com \ --cc=arnd@arndb.de \ --cc=chris@zankel.net \ --cc=davem@davemloft.net \ --cc=deller@gmx.de \ --cc=dhowells@redhat.com \ --cc=fenghua.yu@intel.com \ --cc=isdn@linux-pingi.de \ --cc=jejb@parisc-linux.org \ --cc=linux-afs@lists.infradead.org \ --cc=linux-alpha@vger.kernel.org \ --cc=linux-arch@vger.kernel.org \ --cc=linux-ia64@vger.kernel.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-mips@linux-mips.org \ --cc=linux-parisc@vger.kernel.org \ --cc=linux-rdma@vger.kernel.org \ --cc=linux-s390@vger.kernel.org \ --cc=linux-xtensa@linux-xtensa.org \ --cc=netdev@vger.kernel.org \ --cc=ralf@linux-mips.org \ --cc=rth@twiddle.net \ --cc=schwidefsky@de.ibm.com \ --cc=sparclinux@vger.kernel.org \ --cc=tglx@linutronix.de \ --cc=ubraun@linux.ibm.com \ --cc=viro@zeniv.linux.org.uk \ --cc=y2038@lists.linaro.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.