From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 98403 invoked by alias); 20 Jan 2020 18:26:27 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 98387 invoked by uid 89); 20 Jan 2020 18:26:26 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-24.7 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy= X-HELO: mail-qv1-f65.google.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=to:cc:references:from:autocrypt:subject:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=0352c89K2U6MWcg0ssFO2wQDhW4avZC6qpHAqKT2Cto=; b=RZh3FqGAxsWRsWr7nqKCLz9rBjMiGWuh5pCiXfI/KvbqVXt3n7sNjx+WeH1aI/628r d62cHFyw7hj4raHnjnr+EmDSbyon6roKKZSHauq1kjSER8BORhN2MtDxcujxVmAMo1Xf FLK8wApX4WQE02DoHC86qL/vH152qUh620DWNr8KmWrUwmpqS480zTpy8eZfctdW6cK/ WCZ49CFi2gHYKHL0y6QExXh+c9euYwEP4wySq09ouaMRbNjsWnXihtWPsfMlnBPlz1Z+ EXDWfDBFbVYFsRtOphCC0KL8OLFX9bl4UZMlpEPJe0Loe8AAS5ua/HHBsOnVVOeXwnh9 CVrg== Return-Path: To: Lukasz Majewski Cc: Joseph Myers , Paul Eggert , Samuel Thibault , Alistair Francis , Alistair Francis , GNU C Library , Siddhesh Poyarekar , Florian Weimer , Florian Weimer , Zack Weinberg , Carlos O'Donell , Andreas Schwab References: <20200118072047.23071-1-lukma@denx.de> <20200118072047.23071-3-lukma@denx.de> <20200120190807.14ecc25e@jawa> From: Adhemerval Zanella Subject: Re: [PATCH 2/6] y2038: hurd: Provide __clock_settime64 function Message-ID: Date: Mon, 20 Jan 2020 18:29:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <20200120190807.14ecc25e@jawa> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit X-SW-Source: 2020-01/txt/msg00459.txt.bz2 On 20/01/2020 15:08, Lukasz Majewski wrote: > Hi Adhemerval, > >> On 18/01/2020 04:20, Lukasz Majewski wrote: >>> For Linux glibc ports the __TIMESIZE == 64 ensures proper aliasing >>> for __clock_settime64 (to __clock_settime). >>> When __TIMESIZE != 64 (like ARM32, PPC) the glibc expects separate >>> definition of the __clock_settime64. >>> >>> The HURD port only provides __clock_settime, so this patch adds >>> __clock_settime64 as a tiny wrapper on it. >>> --- >>> sysdeps/mach/hurd/clock_settime.c | 9 +++++++++ >>> 1 file changed, 9 insertions(+) >>> >>> diff --git a/sysdeps/mach/hurd/clock_settime.c >>> b/sysdeps/mach/hurd/clock_settime.c index 2c77bad71a..db1ba860dc >>> 100644 --- a/sysdeps/mach/hurd/clock_settime.c >>> +++ b/sysdeps/mach/hurd/clock_settime.c >>> @@ -53,3 +53,12 @@ versioned_symbol (libc, __clock_settime, >>> clock_settime, GLIBC_2_17); strong_alias (__clock_settime, >>> __clock_settime_2); compat_symbol (libc, __clock_settime_2, >>> clock_settime, GLIBC_2_2); #endif >>> + >>> +int >>> +__clock_settime64 (clockid_t clock_id, const struct __timespec64 >>> *ts64) +{ >>> + struct timespec ts = valid_timespec64_to_timespec (*ts64); >>> + >>> + return __clock_settime (clock_id, &ts); >>> +} >>> +libc_hidden_def (__clock_settime64) >>> >> >> As for https://sourceware.org/ml/libc-alpha/2020-01/msg00445.html I >> don't think this patch is really required now. > > I think that it is required to allow using __clock_settime64() calls > internally in glibc. Ok, I missed the patch where you adjusted the generic settimeofday. In any case, I would like to avoid mess with generic implementation for time64 since I am not sure how/when Hurd will try to fix it and currently all time64 fixes are compartmentalized on Linux sysdep folder. I think it might be add Linux specific version of settimeofday to handle the time64 support.