Message ID | 20170718223333.110371-10-thgarnie@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <xen-devel-bounces@lists.xen.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A0A5360392 for <patchwork-xen-devel@patchwork.kernel.org>; Tue, 18 Jul 2017 22:37:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8C81E285CB for <patchwork-xen-devel@patchwork.kernel.org>; Tue, 18 Jul 2017 22:37:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 80A38285D8; Tue, 18 Jul 2017 22:37:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, RCVD_IN_DNSWL_MED, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 36336285CB for <patchwork-xen-devel@patchwork.kernel.org>; Tue, 18 Jul 2017 22:37:21 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from <xen-devel-bounces@lists.xen.org>) id 1dXb4X-0000YP-1K; Tue, 18 Jul 2017 22:34:29 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from <thgarnie@google.com>) id 1dXb4V-0000Wq-If for xen-devel@lists.xenproject.org; Tue, 18 Jul 2017 22:34:27 +0000 Received: from [85.158.137.68] by server-12.bemta-3.messagelabs.com id 48/D5-01862-2FC8E695; Tue, 18 Jul 2017 22:34:26 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrKIsWRWlGSWpSXmKPExsXiVRtspvupJy/ S4Hy1xfctk5kcGD0Of7jCEsAYxZqZl5RfkcCa0f9mC1PBH7aKnycSGxhvsnYxcnEICUxnlPj6 +RULiMMi8IpF4vODFrCMhEA/q8Tey7MZuxg5gZw4iS8/r7JD2OUSOx48YAKxhQSUJLZuWMoMY f9jlPj3SgvEZhPQktjTMJ8JZJCIwGwOicVdZ8BWCAh8ZJO4seUwM4jDLNDCJPHk3zawUcICzh I7Pk1iBbFZBFQlprcsZ+ti5ODgFbCSWHk7B8SUEDCW+PtFH8TkBIouv88DsddSore3gWUCo+A CRoZVjOrFqUVlqUW6JnpJRZnpGSW5iZk5uoYGxnq5qcXFiempOYlJxXrJ+bmbGIHBxgAEOxgb vzgdYpTkYFIS5d2qnBcpxJeUn1KZkVicEV9UmpNafIhRhoNDSYL3UDdQTrAoNT21Ii0zBxj2M GkJDh4lEV4bYOgL8RYXJOYWZ6ZDpE4xWnI0fdjyhYlj0oHtQPLVhP/fmIRY8vLzUqXEeReAzB MAacgozYMbB4vNS4yyUsK8jEAHCvEUpBblZpagyr9iFOdgVBLmPQYyhSczrwRu6yugg5iADhL 2zQE5qCQRISXVwOj7+JfI53tnTya+Ycz7+3/+4+DHcUcrIzNPO/36/++OVbHKpw1yfUeq1qhf X234sefkuRyO1NXstde0Ev9v+Zhy5NBP9sQLvF8ipYK7TyaUM6Tf9A33CVrmHGY/lyfnPJ99b 3EXSxr/1opXmgf+7lywdGrpP2+/2Gmn3aQ55BZpKxWxs1RcX6bEUpyRaKjFXFScCADjAXJUyA IAAA== X-Env-Sender: thgarnie@google.com X-Msg-Ref: server-14.tower-31.messagelabs.com!1500417264!105907829!1 X-Originating-IP: [74.125.83.54] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 9.4.25; banners=-,-,- X-VirusChecked: Checked Received: (qmail 23297 invoked from network); 18 Jul 2017 22:34:25 -0000 Received: from mail-pg0-f54.google.com (HELO mail-pg0-f54.google.com) (74.125.83.54) by server-14.tower-31.messagelabs.com with AES128-GCM-SHA256 encrypted SMTP; 18 Jul 2017 22:34:25 -0000 Received: by mail-pg0-f54.google.com with SMTP id u5so19919212pgq.3 for <xen-devel@lists.xenproject.org>; Tue, 18 Jul 2017 15:34:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=x7CBXa1CxcCHcainbvTTKr6TQjiJ2Gva4vtnCnlTeO4=; b=TYSHTw8rJX+WyTRbHwCZMSJugImr7JeUQEXe4nmcbjud8SAFRv/EWEGP1tqH8/rWZn DgjgDdirtF2CPdSxOL5db19SGLz6+KtwDHX4onAIxxNtKYC5nbScycsy00Xe4zKRs6B6 qb69dD/mPlnQT8ECysi3GFFRXxRpTQB12U3TED7ddtiIIkYI8WGwxis+RKMItFFhfBuv R+mJ73Fws1SEuqt5UkWJwBqQC3zLuTGkGunb7erarY6/LFHUMDrjUcjh/oi2wr+CW2To w5WJlCHelbCYqP263qqgYYRKSuJuZn3q4DKq+5iatUq6rfqu4qJqsKS0IYzp4zW6KRuw 27YA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=x7CBXa1CxcCHcainbvTTKr6TQjiJ2Gva4vtnCnlTeO4=; b=dXh2uNbAoY76EVhdGCvtzb3ge8Jq0qZPXkGpWZmIa/7NOonIq2DkFyI2HwF76fuBoc 1aoQYPvtwiEhql7j9DMYmtxmNr5vlTlVwPcxgp22RvTOtQ+81IvJkS8hsakc/TKvFcSR Hp2//RkAyqDEHEt165WqAS049EPGY8MlXZV3kyY3zMg4/ltHx1LGa4n11eIxwIYYojZT B3RDW8kPpw3/4rpiqgSnc3xzKhYQ2mmsunMyTxMvFj3jJTqSz20vep3Ie9TIhc+7WNF1 P9xCQk6/y46GsHYftWA1Q5Prw6OyKLayU56O3g/evd6nWvRR9EzK1t0HdWEKNh7UHJMC mWng== X-Gm-Message-State: AIVw113m6rFio/mPD8rc5wRwm7ZOG7jYTMjJ40BblOFeaOlg7bFS/oUZ xehP9noq4UVa8JCO X-Received: by 10.98.101.4 with SMTP id z4mr3852610pfb.163.1500417263704; Tue, 18 Jul 2017 15:34:23 -0700 (PDT) Received: from skynet.sea.corp.google.com ([100.100.206.164]) by smtp.gmail.com with ESMTPSA id b6sm6444242pgn.67.2017.07.18.15.34.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 18 Jul 2017 15:34:23 -0700 (PDT) From: Thomas Garnier <thgarnie@google.com> To: Herbert Xu <herbert@gondor.apana.org.au>, "David S . Miller" <davem@davemloft.net>, Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@redhat.com>, "H . Peter Anvin" <hpa@zytor.com>, Peter Zijlstra <peterz@infradead.org>, Josh Poimboeuf <jpoimboe@redhat.com>, Thomas Garnier <thgarnie@google.com>, Arnd Bergmann <arnd@arndb.de>, Matthias Kaehlcke <mka@chromium.org>, Boris Ostrovsky <boris.ostrovsky@oracle.com>, Juergen Gross <jgross@suse.com>, Paolo Bonzini <pbonzini@redhat.com>, =?UTF-8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= <rkrcmar@redhat.com>, Joerg Roedel <joro@8bytes.org>, Andy Lutomirski <luto@kernel.org>, Borislav Petkov <bp@alien8.de>, "Kirill A . Shutemov" <kirill.shutemov@linux.intel.com>, Brian Gerst <brgerst@gmail.com>, Borislav Petkov <bp@suse.de>, Christian Borntraeger <borntraeger@de.ibm.com>, "Rafael J . Wysocki" <rjw@rjwysocki.net>, Len Brown <len.brown@intel.com>, Pavel Machek <pavel@ucw.cz>, Tejun Heo <tj@kernel.org>, Christoph Lameter <cl@linux.com>, Kees Cook <keescook@chromium.org>, Paul Gortmaker <paul.gortmaker@windriver.com>, Chris Metcalf <cmetcalf@mellanox.com>, "Paul E . McKenney" <paulmck@linux.vnet.ibm.com>, Andrew Morton <akpm@linux-foundation.org>, Christopher Li <sparse@chrisli.org>, Dou Liyang <douly.fnst@cn.fujitsu.com>, Masahiro Yamada <yamada.masahiro@socionext.com>, Daniel Borkmann <daniel@iogearbox.net>, Markus Trippelsdorf <markus@trippelsdorf.de>, Peter Foley <pefoley2@pefoley.com>, Steven Rostedt <rostedt@goodmis.org>, Tim Chen <tim.c.chen@linux.intel.com>, Ard Biesheuvel <ard.biesheuvel@linaro.org>, Catalin Marinas <catalin.marinas@arm.com>, Matthew Wilcox <mawilcox@microsoft.com>, Michal Hocko <mhocko@suse.com>, Rob Landley <rob@landley.net>, Jiri Kosina <jkosina@suse.cz>, "H . J . Lu" <hjl.tools@gmail.com>, Paul Bolle <pebolle@tiscali.nl>, Baoquan He <bhe@redhat.com>, Daniel Micay <danielmicay@gmail.com> Date: Tue, 18 Jul 2017 15:33:20 -0700 Message-Id: <20170718223333.110371-10-thgarnie@google.com> X-Mailer: git-send-email 2.13.2.932.g7449e964c-goog In-Reply-To: <20170718223333.110371-1-thgarnie@google.com> References: <20170718223333.110371-1-thgarnie@google.com> Cc: linux-arch@vger.kernel.org, kvm@vger.kernel.org, linux-pm@vger.kernel.org, x86@kernel.org, linux-kernel@vger.kernel.org, linux-sparse@vger.kernel.org, linux-crypto@vger.kernel.org, kernel-hardening@lists.openwall.com, xen-devel@lists.xenproject.org Subject: [Xen-devel] [RFC 09/22] x86: pm-trace - Adapt assembly for PIE support X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion <xen-devel.lists.xen.org> List-Unsubscribe: <https://lists.xen.org/cgi-bin/mailman/options/xen-devel>, <mailto:xen-devel-request@lists.xen.org?subject=unsubscribe> List-Post: <mailto:xen-devel@lists.xen.org> List-Help: <mailto:xen-devel-request@lists.xen.org?subject=help> List-Subscribe: <https://lists.xen.org/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xen.org?subject=subscribe> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" <xen-devel-bounces@lists.xen.org> X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/arch/x86/include/asm/pm-trace.h b/arch/x86/include/asm/pm-trace.h index 7b7ac42c3661..a3801261f0dd 100644 --- a/arch/x86/include/asm/pm-trace.h +++ b/arch/x86/include/asm/pm-trace.h @@ -7,7 +7,7 @@ do { \ if (pm_trace_enabled) { \ const void *tracedata; \ - asm volatile(_ASM_MOV " $1f,%0\n" \ + asm volatile(_ASM_GET_PTR(1f, %0) "\n" \ ".section .tracedata,\"a\"\n" \ "1:\t.word %c1\n\t" \ _ASM_PTR " %c2\n" \
Change assembly to use the new _ASM_GET_PTR macro instead of _ASM_MOV for the assembly to be PIE compatible. Position Independent Executable (PIE) support will allow to extended the KASLR randomization range below the -2G memory limit. Signed-off-by: Thomas Garnier <thgarnie@google.com> --- arch/x86/include/asm/pm-trace.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)