From patchwork Thu Dec 20 23:09:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 10739671 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id BBE8B13BF for ; Thu, 20 Dec 2018 23:10:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A92A827F93 for ; Thu, 20 Dec 2018 23:10:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9719B27FA8; Thu, 20 Dec 2018 23:10:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2ACFA27F7F for ; Thu, 20 Dec 2018 23:10:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732528AbeLTXKD (ORCPT ); Thu, 20 Dec 2018 18:10:03 -0500 Received: from mail-qt1-f194.google.com ([209.85.160.194]:36168 "EHLO mail-qt1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732028AbeLTXKC (ORCPT ); Thu, 20 Dec 2018 18:10:02 -0500 Received: by mail-qt1-f194.google.com with SMTP id t13so3774794qtn.3; Thu, 20 Dec 2018 15:10:00 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=nezuhEoUN3eO/o0iL1OzyaVZs5mUFWx4ax27J6rh46E=; b=C7vatCKGGt0FL8vfSpVZHZtnNqAc/3pGg9oznC9cCkMwsZVDernqLPgnwxrr+nQBDW 6b5i1Mjw76z2wls1zQppKx9KivuB/6uExV32bwZEKCPFa2XS/eCYICJ1vXoM1Tl6YnHI 2vwyyoMG6HSgEok8UliKrviSW11dCLi6gX48C2GaEaURjQJDre9gFjXxTSy+p3giJdDT ahf17n39bldV2XMJdxie+SW6rojhwsKpMDh7A44SbKMuBuZJZnUacQXwsyhb5VUvV+hn eYImfmQiOzE+k6u4K2MOVq/05//aqTPIXiuO+7b46zFzh4Zz+MzW/Xhmm4YfV8UbxhKb A+ZQ== X-Gm-Message-State: AJcUuke30Scpe6bLbn1LTn7AULEM4T7MEfbn0ikWHNNV0Bs97lFAP3+W uyjTFe+gIcYlzDvpW3FMlxrQfL689ylILqsG99w= X-Google-Smtp-Source: ALg8bN79peTq2WlRDzsWWqdAzOTst4X6HUSdsFFFoHcP5reAn1EtSMSNaryvtKtzDa2iwk65m2a3U37ANBwAigzchec= X-Received: by 2002:a0c:f50c:: with SMTP id j12mr142253qvm.149.1545347400191; Thu, 20 Dec 2018 15:10:00 -0800 (PST) MIME-Version: 1.0 From: Arnd Bergmann Date: Fri, 21 Dec 2018 00:09:43 +0100 Message-ID: Subject: [GIT PULL] y2038: more syscalls and cleanups To: Linus Torvalds , Thomas Gleixner , y2038 Mailman List , Deepa Dinamani , Linux FS-devel Mailing List , Linux API , Linux Kernel Mailing List , Linux-sh list Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi Linus and Thomas, I realized that the merge window is now imminent, but I had not sent a pull request to Thomas for the current y2038 stuff. These patches have been around for a while though, and were in linux-next through my tree. I got one bug report on Monday and incorporated a simple fix, which changed the commit date for the second half of the series, in case you are wondering. Thomas, is it ok for you to just provide an Ack for this branch and have Linus merge it directly? Arnd The following changes since commit 651022382c7f8da46cb4872a545ee1da6d097d2a: Linux 4.20-rc1 (2018-11-04 15:37:52 -0800) are available in the Git repository at: https://git.kernel.org:/pub/scm/linux/kernel/git/arnd/playground.git tags/y2038-for-4.21 for you to fetch changes up to e4b92b108c6cd6b311e4b6e85d6a87a34599a6e3: timekeeping: remove obsolete time accessors (2018-12-18 16:13:05 +0100) ---------------------------------------------------------------- y2038: more syscalls and cleanups This concludes the main part of the system call rework for 64-bit time_t, which has spread over most of year 2018, the last six system calls being - ppoll - pselect6 - io_pgetevents - recvmmsg - futex - rt_sigtimedwait As before, nothing changes for 64-bit architectures, while 32-bit architectures gain another entry point that differs only in the layout of the timespec structure. Hopefully in the next release we can wire up all 22 of those system calls on all 32-bit architectures, which gives us a baseline version for glibc to start using them. This does not include the clock_adjtime, getrusage/waitid, and getitimer/setitimer system calls. I still plan to have new versions of those as well, but they are not required for correct operation of the C library since they can be emulated using the old 32-bit time_t based system calls. Aside from the system calls, there are also a few cleanups here, removing old kernel internal interfaces that have become unused after all references got removed. The arch/sh cleanups are part of this, there were posted several times over the past year without a reaction from the maintainers, while the corresponding changes made it into all other architectures. ---------------------------------------------------------------- Arnd Bergmann (13): y2038: futex: Move compat implementation into futex.c y2038: futex: Add support for __kernel_timespec y2038: socket: Add compat_sys_recvmmsg_time64 y2038: signal: Add sys_rt_sigtimedwait_time32 y2038: signal: Add compat_sys_rt_sigtimedwait_time64 sh: dreamcast: rtc: push down rtc class ops into driver sh: sh03: rtc: push down rtc class ops into driver sh: remove unused rtc_sh_get/set_time infrastructure sh: remove board_time_init() callback timekeeping: remove unused {read,update}_persistent_clock timekeeping: remove timespec_add/timespec_del vfs: replace current_kernel_time64 with ktime equivalent timekeeping: remove obsolete time accessors Deepa Dinamani (5): signal: Add set_user_sigmask() signal: Add restore_user_sigmask() ppoll: use __kernel_timespec pselect6: use __kernel_timespec io_pgetevents: use __kernel_timespec Documentation/sh/new-machine.txt | 8 -- arch/sh/boards/mach-dreamcast/Makefile | 4 +- arch/sh/boards/mach-dreamcast/rtc.c | 45 +++++++--- arch/sh/boards/mach-dreamcast/setup.c | 1 - arch/sh/boards/mach-sh03/Makefile | 3 +- arch/sh/boards/mach-sh03/rtc.c | 51 ++++++----- arch/sh/boards/mach-sh03/setup.c | 9 -- arch/sh/boards/of-generic.c | 8 -- arch/sh/configs/dreamcast_defconfig | 2 + arch/sh/configs/sh03_defconfig | 2 + arch/sh/include/asm/rtc.h | 3 - arch/sh/include/mach-dreamcast/mach/sysasic.h | 1 - arch/sh/kernel/time.c | 74 +--------------- fs/aio.c | 134 ++++++++++++++++++++--------- fs/eventpoll.c | 52 ++---------- fs/inode.c | 4 +- fs/select.c | 360 +++++++++++++++++++++++++++++++++++++++++++++--------------------------------- include/linux/compat.h | 26 ++++++ include/linux/futex.h | 8 -- include/linux/signal.h | 4 + include/linux/socket.h | 9 +- include/linux/syscalls.h | 29 +++++-- include/linux/time32.h | 25 ------ include/linux/timekeeping.h | 14 --- include/linux/timekeeping32.h | 15 ---- kernel/Makefile | 3 - kernel/futex.c | 207 +++++++++++++++++++++++++++++++++++++++++++-- kernel/futex_compat.c | 202 -------------------------------------------- kernel/signal.c | 143 +++++++++++++++++++++++++++++++ kernel/sys_ni.c | 2 + kernel/time/ntp.c | 10 +-- kernel/time/time.c | 36 -------- kernel/time/timekeeping.c | 12 +-- net/compat.c | 34 +++----- net/socket.c | 62 ++++++++++---- 35 files changed, 847 insertions(+), 755 deletions(-) delete mode 100644 kernel/futex_compat.c