From patchwork Wed Sep 3 21:19:09 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Pinski X-Patchwork-Id: 36662 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pa0-f70.google.com (mail-pa0-f70.google.com [209.85.220.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id EFB19202E4 for ; Wed, 3 Sep 2014 21:24:53 +0000 (UTC) Received: by mail-pa0-f70.google.com with SMTP id lf10sf86743652pab.5 for ; Wed, 03 Sep 2014 14:24:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=Wt95x0g3OY42U3H8NHa/E7AZqDd64SvRlNqAybw8eug=; b=DPqxgdRdoU8AQu84fW56aaZ/WrWGW67IRj/MGP+u5HtelmNTj08/P/S887rEtdfN5T UBOCzzd2wmG7R24XDDoxXwP81y8i4/PXIHrpdYLrXQtXA+wejdqovVVypOAlwrqM3lnw +CsATMqUlOBlHLjciC4NP1ZlHCfQHOc/64CmoKxK7M6S5Fh4uUjgK2bywrgzF2G+GtX4 PTCuDpfc2/W5R3J9uQcIW45twLd25lAEZlltkNB6wZ/dG2jPl85O60Axja8F/SQz9/aU pvBSDNvhVilxZ4Riti4F74m0bAqXW4SaczYGgZ7DqAQ9IL7BHD273D46i4jJQPhjhTn0 ZWwg== X-Gm-Message-State: ALoCoQlR3IrvNrH+fX3b+YZnm08VDUme4tLokONplcNvzEV0PkMx3d8SVNqdQOe8Dlzuw73oWgOO X-Received: by 10.66.65.75 with SMTP id v11mr59271pas.30.1409779492513; Wed, 03 Sep 2014 14:24:52 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.22.229 with SMTP id 92ls6506qgn.98.gmail; Wed, 03 Sep 2014 14:24:52 -0700 (PDT) X-Received: by 10.52.26.206 with SMTP id n14mr102052vdg.0.1409779492379; Wed, 03 Sep 2014 14:24:52 -0700 (PDT) Received: from mail-vc0-f169.google.com (mail-vc0-f169.google.com [209.85.220.169]) by mx.google.com with ESMTPS id sl18si1715270vdb.42.2014.09.03.14.24.52 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 03 Sep 2014 14:24:52 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.169 as permitted sender) client-ip=209.85.220.169; Received: by mail-vc0-f169.google.com with SMTP id hq11so9635084vcb.14 for ; Wed, 03 Sep 2014 14:24:52 -0700 (PDT) X-Received: by 10.52.129.165 with SMTP id nx5mr11295vdb.25.1409779492267; Wed, 03 Sep 2014 14:24:52 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.45.67 with SMTP id uj3csp740555vcb; Wed, 3 Sep 2014 14:24:51 -0700 (PDT) X-Received: by 10.70.38.49 with SMTP id d17mr83322pdk.19.1409779491390; Wed, 03 Sep 2014 14:24:51 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ng7si13482617pbc.58.2014.09.03.14.24.48 for ; Wed, 03 Sep 2014 14:24:49 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932963AbaICVYo (ORCPT + 26 others); Wed, 3 Sep 2014 17:24:44 -0400 Received: from mail-ie0-f170.google.com ([209.85.223.170]:63900 "EHLO mail-ie0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932651AbaICVXK (ORCPT ); Wed, 3 Sep 2014 17:23:10 -0400 Received: by mail-ie0-f170.google.com with SMTP id rl12so10591548iec.1 for ; Wed, 03 Sep 2014 14:23:09 -0700 (PDT) X-Received: by 10.42.212.146 with SMTP id gs18mr56880icb.96.1409779389594; Wed, 03 Sep 2014 14:23:09 -0700 (PDT) Received: from localhost.localdomain (64.2.3.195.ptr.us.xo.net. [64.2.3.195]) by mx.google.com with ESMTPSA id ig9sm6515653igb.13.2014.09.03.14.23.08 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Wed, 03 Sep 2014 14:23:09 -0700 (PDT) Received: from localhost.localdomain (apinskidesktop [127.0.0.1]) by localhost.localdomain (8.14.3/8.14.3/Debian-9.4) with ESMTP id s83LJPBj031071 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES256-SHA bits=256 verify=NO); Wed, 3 Sep 2014 14:19:25 -0700 Received: (from apinski@localhost) by localhost.localdomain (8.14.3/8.14.3/Submit) id s83LJPAj031070; Wed, 3 Sep 2014 14:19:25 -0700 From: Andrew Pinski To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, pinskia@gmail.com Cc: Andrew Pinski Subject: [PATCH 15/24] compat_binfmt_elf: coredump: Allow some core dump macros be overridden for compat. Date: Wed, 3 Sep 2014 14:19:09 -0700 Message-Id: <1409779158-30963-16-git-send-email-apinski@cavium.com> X-Mailer: git-send-email 1.7.2.5 In-Reply-To: <1409779158-30963-1-git-send-email-apinski@cavium.com> References: <1409779158-30963-1-git-send-email-apinski@cavium.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: apinski@cavium.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.169 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , On some targets (x86 [32bit and x32] and arm64 [aarch32 and ilp32]), there are two compat elf abis. This adds a few more "#define * COMPAT_*" for compat targets to define if needed. Signed-off-by: Andrew Pinski --- fs/compat_binfmt_elf.c | 17 +++++++++++++++++ 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/fs/compat_binfmt_elf.c b/fs/compat_binfmt_elf.c index 4d24d17..8307927 100644 --- a/fs/compat_binfmt_elf.c +++ b/fs/compat_binfmt_elf.c @@ -130,6 +130,23 @@ static void cputime_to_compat_timeval(const cputime_t cputime, #define arch_setup_additional_pages compat_arch_setup_additional_pages #endif + +#ifdef COMPAT_PR_REG_SIZE +#define PR_REG_SIZE COMPAT_PR_REG_SIZE +#endif + +#ifdef COMPAT_PRSTATUS_SIZE +#define PRSTATUS_SIZE COMPAT_PRSTATUS_SIZE +#endif + +#ifdef COMPAT_PR_REG_PTR +#define PR_REG_PTR COMPAT_PR_REG_PTR +#endif + +#ifdef COMPAT_SET_PR_FPVALID +#define SET_PR_FPVALID COMPAT_SET_PR_FPVALID +#endif + /* * Rename a few of the symbols that binfmt_elf.c will define. * These are all local so the names don't really matter, but it