From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 7ADF73858D32 for ; Mon, 24 Jul 2023 12:55:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7ADF73858D32 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1690203306; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=3RFDVt75nVBQ3qmFZF8KTzffYN6Dwyng/QO4scdTBVc=; b=efppzUx5hVODFE8c/cu1adloA7+Hia1fK3NipLCkhE/J8ftYVWZ3/+/mnNvhtrfxeF83d6 Vqj5OWnYJ5LO+r7JzAU7CEegGpk+dsJX5MknbVL95HdPo4wSSnZ7FNpg8cxjZWGh3gGsQf Ynh6yvq54zNxkcUXvkj8rNHbwDb0BEo= Received: from mail-yw1-f198.google.com (mail-yw1-f198.google.com [209.85.128.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-442-Z_e_IQ90ODGZMGFUlam2mg-1; Mon, 24 Jul 2023 08:55:05 -0400 X-MC-Unique: Z_e_IQ90ODGZMGFUlam2mg-1 Received: by mail-yw1-f198.google.com with SMTP id 00721157ae682-5704e551e8bso54572407b3.3 for ; Mon, 24 Jul 2023 05:55:05 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690203305; x=1690808105; h=content-transfer-encoding:in-reply-to:organization:from:references :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=3RFDVt75nVBQ3qmFZF8KTzffYN6Dwyng/QO4scdTBVc=; b=gCZt3nSHhy8mOEifXCCw8IIcIHdQ1lHcHSQsm+APLwzq7u0jrgmzmb81ITid0lcMtM B/D7cvvge15RJOJxvOQf9qqceqY//fIosY3OBtG5prZuy0xRx0U9MMe/xjuwKdzn3x2G MLAooduIdUnrEWfRCq/Ef/pVJLurKnkLPYyo6Xpj83ZSHDhposqMwURjiNIvvkrlB1FV V8DpbdZgX/2fZ11P61bvFpCJwQeqomlxggv+pXUnzEheHstbuH7l5GIu+Qgo9kvVLRyX M4kpWUiZuOBeQToAOBjaymhZWjJ7CKNawCB9tIuYkWlcLK74pI9WWWXkxr5K7nm+tTcJ 45Cg== X-Gm-Message-State: ABy/qLZ7g+InQe4irEyK1QJFP8LVZ3JII2zTNW7wqPK1o0rIm7S0y90v x31Rc5c2wxgPAdGZDc1JBkc5JzgOumUx6Ps5aC52vNCy9q1TJKmt3qzyMMIY4nWKlEq9BRy853S RX9m5p2/FuyTzl0xoYO+O2tmIr9xo X-Received: by 2002:a81:a087:0:b0:576:f0d6:3d68 with SMTP id x129-20020a81a087000000b00576f0d63d68mr8640897ywg.32.1690203304916; Mon, 24 Jul 2023 05:55:04 -0700 (PDT) X-Google-Smtp-Source: APBJJlE7/bK1kUDxhaQBPj6noUQZxsJQBsUdm+R/eKvOWDwQgbEKEI0wB1adGl3lxUJDCLz/jvkw7Q== X-Received: by 2002:a81:a087:0:b0:576:f0d6:3d68 with SMTP id x129-20020a81a087000000b00576f0d63d68mr8640885ywg.32.1690203304548; Mon, 24 Jul 2023 05:55:04 -0700 (PDT) Received: from [192.168.0.241] ([198.48.244.52]) by smtp.gmail.com with ESMTPSA id h2-20020a0dc502000000b005731dbd4928sm2707337ywd.69.2023.07.24.05.55.03 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 24 Jul 2023 05:55:04 -0700 (PDT) Message-ID: <769eb9fa-5e69-bbd2-2055-10d494f76b8e@redhat.com> Date: Mon, 24 Jul 2023 08:55:03 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: CONFIG_COMPAT_32BIT_TIME in the kernel, x86 ABI on x86-64 To: Adhemerval Zanella Netto , "Andreas K. Huettel" , libc-alpha@sourceware.org, floppym@gentoo.org References: <8005565.6fTUFtlzNn@pinacolada> <1e8a84bf-4b7f-67bc-ba8d-6a434afb2b8c@linaro.org> From: Carlos O'Donell Organization: Red Hat In-Reply-To: <1e8a84bf-4b7f-67bc-ba8d-6a434afb2b8c@linaro.org> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,KAM_NUMSUBJECT,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 7/23/23 14:46, Adhemerval Zanella Netto via Libc-alpha wrote: > > > On 23/07/23 12:16, Andreas K. Huettel wrote: >> Dear all, >> >> one of my Gentoo colleagues (Mike Gilbert, floppym) found this, so I'm forwarding >> his notes: >> >> === >> Using utimensat as an example, the kernel interface is as follows: >> >> When CONFIG_COMPAT_32BIT_TIME is enabled, the kernel provides both the legact >> 32-bit interface (utimensat) and the 64-bit interface (utimensat_time64). >> When CONFIG_COMPAT_32BIT_TIME is disabled, only the 64-bit interface >> (utimensat_time64) is provided. utimensat gives ENOSYS. >> >> Behavior of utimensat64 libc function before b286eca5d4117b3e17c939e3df56e132ae623df1: >> >> 1. Try utimensat_time64 >> 2. If ENOSYS, fall back to utimensat if the arguments are small enough to fit in 32-bits >> >> Behavior of utimensat64 libc function after b286eca5d4117b3e17c939e3df56e132ae623df1: >> >> 1. If the arguments are small enough to fit in 32-bits, use utimensat >> 2. If the arguments are too large, use utimensat_time64 >> >> The new behavior fails when CONFIG_COMPAT_32BIT_TIME is disabled, since utimensat is >> unavailable. >> >> Several other glibc functions were updated with similar behavior changes. >> === >> >> What's to do? > > It has been already discussed [1], and not only glibc but musl creator Rich > agreed [2] that this option is a gratuitous userspace API/ABI stability policy > breakage that Linux (at least Linus and some other maintainers) is adamant to > not introduce. > > At least for glibc we have the option to configure with a minimum 5.1 kernel > (--enable-kernel=5.1) which should disable the 32 bit syscall fallback. This > should work with CONFIG_COMPAT_32BIT_TIME, although I have not actually > test it. > > [1] https://sourceware.org/pipermail/libc-alpha/2022-November/143330.html > [2] https://sourceware.org/pipermail/libc-alpha/2022-November/143349.html > Adhemerval, Could you please review this release note? https://sourceware.org/glibc/wiki/Release/2.38#Linux_kernel_config_option_CONFIG_COMPAT_32BIT_TIME_and_userspace_ABI I want to have something that we can point distributions to as the official answer. -- Cheers, Carlos.