From patchwork Wed Apr 8 21:41:05 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nathan Lynch X-Patchwork-Id: 6182761 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 47DED9F1C4 for ; Wed, 8 Apr 2015 21:44:58 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 81D6520395 for ; Wed, 8 Apr 2015 21:44:57 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 35CEB20386 for ; Wed, 8 Apr 2015 21:44:56 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Yfxj4-0003fP-Un; Wed, 08 Apr 2015 21:41:34 +0000 Received: from relay1.mentorg.com ([192.94.38.131]) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Yfxj2-0003eE-A8 for linux-arm-kernel@lists.infradead.org; Wed, 08 Apr 2015 21:41:33 +0000 Received: from svr-orw-fem-04.mgc.mentorg.com ([147.34.97.41]) by relay1.mentorg.com with esmtp id 1Yfxid-00027q-Pb from Nathan_Lynch@mentor.com ; Wed, 08 Apr 2015 14:41:07 -0700 Received: from localhost (147.34.91.1) by SVR-ORW-FEM-04.mgc.mentorg.com (147.34.97.41) with Microsoft SMTP Server (TLS) id 14.3.224.2; Wed, 8 Apr 2015 14:41:06 -0700 From: Nathan Lynch To: Russell King Subject: [PATCH] ARM: VDSO: depend on CPU_V7 Date: Wed, 8 Apr 2015 16:41:05 -0500 Message-ID: <1428529265-26772-1-git-send-email-nathan_lynch@mentor.com> X-Mailer: git-send-email 1.9.3 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150408_144132_381466_2F79027B X-CRM114-Status: GOOD ( 10.33 ) X-Spam-Score: -0.7 (/) Cc: Arnd Bergmann , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP (Arnd reported a build break with the VDSO code when targeting v4 (but not v4t). I haven't been able to recreate it locally because all the toolchains I have at hand convert 'bx lr' to 'mov pc,lr' when targeting v4.) The __get_datapage routine in the VDSO uses 'bx lr' to return to the caller. This is inappropriate when targeting v4 CPUs, and the VDSO is unlikely to be useful for pre-v7 CPUs anyway due to its reliance on the generic timers extension, so the easy thing to do here is just make CONFIG_VDSO depend on CONFIG_CPU_V7. An alternative considered was to use 'ldr pc,lr' when armv4 (or lower) is enabled, but Arnd pointed out that this would be broken when running with a kernel that supports both v4 arnd v4t, and you have a thumb user space. Reported-by: Arnd Bergmann Signed-off-by: Nathan Lynch Acked-by: Arnd Bergmann --- arch/arm/mm/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index b7644310236b..b4f92b9a13ac 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig @@ -827,7 +827,7 @@ config KUSER_HELPERS config VDSO bool "Enable VDSO for acceleration of some system calls" - depends on AEABI && MMU + depends on AEABI && MMU && CPU_V7 default y if ARM_ARCH_TIMER select GENERIC_TIME_VSYSCALL help