From patchwork Tue Feb 25 12:38:57 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 3716351 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 73431BF13A for ; Tue, 25 Feb 2014 12:39:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A2871201DD for ; Tue, 25 Feb 2014 12:39:46 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (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 C08C5201D3 for ; Tue, 25 Feb 2014 12:39:44 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WIHIN-0003wn-6Q; Tue, 25 Feb 2014 12:39:35 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1WIHIK-0000Ty-H5; Tue, 25 Feb 2014 12:39:32 +0000 Received: from mail-we0-f181.google.com ([74.125.82.181]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WIHIG-0000TD-IZ for linux-arm-kernel@lists.infradead.org; Tue, 25 Feb 2014 12:39:29 +0000 Received: by mail-we0-f181.google.com with SMTP id w61so327322wes.40 for ; Tue, 25 Feb 2014 04:39:05 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=anJKGEOGuuTl0jp9shdwLU8UmYssxLWb81D+974TAnw=; b=O5mZoXLYsaCeT1DHqS4pBWoK+vMVYbrnDnSdSOHEB34e87lfxKwO0BpY4Gx/n9unVp WndWOWokbfxs3hcsCBZlA/7Qkz8QORqZklzLaKiAOmPi5omh1p9/JhzUxFmosDtlAcs5 dwxhqeJbHpj6Y/Hjps2kT6sa0y2pv5ZsfVo3D/XuazBfPsC81o73ZqjgfZdhOM9uYXI0 y7ZGhBT7DGxjIRNDbO69qE1skeEYITkEQ1WnxSqgN7LBXwJJjwyBvT18O6fqNwr0bGDB di5sCyrUrOGwuamDSdzkA70pw61bw5M9ihs74b/4boSAyDD4Qa9l4kjeMqrwTnq0SF9a uFFw== X-Gm-Message-State: ALoCoQleGlsuu03qRtpWtFLIT7Gf3HYWlKqCYTx9nv+Pw8oB38w5nlhPwKsoIfZDWmq+2ecUOKGo X-Received: by 10.180.211.239 with SMTP id nf15mr19555655wic.9.1393331945599; Tue, 25 Feb 2014 04:39:05 -0800 (PST) Received: from ards-macbook-pro.local (cag06-7-83-153-85-71.fbx.proxad.net. [83.153.85.71]) by mx.google.com with ESMTPSA id jw4sm50423292wjc.20.2014.02.25.04.39.04 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 25 Feb 2014 04:39:05 -0800 (PST) From: Ard Biesheuvel To: linux-arm-kernel@lists.infradead.org, catalin.marinas@arm.com, peter.maydell@linaro.org Subject: [PATCH resend 1/3] binfmt_elf: add ELF_HWCAP2 to compat auxv entries Date: Tue, 25 Feb 2014 13:38:57 +0100 Message-Id: <1393331939-31289-2-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1393331939-31289-1-git-send-email-ard.biesheuvel@linaro.org> References: <1393331939-31289-1-git-send-email-ard.biesheuvel@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140225_073928_727685_69DFCBBE X-CRM114-Status: UNSURE ( 9.06 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.6 (--) Cc: ryan.arnold@linaro.org, Ard Biesheuvel X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 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, 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 Add ELF_HWCAP2 to the set of auxv entries that is passed to a 32-bit ELF program running in 32-bit compat mode under a 64-bit kernel. Signed-off-by: Ard Biesheuvel Acked-by: Catalin Marinas Acked-by: Andrew Morton --- fs/compat_binfmt_elf.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/fs/compat_binfmt_elf.c b/fs/compat_binfmt_elf.c index a81147e2e4ef..4d24d17bcfc1 100644 --- a/fs/compat_binfmt_elf.c +++ b/fs/compat_binfmt_elf.c @@ -88,6 +88,11 @@ static void cputime_to_compat_timeval(const cputime_t cputime, #define ELF_HWCAP COMPAT_ELF_HWCAP #endif +#ifdef COMPAT_ELF_HWCAP2 +#undef ELF_HWCAP2 +#define ELF_HWCAP2 COMPAT_ELF_HWCAP2 +#endif + #ifdef COMPAT_ARCH_DLINFO #undef ARCH_DLINFO #define ARCH_DLINFO COMPAT_ARCH_DLINFO