From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id EAA551F463 for ; Tue, 7 Jan 2020 15:26:37 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-type; q=dns; s=default; b=qjrP HD3pAE+003UE8H0VDyM08ZCrHHG49/xgLX4JuKkuhYy+Hj7T7W7l28blLXLDufvk wjqYEIsTe5zSHSv76EikVUmXsiq8cfwxwIxtfi3SZuHIFgzlbyeMgMoeI0DL0KuU HXj2gmigdJrnskJhKkZqXeMf8QwUs/6dUzc38wM= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-type; s=default; bh=pPG4U316kH l9NQNCDvFmF/YjUwE=; b=yy4bsUxdFF+asaziwdkvwPjsEZm4MZvqykheQ/UB/L m49gJUcnWT20VGnhnLroTMpInCa1MKaDRvsEmmyI7hpvB4mreluLNBqoQemj3W1H +YGOtQ++g4fshXqDwGnHLNzdOtISE5GwMmEOZWT2Naxfq3h5TBY52iwNXSNZbvWy w= Received: (qmail 18290 invoked by alias); 7 Jan 2020 15:26:35 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 18278 invoked by uid 89); 7 Jan 2020 15:26:35 -0000 Authentication-Results: sourceware.org; auth=none X-HELO: mout.kundenserver.de MIME-Version: 1.0 References: <20200106121742.1628-1-lukma@denx.de> <20200107102752.396f7f6f@jawa> <20200107152521.7416d5f3@jawa> In-Reply-To: <20200107152521.7416d5f3@jawa> From: Arnd Bergmann Date: Tue, 7 Jan 2020 16:26:14 +0100 Message-ID: Subject: Re: [PATCH v4 1/2] y2038: linux: Provide __timerfd_gettime64 implementation To: Lukasz Majewski Cc: Adhemerval Zanella , Joseph Myers , Paul Eggert , Andreas Schwab , Alistair Francis , Alistair Francis , GNU C Library , Siddhesh Poyarekar , Florian Weimer , Florian Weimer , Zack Weinberg , "Carlos O'Donell" Content-Type: text/plain; charset="UTF-8" On Tue, Jan 7, 2020 at 3:25 PM Lukasz Majewski wrote: > > On 07/01/2020 06:27, Lukasz Majewski wrote: > > > > >> As a side note, now that arch-syscall patch is upstream should we > > >> assume that for !__ASSUME_TIME64_SYSCALLS the > > >> __NR_timerfd_gettime64 should be defined (meaning that Linux > > >> supports time64 for all 32-bit architectures)? > > > > > > Only Linux version >= 5.1 supports 64 bit time on archs with > > > __WORDSIZE = 32. I do guess (but I may be wrong here) that the > > > arch-syscall is supposed to reflect the exact syscalls provided by > > > kernel headers used for building (to help with validation of Y2038 > > > patches). > > > > The arch-syscall is now autogenerated from the latest kernel release > > defined in build-many-glibcs.py. So the question is whether Linux > > support and enforces time64 support on all and future 32-bit > > architectures or if there is still some missing ones (as it has > > happen on some syscall additions, where some architecture lag > > behind some releases). > > This question would be best answered by Arnd (CC'ed) IMHO. From what I > know all 32 bit architectures gained syscalls covered by > __ASSUME_TIME64_SYSCALLS from Linux 5.1+. Yes, we intentionally converted all architectures at the same time to have a reliable baseline, i.e. once a future glibc requires linux-5.1 as the minimum kernel all the backwards-compatibility support for old kernels can be dropped. New 32-bit architectures (if any) will only support the time64 syscalls and not time time32 ones. For some ioctl interfaces, you also need to use the latest kernel headers, e.g. sound/asound.h from kernels before 5.6 has some bugs with time64. For the ioctl implementation I hope to wrap up the final bits in linux-5.6 as well, earlier kernels may return -EINVAL on some of the ioctls that pass a time_t. Arnd