Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp1859827rwr; Fri, 28 Apr 2023 02:54:11 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7GwciP602xShLfvXaYueUAUrx2tF6RWN7z/P/8d8kJA0UF/NRawV+hVudJzyb893kgybLq X-Received: by 2002:a05:6a20:9191:b0:f2:4d44:3560 with SMTP id v17-20020a056a20919100b000f24d443560mr5902363pzd.19.1682675651270; Fri, 28 Apr 2023 02:54:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682675651; cv=none; d=google.com; s=arc-20160816; b=CKBWSUb+M/HhF9fW3Np1XpuSpcsgj9ob0Ypjgo+dPe0LYpATSGze92TpEtT9VblNw1 prKQ4G6GEVapmyDHnV0ARdaFypu4wxaEdM0bNpu0yF/XO4nnTiQrdhtquvh7uAU98Fwy +gvyobB8ad/yZoker/RjFGNbK6uOgGFijldNTnirHM8hrjVupkMUyWFR58LCnv7WpJVx Xjij6d9rRqEQCmRhODj+pRdDek3cIEYw6VVTTwH2V8xKgEhdXh1GQVu1Ksfiav3gPglf e2y2Lx9rqgiJZAlQv1AExMzcepjTDjHUL+zVpn7hfsy4+sR2LgTksIxPm28QWd7i2UYI mYOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=VtHyvyd+h4I56mLQ8MQqUwbUEUpPiJqEGHwuJdwQGiw=; b=wq7U7cRxglPOJpnlW47OAJRtYpYsrtnY83vAA5JOP0pcHxxaH+PzZ5EKs/LoqdU1yn vkRqpvj0utLMnAQMFdkjhQ00R54EtEz+JVKGJJoTMlXgL+An9l9S4mRibxYHjCJt4FAR kATP3hCDYy3LEfhO70VcIq9MsKxp1Dw3Z1RqMeXCmOKVgxAsBxndHnQvaxjFXufSi1eu L7RjUq+B5ak/APSEAVsUhKC2B61pUqfl8nDuitp5JBqwGqpRfM6/30vvlI2QUluDiDsg vXKu/XI0tYaZs4J+WdNuH8suWS12GrhQATEF8bTs+8Lvt9FtOZcK1HMPhJq7z2DlQH+C neKQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=antgroup.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n7-20020a6546c7000000b0050c0e269719si21150984pgr.513.2023.04.28.02.53.57; Fri, 28 Apr 2023 02:54:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=antgroup.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345742AbjD1JwZ (ORCPT + 99 others); Fri, 28 Apr 2023 05:52:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60170 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345743AbjD1JwO (ORCPT ); Fri, 28 Apr 2023 05:52:14 -0400 Received: from out0-198.mail.aliyun.com (out0-198.mail.aliyun.com [140.205.0.198]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A15045263 for ; Fri, 28 Apr 2023 02:52:03 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R271e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018047213;MF=houwenlong.hwl@antgroup.com;NM=1;PH=DS;RN=11;SR=0;TI=SMTPD_---.STDfrtZ_1682675513; Received: from localhost(mailfrom:houwenlong.hwl@antgroup.com fp:SMTPD_---.STDfrtZ_1682675513) by smtp.aliyun-inc.com; Fri, 28 Apr 2023 17:51:54 +0800 From: "Hou Wenlong" To: linux-kernel@vger.kernel.org Cc: "Thomas Garnier" , "Lai Jiangshan" , "Kees Cook" , "Hou Wenlong" , "Thomas Gleixner" , "Ingo Molnar" , "Borislav Petkov" , "Dave Hansen" , , "H. Peter Anvin" Subject: [PATCH RFC 05/43] x86: pm-trace: Adapt assembly for PIE support Date: Fri, 28 Apr 2023 17:50:45 +0800 Message-Id: <49a5d885f8cc02048a979ced4bf7e54f700ecb94.1682673543.git.houwenlong.hwl@antgroup.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Thomas Garnier From: Thomas Garnier Change assembly to use the new _ASM_MOVABS macro instead of _ASM_MOV for the assembly to be PIE compatible. Signed-off-by: Thomas Garnier Signed-off-by: Hou Wenlong Cc: Lai Jiangshan Cc: Kees Cook --- arch/x86/include/asm/pm-trace.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/include/asm/pm-trace.h b/arch/x86/include/asm/pm-trace.h index bfa32aa428e5..972070806ce9 100644 --- a/arch/x86/include/asm/pm-trace.h +++ b/arch/x86/include/asm/pm-trace.h @@ -8,7 +8,7 @@ do { \ if (pm_trace_enabled) { \ const void *tracedata; \ - asm volatile(_ASM_MOV " $1f,%0\n" \ + asm volatile(_ASM_MOVABS " $1f,%0\n" \ ".section .tracedata,\"a\"\n" \ "1:\t.word %c1\n\t" \ _ASM_PTR " %c2\n" \ -- 2.31.1