From patchwork Thu Aug 1 18:15:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adhemerval Zanella X-Patchwork-Id: 170391 Delivered-To: patch@linaro.org Received: by 2002:a92:512:0:0:0:0:0 with SMTP id q18csp5790109ile; Thu, 1 Aug 2019 11:16:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqw87MSbhtg6fQ07K8xYKccXrEbSMKe2kqzVw3R4j1x+G+1nxupjBbTemri9zKvbBW0hrcwT X-Received: by 2002:a63:6904:: with SMTP id e4mr59473844pgc.321.1564683361972; Thu, 01 Aug 2019 11:16:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564683361; cv=none; d=google.com; s=arc-20160816; b=dWlS/4H2Fa9PBtksripfMQL8IJREOT5orsrEXP9Uxv8kon20vQiJdEtIxH2wSj4W0y 6ijdtQq4GrSa9T8r5f5Qlc39w1gMcHm51FmCcXddiqWcHGe2ucJRQ4ghX+y+B94ggyGG mj3q+Y0QTwwPzA5BzkRi0BzWNUJc2FeSCXxbHa4ul83VchpaPsomJJ4VtWk0t9AfZXhN bD69bjTzQCOFPqGexZPwUdV7LRHjnL6OfaplsJ2EJjW4TlLTMk/BauQYdgmqjuhn/Y73 xLMX84Yl1ftaYjIhMekqDswbyPhF7maL+SJNNbWK0ZQI08uBWXHFPDsARY6Q5wKHqWJy 4G0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:to:from :dkim-signature:delivered-to:sender:list-help:list-post:list-archive :list-subscribe:list-unsubscribe:list-id:precedence:mailing-list :dkim-signature:domainkey-signature; bh=YAJOTy82WEnFh7qT7GuiRDcR9YkfP5ZBtUwlSVkOU9E=; b=tHDQgB5DweKe+cN1nDCba2BpAFbd0Pttp0oPtmFlOjnHZvfnLFyogf+eStXZRFsoU6 gCrz+9+nUKRjVWzqtavi6M+ZBeVjumIGn6DA7KHNfLUeiJP66cVNTot3Hio6jF6uDrZc C0zPYo5Ccfb0hjHeiAdzt9Szp3XLfS3Qsx9nPeMQ4Jmgvy8AAnekpdZWA1yZDyHz6YJn h+wH3/fVAODOI4rPLzgHX5fSTtCRe5xsW+cRQpEoG3vzM4JosTksipcbpoyn1gdnn1ml F18A08TxNfppIEfq0Bb9c/YHegzCFWEU08V3P/jU3osyv3DMFH6Lx5NUdgkt2/OEORlZ IkSQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sourceware.org header.s=default header.b=o6sEQIW9; dkim=pass header.i=@linaro.org header.s=google header.b=aYmOpBLe; spf=pass (google.com: domain of libc-alpha-return-104110-patch=linaro.org@sourceware.org designates 209.132.180.131 as permitted sender) smtp.mailfrom="libc-alpha-return-104110-patch=linaro.org@sourceware.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id c18si33832578plo.316.2019.08.01.11.16.01 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 01 Aug 2019 11:16:01 -0700 (PDT) Received-SPF: pass (google.com: domain of libc-alpha-return-104110-patch=linaro.org@sourceware.org designates 209.132.180.131 as permitted sender) client-ip=209.132.180.131; Authentication-Results: mx.google.com; dkim=pass header.i=@sourceware.org header.s=default header.b=o6sEQIW9; dkim=pass header.i=@linaro.org header.s=google header.b=aYmOpBLe; spf=pass (google.com: domain of libc-alpha-return-104110-patch=linaro.org@sourceware.org designates 209.132.180.131 as permitted sender) smtp.mailfrom="libc-alpha-return-104110-patch=linaro.org@sourceware.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=gREXp9oxGmjgRn7o1oICpRyuXeMim/V gbSKlxcKdDR1hNn99fcEGSsj1dS9Dx531MlWFYGHpmyyDpevmgJ8n5qSKTBzJOk5 SkDmYXZbrA9a6WL85GZ2jexsca/DYDb47W6BhnVrS6j+LZlOIq4HODxjN7sx2RMV e4r/AHL6IBzE= 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:from:to:subject:date:message-id:in-reply-to :references; s=default; bh=u5bdzeCXF0V7ZjzmWyB94GFhb8c=; b=o6sEQ IW9iLaxvXvuF25xs7Kx2h2bGGFejja90/wDkAGX1Za4BzjhCkibFZU8FnXQ1NEY/ qPZaj4I6mWWB54gVq810xyTUsssDLHRQ10+E3HPucDLQ0olEugmN3eWwr6JaRMSi rMBzSp5sS8mCleNdsUO/rtihhnMXyE8PYhEgTQ= Received: (qmail 102519 invoked by alias); 1 Aug 2019 18:15:52 -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 Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 102450 invoked by uid 89); 1 Aug 2019 18:15:51 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-15.9 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=accident X-HELO: mail-qt1-f193.google.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references; bh=YAJOTy82WEnFh7qT7GuiRDcR9YkfP5ZBtUwlSVkOU9E=; b=aYmOpBLelYuxqx+oF2k1VhSNlVvWlTblm+vfBdUNBMEchP4iIGagx7liryJxamJ0gu JEOFbmkG5kAL1RLGkFhOxpaRO77P/O1CUcsqVSzwJvijbVa91fHt424JrKEJrLT4NtWv VXWVs1ajU5GAY7VrM7DawZmquTWo8sWk4w2FK9oM978MQ38Xl0ZGUebCO1/MFrVuZcl8 ePIk0JSMLXQI06/N9buDj+3mVTNSik09osSe41Yfc+ZwKnwiMhmjVt7y+VR+gGQuQMyy zLY9xwaHpeCi/3qQHje0/1hci7CsekrBVDSqZkKnQKW1PoWDMZcPAfcZhS4D135q0+yg pylA== Return-Path: From: Adhemerval Zanella To: libc-alpha@sourceware.org Subject: [PATCH 2/2] linux: Make profil_counter a compat_symbol (BZ#17726) Date: Thu, 1 Aug 2019 15:15:34 -0300 Message-Id: <20190801181534.8802-2-adhemerval.zanella@linaro.org> In-Reply-To: <20190801181534.8802-1-adhemerval.zanella@linaro.org> References: <20190801181534.8802-1-adhemerval.zanella@linaro.org> As indicated by Joseph's comment on BZ#17726, this symbol is most likely a historical ABI accident. This patch make it on both arm and sparc ABIs a compat_symbol. Checked with a build arm-linux-gnueabihf, sparcv9-linux-gnu, adn sparc64-linux-gnu to see if the symbol is still present. * gmon/Versions (libc) [GLIBC_2.31]: New entry. * sysdeps/unix/sysv/linux/arm/profil-counter.h (profil_counter): Make a compat_symbol. * sysdeps/unix/sysv/linux/sparc/profil-counter.h (__profil_counter_global): Likewise. --- gmon/Versions | 2 ++ sysdeps/unix/sysv/linux/arm/profil-counter.h | 5 ++++- sysdeps/unix/sysv/linux/sparc/profil-counter.h | 5 ++++- 3 files changed, 10 insertions(+), 2 deletions(-) -- 2.17.1 diff --git a/gmon/Versions b/gmon/Versions index d0b63334f2..cc705bd978 100644 --- a/gmon/Versions +++ b/gmon/Versions @@ -19,4 +19,6 @@ libc { GLIBC_2.2.3 { sprofil; } + GLIBC_2.31 { + } } diff --git a/sysdeps/unix/sysv/linux/arm/profil-counter.h b/sysdeps/unix/sysv/linux/arm/profil-counter.h index 29a9c7fecc..6243a02bb5 100644 --- a/sysdeps/unix/sysv/linux/arm/profil-counter.h +++ b/sysdeps/unix/sysv/linux/arm/profil-counter.h @@ -30,5 +30,8 @@ __profil_counter (int signo, siginfo_t *_si, void *scp) asm volatile (""); } #ifndef __profil_counter -weak_alias (__profil_counter, profil_counter) +# include +# if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_31) +compat_symbol (libc, __profil_counter, profil_counter, GLIBC_2_0); +# endif #endif diff --git a/sysdeps/unix/sysv/linux/sparc/profil-counter.h b/sysdeps/unix/sysv/linux/sparc/profil-counter.h index ad06a4fe06..01271103bb 100644 --- a/sysdeps/unix/sysv/linux/sparc/profil-counter.h +++ b/sysdeps/unix/sysv/linux/sparc/profil-counter.h @@ -21,6 +21,8 @@ #include #ifndef __profil_counter +# include +# if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_31) void __profil_counter_global (int signo, struct sigcontext *si) { @@ -30,5 +32,6 @@ __profil_counter_global (int signo, struct sigcontext *si) profil_count (si->si_regs.pc); #endif } -weak_alias (__profil_counter_global, profil_counter) +compat_symbol (libc, __profil_counter_global, profil_counter, GLIBC_2_0); +# endif #endif