| Message ID | 20260324114527.91494-3-fangyu.yu@linux.alibaba.com |
|---|---|
| State | Handled Elsewhere |
| Headers | show
Return-Path:
<kvm-riscv-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org>
X-Original-To: incoming@patchwork.ozlabs.org
Delivered-To: patchwork-incoming@legolas.ozlabs.org
Authentication-Results: legolas.ozlabs.org;
dkim=pass (2048-bit key;
secure) header.d=lists.infradead.org header.i=@lists.infradead.org
header.a=rsa-sha256 header.s=bombadil.20210309 header.b=C6PwzxDP;
dkim=fail reason="signature verification failed" (1024-bit key;
unprotected) header.d=linux.alibaba.com header.i=@linux.alibaba.com
header.a=rsa-sha256 header.s=default header.b=TLeffPEX;
dkim-atps=neutral
Authentication-Results: legolas.ozlabs.org;
spf=none (no SPF record) smtp.mailfrom=lists.infradead.org
(client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org;
envelope-from=kvm-riscv-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org;
receiver=patchwork.ozlabs.org)
Received: from bombadil.infradead.org (bombadil.infradead.org
[IPv6:2607:7c80:54:3::133])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)
(No client certificate requested)
by legolas.ozlabs.org (Postfix) with ESMTPS id 4fg7Zt1f1bz1y1g
for <incoming@patchwork.ozlabs.org>; Tue, 24 Mar 2026 22:48:01 +1100 (AEDT)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=lists.infradead.org; s=bombadil.20210309; h=Sender:
Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post:
List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:
Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:
Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:
List-Owner; bh=xpThCwSZjPRv299FoBRgibbGnFVhlXui1ACHBC04fsg=; b=C6PwzxDPEwG0jy
tUpM08DhCMuQpucLi0Lnr2j5oPXgq8XyzFSxeKpyA7GI6YjYfba40vKjpWhzyOS8vNCwI9mQJ+v6k
ieojSEieBHy1h2fl6idsIDVWbxayvbjtBa46GssJipiDB+4bw8D14MmCKCuVOl3mI5Hljt4J7p36O
+tGW1M6L8zjDVKB1k233rbnWOgzQRuAIKnL/5NeUK0wCpvgf0kl0weyytqwbc4X3ttPMEkey63j8K
DGr+BGc83J4tZq4sOv4Vlmci5XmMe8OIdyKAZLzsz9WJ4DHaKi/v+1vR7RnQ3qONBN68ulzrboxyW
HCnNgQz2Fr+xubAM6pbg==;
Received: from localhost ([::1] helo=bombadil.infradead.org)
by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux))
id 1w50El-00000001IrF-0mNG;
Tue, 24 Mar 2026 11:47:55 +0000
Received: from out199-1.us.a.mail.aliyun.com ([47.90.199.1])
by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux))
id 1w50Ei-00000001Iq8-19My
for kvm-riscv@lists.infradead.org;
Tue, 24 Mar 2026 11:47:54 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=linux.alibaba.com; s=default;
t=1774352741; h=From:To:Subject:Date:Message-Id:MIME-Version;
bh=eGoUX5+U64mMyKbsYD4ZIBWAtxP/BeYqHD20VtSl4vc=;
b=TLeffPEX1hMfUlHGGNXJQ0orUMvWCoGAz5t4rI3U9z9yUAC60TrsCz8aI/bpHxaaPeex1ZtwO5AMvjDSmHg2/xCnwfAWNBiC42gJ5SmfCf0Vz4Torp/dxzmqtSW+ibTlpWxQT199/iZfGdwd5YajxnAMmWhu+uVH7YeWtwQx6xI=
X-Alimail-AntiSpam:
AC=PASS;BC=-1|-1;BR=01201311R781e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=maildocker-contentspam033037033178;MF=fangyu.yu@linux.alibaba.com;NM=1;PH=DS;RN=17;SR=0;TI=SMTPD_---0X.eWVFc_1774352735;
Received: from localhost.localdomain(mailfrom:fangyu.yu@linux.alibaba.com
fp:SMTPD_---0X.eWVFc_1774352735 cluster:ay36)
by smtp.aliyun-inc.com;
Tue, 24 Mar 2026 19:45:35 +0800
From: fangyu.yu@linux.alibaba.com
To: pjw@kernel.org,
palmer@dabbelt.com,
aou@eecs.berkeley.edu,
alex@ghiti.fr,
songshuaishuai@tinylab.org,
bjorn@rivosinc.com,
ardb@kernel.org,
arnd@arndb.de,
bhelgaas@google.com,
richard.lyu@suse.com,
tzimmermann@suse.de,
nathan@kernel.org
Cc: guoren@kernel.org,
kvm-riscv@lists.infradead.org,
linux-riscv@lists.infradead.org,
linux-kernel@vger.kernel.org,
Fangyu Yu <fangyu.yu@linux.alibaba.com>
Subject: [PATCH 2/4] riscv: kexec: Place norelocate trampoline into
.kexec.tramp.text
Date: Tue, 24 Mar 2026 19:45:25 +0800
Message-Id: <20260324114527.91494-3-fangyu.yu@linux.alibaba.com>
X-Mailer: git-send-email 2.39.3 (Apple Git-146)
In-Reply-To: <20260324114527.91494-1-fangyu.yu@linux.alibaba.com>
References: <20260324114527.91494-1-fangyu.yu@linux.alibaba.com>
MIME-Version: 1.0
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3
X-CRM114-CacheID: sfid-20260324_044752_584454_43A5B509
X-CRM114-Status: UNSURE ( 6.13 )
X-CRM114-Notice: Please train this message.
X-Spam-Score: -17.6 (-----------------)
X-Spam-Report: Spam detection software,
running on the system "bombadil.infradead.org",
has NOT identified this incoming email as spam. The original
message has been attached to this so you can view it or label
similar future email. If you have any questions, see
the administrator of that system for details.
Content preview: From: Fangyu Yu <fangyu.yu@linux.alibaba.com> Move
riscv_kexec_norelocate
out of the generic .text section and into a dedicated executable
trampoline
section,
.kexec.tramp.text. Signed-off-by: Fangyu Yu <fangyu.yu@linux.alibaba.com>
--- arch/riscv/include/asm/kexec.h | 9 +++++++++
arch/riscv/kernel/kexec_relocate.S
| 2 +- 2 files changed, 10 insertions(+), 1 deletion(-)
Content analysis details: (-17.6 points, 5.0 required)
pts rule name description
---- ----------------------
--------------------------------------------------
-0.0 SPF_PASS SPF: sender matches SPF record
0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record
-7.5 USER_IN_DEF_SPF_WL From: address is in the default SPF welcome-list
-7.5 USER_IN_DEF_DKIM_WL From: address is in the default DKIM welcome-list
-0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from
envelope-from domain
-0.1 DKIM_VALID Message has at least one valid DKIM or DK
signature
-0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from
author's
domain
0.1 DKIM_SIGNED Message has a DKIM or DK signature,
not necessarily valid
-1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
[score: 0.0000]
0.0 RCVD_IN_VALIDITY_SAFE_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to
Validity was blocked. See
https://knowledge.validity.com/hc/en-us/articles/20961730681243
for more information.
[47.90.199.1 listed in sa-accredit.habeas.com]
0.0 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED RBL: ADMINISTRATOR NOTICE: The
query to Validity was blocked. See
https://knowledge.validity.com/hc/en-us/articles/20961730681243
for more information.
[47.90.199.1 listed in
sa-trusted.bondedsender.org]
0.0 UNPARSEABLE_RELAY Informational: message has unparseable relay
lines
-0.5 ENV_AND_HDR_SPF_MATCH Env and Hdr From used in default SPF WL Match
0.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to
Validity was blocked. See
https://knowledge.validity.com/hc/en-us/articles/20961730681243
for more information.
[47.90.199.1 listed in bl.score.senderscore.com]
X-BeenThere: kvm-riscv@lists.infradead.org
X-Mailman-Version: 2.1.34
Precedence: list
List-Id: <kvm-riscv.lists.infradead.org>
List-Unsubscribe: <http://lists.infradead.org/mailman/options/kvm-riscv>,
<mailto:kvm-riscv-request@lists.infradead.org?subject=unsubscribe>
List-Archive: <http://lists.infradead.org/pipermail/kvm-riscv/>
List-Post: <mailto:kvm-riscv@lists.infradead.org>
List-Help: <mailto:kvm-riscv-request@lists.infradead.org?subject=help>
List-Subscribe: <http://lists.infradead.org/mailman/listinfo/kvm-riscv>,
<mailto:kvm-riscv-request@lists.infradead.org?subject=subscribe>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Sender: "kvm-riscv" <kvm-riscv-bounces@lists.infradead.org>
Errors-To: kvm-riscv-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org
|
| Series |
Add crashdump support in guest kernel
|
expand
|
diff --git a/arch/riscv/include/asm/kexec.h b/arch/riscv/include/asm/kexec.h index b9ee8346cc8c..315dce0d9ca6 100644 --- a/arch/riscv/include/asm/kexec.h +++ b/arch/riscv/include/asm/kexec.h @@ -75,4 +75,13 @@ int load_extra_segments(struct kimage *image, unsigned long kernel_start, unsigned long cmdline_len); #endif +#ifndef __ASSEMBLY__ +#ifdef CONFIG_MMU +#define __kexec_tramp_text __section(".kexec.tramp.text") +#else +#define __kexec_tramp_text +#endif +#endif +extern char __kexec_tramp_text_start[]; + #endif diff --git a/arch/riscv/kernel/kexec_relocate.S b/arch/riscv/kernel/kexec_relocate.S index de0a4b35d01e..af6b99f5b0fd 100644 --- a/arch/riscv/kernel/kexec_relocate.S +++ b/arch/riscv/kernel/kexec_relocate.S @@ -147,7 +147,7 @@ riscv_kexec_relocate_end: /* Used for jumping to crashkernel */ -.section ".text" +.section ".kexec.tramp.text", "ax" SYM_CODE_START(riscv_kexec_norelocate) /* * s0: (const) Phys address to jump to