Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp9206379ybi; Wed, 10 Jul 2019 06:27:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqyeHLuICSX+bylAEJi/RzcNHS/n+jF+mYzgYePC4hn1Bf6ZFzbXO1Ft6bZ1dT39AzDy/RHj X-Received: by 2002:a17:90a:1a0d:: with SMTP id 13mr6647074pjk.99.1562765261209; Wed, 10 Jul 2019 06:27:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562765261; cv=none; d=google.com; s=arc-20160816; b=kICB+WUdgzzYDC1CP6UCKSsJkzhq9u3Mn1kyJ29kcxHlIZUMxXwygmvzTKdkWnh8t2 thB1xUrjD7re38fgIiDTrHIAl3FM1O6E3hymZ8RNbX1SavflySF9hs9kpqpJ6IJT9OEQ wQvyZp3NaN5dr60rIC71zzI5JmTqkDZ6DtIvYedYRuV5tbxwwnocSinGzvPWc5lJMjLm Efx1q7e+s7QBSr5ihob33fTGM5GN6yrVwvIu5WPyHCz5rBh0CpNFGmw/VFw8jT3L9O59 K/Bv0ABAW4NdGJAPdOxTLZLsjRhdxMDI0QCncVU0mu+8Iwt4ftMZ1NZFVmCUqfEsTenj s0Ew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=W5AccjlXcryhFySuUOFpomM1JqPMRcUKuw0MlpXOF6s=; b=ekzD3x3m2QDeSEF51pJ3nIFnbm6RqiavVOxz9FIo/PajL/SToDBwr95KqnmVIO22vO kQZJqx7AO/KggMzZDi/wvXQvwKaFoADUw/On0ThkL+kPMj4GmwuwsERfRGwXdWboqQB0 dXoBHFk/nwrAcht8SxI4R7ohy5tL0Y2ML07vQ8FVJFUleuwcijijzP6oXclFzvTdHykl mCNrwU6AzZY7TcaFV3MiFzmlDvGIlVq4yV/2tU3Y6hVd3UoGGn0BPC1joRPv674gZk2v LrC9zQ3jtovMCuwsF09y9jHfie0AKQHETvgOBawdIOcs4X6nyTeSZHSJC6YAawoaEmdK B34A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id br15si2190789pjb.13.2019.07.10.06.27.24; Wed, 10 Jul 2019 06:27:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727183AbfGJNFJ (ORCPT + 99 others); Wed, 10 Jul 2019 09:05:09 -0400 Received: from foss.arm.com ([217.140.110.172]:32982 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725956AbfGJNFJ (ORCPT ); Wed, 10 Jul 2019 09:05:09 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 5893A2B; Wed, 10 Jul 2019 06:05:08 -0700 (PDT) Received: from e119884-lin.cambridge.arm.com (e119884-lin.cambridge.arm.com [10.1.196.72]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 846A43F738; Wed, 10 Jul 2019 06:05:05 -0700 (PDT) From: Vincenzo Frascino To: linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-kselftest@vger.kernel.org Cc: catalin.marinas@arm.com, will.deacon@arm.com, arnd@arndb.de, linux@armlinux.org.uk, ralf@linux-mips.org, paul.burton@mips.com, daniel.lezcano@linaro.org, tglx@linutronix.de, salyzyn@android.com, pcc@google.com, shuah@kernel.org, 0x7f454c46@gmail.com, linux@rasmusvillemoes.dk, huw@codeweavers.com, sthotton@marvell.com, andre.przywara@arm.com, luto@kernel.org, john.stultz@linaro.org Subject: [PATCH] arm64: vdso: Fix ABI regression in compat vdso Date: Wed, 10 Jul 2019 14:04:52 +0100 Message-Id: <20190710130452.44111-1-vincenzo.frascino@arm.com> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190621095252.32307-11-vincenzo.frascino@arm.com> References: <20190621095252.32307-11-vincenzo.frascino@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Prior to the introduction of Unified vDSO support and compat layer for vDSO on arm64, AT_SYSINFO_EHDR was not defined for compat tasks. In the current implementation, AT_SYSINFO_EHDR is defined even if the compat vdso layer is not built and this causes a regression in the expected behavior of the ABI. Restore the ABI behavior making sure that AT_SYSINFO_EHDR for compat tasks is defined only when CONFIG_GENERIC_COMPAT_VDSO and CONFIG_COMPAT_VDSO are enabled. Reported-by: John Stultz Signed-off-by: Vincenzo Frascino --- arch/arm64/include/asm/elf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/include/asm/elf.h b/arch/arm64/include/asm/elf.h index 3c7037c6ba9b..b7992bb9d414 100644 --- a/arch/arm64/include/asm/elf.h +++ b/arch/arm64/include/asm/elf.h @@ -202,7 +202,7 @@ typedef compat_elf_greg_t compat_elf_gregset_t[COMPAT_ELF_NGREG]; ({ \ set_thread_flag(TIF_32BIT); \ }) -#ifdef CONFIG_GENERIC_COMPAT_VDSO +#if defined(CONFIG_COMPAT_VDSO) && defined(CONFIG_GENERIC_COMPAT_VDSO) #define COMPAT_ARCH_DLINFO \ do { \ /* \ -- 2.22.0