From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa3.mentor.iphmx.com (esa3.mentor.iphmx.com [68.232.137.180]) by sourceware.org (Postfix) with ESMTPS id 57498385DC00 for ; Tue, 2 Jun 2020 18:05:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 57498385DC00 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=joseph_myers@mentor.com IronPort-SDR: QC7/Y+g2uFXjK24WxxzuWq7LterOLKuArbenCHaFQFH+s6X3k6z+6hYVmiAOSloAgTeC6v6E3K paGX/+Z4dKNxYoNsv6rK1djo8tGDiRS9m6Gt7wSHxloJMbPM/9bAunBV/+gk+dtWbvTQtxqAP4 gP2RiaYJTd9YlNh4k7DfmiFrm6R7shfThGz9oX3bLUBAeNd/BwmB+tyvB9jeITTmeZCcICeKn0 V72QGDRbg3DWGNY0x3OJQ8bxOUCo7jg4RyJRJHYPG1vOLh20gcm/bhyWHDaEZi9U+m1VXTFtfD 1FU= X-IronPort-AV: E=Sophos;i="5.73,465,1583222400"; d="scan'208";a="49434343" Received: from orw-gwy-02-in.mentorg.com ([192.94.38.167]) by esa3.mentor.iphmx.com with ESMTP; 02 Jun 2020 10:05:16 -0800 IronPort-SDR: BrwQJ03O8BSYjGeKR2Va4tW7RxRoXXDGZo85YINdMNk5gU53CFJZNl48KTmGi8smfYokcvvBJv rrHDSKvfxh9PUiifRHAn9sYAV0lzXbqcz0EnieoJPN+E5yUS+819hERUtxpW33ZylwHaAdmiCs r42bcRItwYRTbky9iHxaewRdmX2qOtlEKfi86URqUL9e0tTZT7duBEyRj9b4SV8n+LE3aGifDw PHimEkJBxvokZQj0zkdh+cwIxkaONWWSlM19Duy/OL+tyosLgyX2p2b5+XEbRA3VdEs5sa0orZ OsM= Date: Tue, 2 Jun 2020 18:05:09 +0000 From: Joseph Myers X-X-Sender: jsm28@digraph.polyomino.org.uk To: Lukasz Majewski CC: Paul Eggert , Adhemerval Zanella , Florian Weimer , GNU C Library , Andreas Schwab , Alistair Francis Subject: Re: [RFC 00/12] [RFC] y2038: Convert timespec_{sub|add|create} in support to be Y2038 safe In-Reply-To: <20200601140740.16371-1-lukma@denx.de> Message-ID: References: <20200601140740.16371-1-lukma@denx.de> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: SVR-IES-MBX-07.mgc.mentorg.com (139.181.222.7) To svr-ies-mbx-02.mgc.mentorg.com (139.181.222.2) X-Spam-Status: No, score=-3131.2 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Jun 2020 18:05:19 -0000 On Mon, 1 Jun 2020, Lukasz Majewski wrote: > First timespec* functions are renamed to have common "__" prefix for internal > functions. This is a preparatory work for further conversion. Leading "__" is *only* needed when the name is used in contexts where it could conflict with a user identifier. For example, in installed headers or with external linkage. In particular, static inline functions in non-installed headers never need a leading "__". So there is no justification for renaming timespec_compare unless you plan to make it an extern, non-inline function, in which case you should say so explicitly in that patch's commit message. xclock_gettime is inherently unsuitable for use in installed libraries, because it exits (FAIL_EXIT1) on error, which is not suitable for library code. So there is no need to rename that function; any installed library code that uses it has to be fixed not to use it and instead to do appropriate error checks on the result of clock_gettime (returning an error from the caller if appropriate) itself; library code should almost never exit the process on error. Likewise xclock_now, because it calls xclock_gettime, must not be used in installed libraries. These function naming changes are only appropriate for external linkage functions whose semantics are appropriate for use in installed libraries and that are actually used in such libraries or that you intend to be used in such libraries. Please review all those changes to make sure that you don't rename functions for which such library use is not appropriate or not planned. -- Joseph S. Myers joseph@codesourcery.com