From: Stephen Zhang <starzhangzsd@gmail.com>
To: tsbogend@alpha.franken.de, liam.howlett@oracle.com,
ebiederm@xmission.com, dbueso@suse.de, alobakin@pm.me,
f.fainelli@gmail.com
Cc: zhangshida@kylinos.cn, starzhangzsd@gmail.com,
linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org
Subject: [PATCH] arch/mips/kernel/traps: add CONFIG_MIPS_FP_SUPPORT when using handle_fpe
Date: Tue, 26 Apr 2022 16:32:59 +0800 [thread overview]
Message-ID: <20220426083259.526685-1-starzhangzsd@gmail.com> (raw)
From: Shida Zhang <zhangshida@kylinos.cn>
handle_fpe gets defined when CONFIG_MIPS_FP_SUPPORT is defined. So add
CONFIG_MIPS_FP_SUPPORT when using handle_fpe.
Signed-off-by: Shida Zhang <zhangshida@kylinos.cn>
---
arch/mips/kernel/traps.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
index 246c6a6b0261..ef9792261f91 100644
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -90,7 +90,9 @@ extern asmlinkage void handle_cpu(void);
extern asmlinkage void handle_ov(void);
extern asmlinkage void handle_tr(void);
extern asmlinkage void handle_msa_fpe(void);
+#ifdef CONFIG_MIPS_FP_SUPPORT
extern asmlinkage void handle_fpe(void);
+#endif
extern asmlinkage void handle_ftlb(void);
extern asmlinkage void handle_gsexc(void);
extern asmlinkage void handle_msa(void);
@@ -2489,8 +2491,10 @@ void __init trap_init(void)
if (board_nmi_handler_setup)
board_nmi_handler_setup();
+#ifdef CONFIG_MIPS_FP_SUPPORT
if (cpu_has_fpu && !cpu_has_nofpuex)
set_except_vector(EXCCODE_FPE, handle_fpe);
+#endif
if (cpu_has_ftlbparex)
set_except_vector(MIPS_EXCCODE_TLBPAR, handle_ftlb);
--
2.30.2
next reply other threads:[~2022-04-26 8:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-26 8:32 Stephen Zhang [this message]
2022-04-27 0:40 ` [PATCH] arch/mips/kernel/traps: add CONFIG_MIPS_FP_SUPPORT when using handle_fpe Maciej W. Rozycki
2022-04-27 1:57 ` Stephen Zhang
2022-04-27 10:57 ` Maciej W. Rozycki
[not found] ` <CANubcdUPQJcJ=dryJGsnQLhjcTouLUARD-GwCd7UjurUm+-GXg@mail.gmail.com>
2022-04-28 9:00 ` Maciej W. Rozycki
2022-04-29 3:10 ` Stephen Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220426083259.526685-1-starzhangzsd@gmail.com \
--to=starzhangzsd@gmail.com \
--cc=alobakin@pm.me \
--cc=dbueso@suse.de \
--cc=ebiederm@xmission.com \
--cc=f.fainelli@gmail.com \
--cc=liam.howlett@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=tsbogend@alpha.franken.de \
--cc=zhangshida@kylinos.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox