From nobody Thu Oct 2 11:51:20 2025 Received: from mail.loongson.cn (mail.loongson.cn [114.242.206.163]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 887C12FFF9A for ; Wed, 17 Sep 2025 11:27:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=114.242.206.163 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758108446; cv=none; b=lljQr436MaQ20L8Xv0gR24AO8dzsrmtwUB8xkkZFmGKK14f6Su39NR6hEJbgo6xpXwPQxQ4RUEHWUI+T7Lss+j9wi2WgdAk2P/HapnLfKwjWRTJBb/U1TTJ4JxATUq1EWsO+zq7J+GRTw7RxuOQs/iH4AWJ6R0i5r/B9JdbuMmI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758108446; c=relaxed/simple; bh=YHhlohqdNiMxJQZWF4wsTbW3PDgvPOUakYwjAVijHxQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=O90q4/J58Vq4Y89tcJ0AZb620Pa7d+BZxuMMVgrTYjAfCirnyWhbC979yz/9GaFT/CGW09jtqgH6Gj8N3cA196IEO55QxjDL26LTzFTQKvkfcqLIjZJu9fZb33YEuYzZ3VOJxDekex+JRWKIqnqxqmlUwlwnR2+7QwENi1+t6Bo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=loongson.cn; spf=pass smtp.mailfrom=loongson.cn; arc=none smtp.client-ip=114.242.206.163 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=loongson.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=loongson.cn Received: from loongson.cn (unknown [113.200.148.30]) by gateway (Coremail) with SMTP id _____8Cx5tAYm8poE1kLAA--.24473S3; Wed, 17 Sep 2025 19:27:20 +0800 (CST) Received: from linux.localdomain (unknown [113.200.148.30]) by front1 (Coremail) with SMTP id qMiowJDxQ+QVm8por2abAA--.39884S3; Wed, 17 Sep 2025 19:27:19 +0800 (CST) From: Tiezhu Yang To: Josh Poimboeuf , Peter Zijlstra , Huacai Chen Cc: loongarch@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v3 1/3] objtool/LoongArch: Fix fall through warning about efistub Date: Wed, 17 Sep 2025 19:27:14 +0800 Message-ID: <20250917112716.24415-2-yangtiezhu@loongson.cn> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20250917112716.24415-1-yangtiezhu@loongson.cn> References: <20250917112716.24415-1-yangtiezhu@loongson.cn> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: qMiowJDxQ+QVm8por2abAA--.39884S3 X-CM-SenderInfo: p1dqw3xlh2x3gn0dqz5rrqw2lrqou0/ X-Coremail-Antispam: 1Uk129KBj93XoW7AryrKr1fKry3XrW7tryktFc_yoW8Zr4rpF 45CrWakrZ8WrWkGw18Ja18Wry3Crsxtry7Gry8J3sxA3s0qrnFqr4SkF10vFZrXrnag3WI qay0gryakayqyagCm3ZEXasCq-sJn29KB7ZKAUJUUUUr529EdanIXcx71UUUUU7KY7ZEXa sCq-sGcSsGvfJ3Ic02F40EFcxC0VAKzVAqx4xG6I80ebIjqfuFe4nvWSU5nxnvy29KBjDU 0xBIdaVrnRJUUUvEb4IE77IF4wAFF20E14v26r1j6r4UM7CY07I20VC2zVCF04k26cxKx2 IYs7xG6rWj6s0DM7CIcVAFz4kK6r1Y6r17M28lY4IEw2IIxxk0rwA2F7IY1VAKz4vEj48v e4kI8wA2z4x0Y4vE2Ix0cI8IcVAFwI0_Xr0_Ar1l84ACjcxK6xIIjxv20xvEc7CjxVAFwI 0_Gr0_Cr1l84ACjcxK6I8E87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_ GcCE3s1ln4kS14v26r1Y6r17M2AIxVAIcxkEcVAq07x20xvEncxIr21l57IF6xkI12xvs2 x26I8E6xACxx1l5I8CrVACY4xI64kE6c02F40Ex7xfMcIj6xIIjxv20xvE14v26r126r1D McIj6I8E87Iv67AKxVW8JVWxJwAm72CE4IkC6x0Yz7v_Jr0_Gr1lF7xvr2IYc2Ij64vIr4 1l42xK82IYc2Ij64vIr41l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1l4IxYO2xFxVAFwI0_Jrv_ JF1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17 CE14v26r126r1DMIIYrxkI7VAKI48JMIIF0xvE2Ix0cI8IcVAFwI0_JFI_Gr1lIxAIcVC0 I7IYx2IY6xkF7I0E14v26r1j6r4UMIIF0xvE42xK8VAvwI8IcIk0rVWUJVWUCwCI42IY6I 8E87Iv67AKxVW8JVWxJwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73 UjIFyTuYvjxU466zUUUUU Content-Type: text/plain; charset="utf-8" When compiling with LLVM and CONFIG_LTO_CLANG is set, there exists the following objtool warning: vmlinux.o: warning: objtool: __efistub_efi_boot_kernel() falls through to next function __efistub_exit_boot_func() This is because efi_boot_kernel() doesn't end with a return instruction or an unconditional jump, then objtool has determined that the function can fall through into the next function. At the beginning, try to do something to make efi_boot_kernel() ends with an unconditional jump instruction, but this modification seems not proper and makes LoongArch different to other architectures. Furthermore, it is not proper to link efistub separately for LoongArch, ARM64 and RISC-V too due to there is technical reason why vmlinux.o needs efistub linked in. For example, there are two ways of populating the core kernel's struct screen_info via the stub, the latter is preferred because it makes the EFIFB earlycon available very early, but it only works if the EFI stub is part of the core kernel image itself. For more information, please see the comments in drivers/firmware/efi/libstub/screen_info.c. After more analysis, one simple way is to ignore these efistub functions in validate_branch() of objtool since they are useless for stack unwinder. Signed-off-by: Tiezhu Yang --- tools/objtool/check.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/objtool/check.c b/tools/objtool/check.c index d14f20ef1db1..2dcebf75d95e 100644 --- a/tools/objtool/check.c +++ b/tools/objtool/check.c @@ -3567,6 +3567,10 @@ static int validate_branch(struct objtool_file *file= , struct symbol *func, !strncmp(func->name, "__pfx_", 6)) return 0; =20 + /* Ignore EFISTUB functions which are useless for stack unwinder */ + if (!strncmp(func->name, "__efistub_", 10)) + return 0; + if (file->ignore_unreachables) return 0; =20 --=20 2.42.0 From nobody Thu Oct 2 11:51:20 2025 Received: from mail.loongson.cn (mail.loongson.cn [114.242.206.163]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C062932D5C2 for ; Wed, 17 Sep 2025 11:27:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=114.242.206.163 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758108449; cv=none; b=RFdFOU/80pRENI4U2ri88iCzrE/eFguvmBCi1oWOgOutIUNhcHOrIgNeLwf2bG4bse59siuAz5py+2Du2XG54EyG8mK+DUQud2ffrRhatbTUcWZ9B0hFmo+QKaKBA9VBMGvw4qieZRTxxHb5ZlmMe8aTQy+bJwnFIThDLGHf574= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758108449; c=relaxed/simple; bh=Yhh2ADC9r6JmtVYufkxeK0MbVvfLJkwJDU8kBVyEgIc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=LtY0HT4GBRN+aEs6Pc647fLKIzcJEDkzZlTg9Utd9GPW9cVw4D4+2B2h3zqBDLJVTJ8JLN42rzYMKne0OG6HlCBCdkfgBNWKsX8DxwABuqp+PiUSlVbu/xyjHSOEaG0czViALQx4qKIChD2ZO9M8H5wBnRkBYK0qIjc5b30bLc0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=loongson.cn; spf=pass smtp.mailfrom=loongson.cn; arc=none smtp.client-ip=114.242.206.163 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=loongson.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=loongson.cn Received: from loongson.cn (unknown [113.200.148.30]) by gateway (Coremail) with SMTP id _____8Dx_tIbm8poHlkLAA--.24320S3; Wed, 17 Sep 2025 19:27:23 +0800 (CST) Received: from linux.localdomain (unknown [113.200.148.30]) by front1 (Coremail) with SMTP id qMiowJDxQ+QVm8por2abAA--.39884S4; Wed, 17 Sep 2025 19:27:20 +0800 (CST) From: Tiezhu Yang To: Josh Poimboeuf , Peter Zijlstra , Huacai Chen Cc: loongarch@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v3 2/3] LoongArch: Fix unreachable instruction warnings about head.S Date: Wed, 17 Sep 2025 19:27:15 +0800 Message-ID: <20250917112716.24415-3-yangtiezhu@loongson.cn> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20250917112716.24415-1-yangtiezhu@loongson.cn> References: <20250917112716.24415-1-yangtiezhu@loongson.cn> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: qMiowJDxQ+QVm8por2abAA--.39884S4 X-CM-SenderInfo: p1dqw3xlh2x3gn0dqz5rrqw2lrqou0/ X-Coremail-Antispam: 1Uk129KBj93XoW3JFWUXrykZry8Kr17uw17Arc_yoW7AFWrpF 47C3yDArZ8uF1qvw4UGa1a93yavan8Xr4qqF1UGa4rA3yqv3Z2q3Wvyr17XFyqgw4j9F4r Wr4UKrWqka4jy3cCm3ZEXasCq-sJn29KB7ZKAUJUUUUr529EdanIXcx71UUUUU7KY7ZEXa sCq-sGcSsGvfJ3Ic02F40EFcxC0VAKzVAqx4xG6I80ebIjqfuFe4nvWSU5nxnvy29KBjDU 0xBIdaVrnRJUUUvEb4IE77IF4wAFF20E14v26r1j6r4UM7CY07I20VC2zVCF04k26cxKx2 IYs7xG6rWj6s0DM7CIcVAFz4kK6r1Y6r17M28lY4IEw2IIxxk0rwA2F7IY1VAKz4vEj48v e4kI8wA2z4x0Y4vE2Ix0cI8IcVAFwI0_Xr0_Ar1l84ACjcxK6xIIjxv20xvEc7CjxVAFwI 0_Gr0_Cr1l84ACjcxK6I8E87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_ GcCE3s1ln4kS14v26r1Y6r17M2AIxVAIcxkEcVAq07x20xvEncxIr21l57IF6xkI12xvs2 x26I8E6xACxx1l5I8CrVACY4xI64kE6c02F40Ex7xfMcIj6xIIjxv20xvE14v26r1q6rW5 McIj6I8E87Iv67AKxVW8JVWxJwAm72CE4IkC6x0Yz7v_Jr0_Gr1lF7xvr2IYc2Ij64vIr4 1l42xK82IYc2Ij64vIr41l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1l4IxYO2xFxVAFwI0_Jrv_ JF1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17 CE14v26r126r1DMIIYrxkI7VAKI48JMIIF0xvE2Ix0cI8IcVAFwI0_Gr0_Xr1lIxAIcVC0 I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAvwI8IcIk0rVWUJVWUCwCI42IY6I 8E87Iv67AKxVW8JVWxJwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73 UjIFyTuYvjxU4AhLUUUUU Content-Type: text/plain; charset="utf-8" When compiling with LLVM and CONFIG_LTO_CLANG is set, there exist the following objtool warnings: vmlinux.o: warning: objtool: .head.text+0x0: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x18: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x38: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x3c: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x40: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x44: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x54: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x58: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x6c: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x84: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x94: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x9c: unreachable instruction vmlinux.o: warning: objtool: .head.text+0xc4: unreachable instruction vmlinux.o: warning: objtool: .head.text+0xf8: unreachable instruction vmlinux.o: warning: objtool: .head.text+0xfc: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x104: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x10c: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x11c: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x120: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x124: unreachable instruction vmlinux.o: warning: objtool: .head.text+0x144: unreachable instruction vmlinux.o: warning: objtool: kernel_entry+0x0: unreachable instruction vmlinux.o: warning: objtool: smpboot_entry+0x0: unreachable instruction All of the above instructions are in arch/loongarch/kernel/head.S, and there is "OBJECT_FILES_NON_STANDARD_head.o :=3D y" in Makefile to skip objtool checking for head.o, but OBJECT_FILES_NON_STANDARD does not work for link time validation of vmlinux.o according to tools/objtool/Documentation/objtool.txt. After many discussions, it is not proper to ignore .head.text section in objtool or put them from text section to data section, so just give UNWIND_HINT_UNDEFINED to fix the warnings in the image header and also give UNWIND_HINT_END_OF_STACK to fix the warnings in the entry points. By the way, ASM_BUG() can be removed due to unnecessary, otherwise there are following warnings: kernel_entry+0xf4: start_kernel() missing __noreturn in .c/.h or NORETURN() in noreturns.h smpboot_entry+0x68: start_secondary() missing __noreturn in .c/.h or NORETURN() in noreturns.h This is because the previous instructions of kernel_entry+0xf4 and smpboot_entry+0x68 are the 'bl' instructions, start_kernel() and start_secondary() are the respective call destination symbols which are noreturn functions, then the 'bl' instructions are already marked as dead end in annotate_call_site(). For now, it is time to remove "OBJECT_FILES_NON_STANDARD_head.o :=3D y" in arch/loongarch/kernel/Makefile. Link: https://lore.kernel.org/lkml/20250814083651.GR4067720@noisy.programmi= ng.kicks-ass.net/ Link: https://lore.kernel.org/lkml/CAAhV-H6A_swQmqpWHp6ryAEvc96CAMOMd2ZGyJE= VNMsJfLkz6w@mail.gmail.com/ Suggested-by: Peter Zijlstra Suggested-by: Huacai Chen Signed-off-by: Tiezhu Yang --- arch/loongarch/kernel/Makefile | 2 -- arch/loongarch/kernel/head.S | 7 +++---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/arch/loongarch/kernel/Makefile b/arch/loongarch/kernel/Makefile index 6f5a4574a911..4302c5b0a201 100644 --- a/arch/loongarch/kernel/Makefile +++ b/arch/loongarch/kernel/Makefile @@ -3,8 +3,6 @@ # Makefile for the Linux/LoongArch kernel. # =20 -OBJECT_FILES_NON_STANDARD_head.o :=3D y - always-$(KBUILD_BUILTIN) :=3D vmlinux.lds =20 obj-y +=3D head.o cpu-probe.o cacheinfo.o env.o setup.o entry.o genex.o \ diff --git a/arch/loongarch/kernel/head.S b/arch/loongarch/kernel/head.S index e3865e92a917..c62dab32a06b 100644 --- a/arch/loongarch/kernel/head.S +++ b/arch/loongarch/kernel/head.S @@ -20,6 +20,7 @@ __HEAD =20 _head: + UNWIND_HINT_UNDEFINED .word IMAGE_DOS_SIGNATURE /* "MZ", MS-DOS header */ .org 0x8 .dword _kernel_entry /* Kernel entry point (physical address) */ @@ -42,6 +43,7 @@ SYM_DATA(kernel_fsize, .long _kernel_fsize); .align 12 =20 SYM_CODE_START(kernel_entry) # kernel entry point + UNWIND_HINT_END_OF_STACK =20 /* Config direct window and set PG */ SETUP_DMWINS t0 @@ -109,8 +111,6 @@ SYM_CODE_START(kernel_entry) # kernel entry point #endif =20 bl start_kernel - ASM_BUG() - SYM_CODE_END(kernel_entry) =20 #ifdef CONFIG_SMP @@ -120,6 +120,7 @@ SYM_CODE_END(kernel_entry) * function after setting up the stack and tp registers. */ SYM_CODE_START(smpboot_entry) + UNWIND_HINT_END_OF_STACK =20 SETUP_DMWINS t0 JUMP_VIRT_ADDR t0, t1 @@ -142,8 +143,6 @@ SYM_CODE_START(smpboot_entry) ld.d tp, t0, CPU_BOOT_TINFO =20 bl start_secondary - ASM_BUG() - SYM_CODE_END(smpboot_entry) =20 #endif /* CONFIG_SMP */ --=20 2.42.0 From nobody Thu Oct 2 11:51:20 2025 Received: from mail.loongson.cn (mail.loongson.cn [114.242.206.163]) by smtp.subspace.kernel.org (Postfix) with ESMTP id ED455309DD2 for ; Wed, 17 Sep 2025 11:27:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=114.242.206.163 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758108447; cv=none; b=EFp7L6CcjZuVmE7fEbEA875CAmlwRVFxzB4g6j00IWRFZraEZARyEpeYtB2IexevZ1JTBil7XrALkjSqos/VIIO+wWYtKA71BZGZeSyhYP3XUbGCrwDo1PJINV4jh7qO/kD6eLORW8qd+m+0mq5kcOTeER+fk37y39U461O1OFg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1758108447; c=relaxed/simple; bh=5xt4C80mQGWhGn4QWQy8RJCY75EMFYpXXeicgnELsmI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Gw3Cs8qlXBaRnxjVy9ClMXLcSjvx7bBbsdKxgYyA9HVQ0fH3fT4BZi9ZrYpyQPWSi2UC6CR9RRd9Qzr3VVWdOjV9xmMqTEHvvf5yGBF7kEHX3BxUvlwyqwUYRg3UE9husoKy4hDe0avrA1d7WjBsd05SGzzkT3Sh6ktHnukfRig= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=loongson.cn; spf=pass smtp.mailfrom=loongson.cn; arc=none smtp.client-ip=114.242.206.163 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=loongson.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=loongson.cn Received: from loongson.cn (unknown [113.200.148.30]) by gateway (Coremail) with SMTP id _____8CxK9Iam8poHVkLAA--.23130S3; Wed, 17 Sep 2025 19:27:22 +0800 (CST) Received: from linux.localdomain (unknown [113.200.148.30]) by front1 (Coremail) with SMTP id qMiowJDxQ+QVm8por2abAA--.39884S5; Wed, 17 Sep 2025 19:27:21 +0800 (CST) From: Tiezhu Yang To: Josh Poimboeuf , Peter Zijlstra , Huacai Chen Cc: loongarch@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v3 3/3] LoongArch: Remove is_entry_func() related code Date: Wed, 17 Sep 2025 19:27:16 +0800 Message-ID: <20250917112716.24415-4-yangtiezhu@loongson.cn> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20250917112716.24415-1-yangtiezhu@loongson.cn> References: <20250917112716.24415-1-yangtiezhu@loongson.cn> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: qMiowJDxQ+QVm8por2abAA--.39884S5 X-CM-SenderInfo: p1dqw3xlh2x3gn0dqz5rrqw2lrqou0/ X-Coremail-Antispam: 1Uk129KBj93XoWxJryDCFW8Xr1rAF4rur15GFX_yoW8Gw15pF 9xAwnrWrWFv3s2g34DXw1j9rWDZrn7XrnFgFZrKFyrW3Zrt3W3Cr1Fvw1j9FZ0y3yrWF1r XFnak3s0ka1DZ3XCm3ZEXasCq-sJn29KB7ZKAUJUUUUr529EdanIXcx71UUUUU7KY7ZEXa sCq-sGcSsGvfJ3Ic02F40EFcxC0VAKzVAqx4xG6I80ebIjqfuFe4nvWSU5nxnvy29KBjDU 0xBIdaVrnRJUUUvEb4IE77IF4wAFF20E14v26r1j6r4UM7CY07I20VC2zVCF04k26cxKx2 IYs7xG6rWj6s0DM7CIcVAFz4kK6r126r13M28lY4IEw2IIxxk0rwA2F7IY1VAKz4vEj48v e4kI8wA2z4x0Y4vE2Ix0cI8IcVAFwI0_Xr0_Ar1l84ACjcxK6xIIjxv20xvEc7CjxVAFwI 0_Gr0_Cr1l84ACjcxK6I8E87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_ GcCE3s1ln4kS14v26r1Y6r17M2AIxVAIcxkEcVAq07x20xvEncxIr21l57IF6xkI12xvs2 x26I8E6xACxx1l5I8CrVACY4xI64kE6c02F40Ex7xfMcIj6xIIjxv20xvE14v26r1q6rW5 McIj6I8E87Iv67AKxVW8JVWxJwAm72CE4IkC6x0Yz7v_Jr0_Gr1lF7xvr2IYc2Ij64vIr4 1l42xK82IYc2Ij64vIr41l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1l4IxYO2xFxVAFwI0_Jrv_ JF1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17 CE14v26r126r1DMIIYrxkI7VAKI48JMIIF0xvE2Ix0cI8IcVAFwI0_Gr0_Xr1lIxAIcVC0 I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAvwI8IcIk0rVWUJVWUCwCI42IY6I 8E87Iv67AKxVW8JVWxJwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIYCTnIWIevJa73 UjIFyTuYvjxU4OzVUUUUU Content-Type: text/plain; charset="utf-8" For now, there is UNWIND_HINT_END_OF_STACK for the entry points kernel_entry() and smpboot_entry(), just remove is_entry_func() related code. Link: https://lore.kernel.org/lkml/kjiyla6qj3l7ezspitulrdoc5laj2e6hoecvd254= hssnpddczm@g6nkaombh6va/ Suggested-by: Josh Poimboeuf Signed-off-by: Tiezhu Yang --- arch/loongarch/kernel/unwind_orc.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/arch/loongarch/kernel/unwind_orc.c b/arch/loongarch/kernel/unw= ind_orc.c index 0d5fa64a2225..710f82d73797 100644 --- a/arch/loongarch/kernel/unwind_orc.c +++ b/arch/loongarch/kernel/unwind_orc.c @@ -348,14 +348,6 @@ void unwind_start(struct unwind_state *state, struct t= ask_struct *task, } EXPORT_SYMBOL_GPL(unwind_start); =20 -static bool is_entry_func(unsigned long addr) -{ - extern u32 kernel_entry; - extern u32 kernel_entry_end; - - return addr >=3D (unsigned long)&kernel_entry && addr < (unsigned long)&k= ernel_entry_end; -} - static inline unsigned long bt_address(unsigned long ra) { extern unsigned long eentry; @@ -402,9 +394,6 @@ bool unwind_next_frame(struct unwind_state *state) /* Don't let modules unload while we're reading their ORC data. */ guard(rcu)(); =20 - if (is_entry_func(state->pc)) - goto end; - orc =3D orc_find(state->pc); if (!orc) { /* --=20 2.42.0