[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 05/19] target/m68k: Fix coding style in m68k_interrupt_all
From: |
Laurent Vivier |
Subject: |
[PULL 05/19] target/m68k: Fix coding style in m68k_interrupt_all |
Date: |
Thu, 2 Jun 2022 13:58:23 +0200 |
From: Richard Henderson <richard.henderson@linaro.org>
Add parenthesis around & vs &&.
Remove assignment to sr in function call argument -- note that
sr is unused after the call, so the assignment was never needed,
only the result of the & expression.
Suggested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Laurent Vivier <laurent@vivier.eu>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20220602013401.303699-4-richard.henderson@linaro.org>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
---
target/m68k/op_helper.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/target/m68k/op_helper.c b/target/m68k/op_helper.c
index 2b94a6ec84de..0f41c2dce3cc 100644
--- a/target/m68k/op_helper.c
+++ b/target/m68k/op_helper.c
@@ -408,11 +408,11 @@ static void m68k_interrupt_all(CPUM68KState *env, int
is_hw)
break;
case EXCP_SPURIOUS ... EXCP_INT_LEVEL_7:
- if (is_hw && oldsr & SR_M) {
+ if (is_hw && (oldsr & SR_M)) {
do_stack_frame(env, &sp, 0, oldsr, 0, retaddr);
oldsr = sr;
env->aregs[7] = sp;
- cpu_m68k_set_sr(env, sr &= ~SR_M);
+ cpu_m68k_set_sr(env, sr & ~SR_M);
sp = env->aregs[7];
if (!m68k_feature(env, M68K_FEATURE_UNALIGNED_DATA)) {
sp &= ~1;
--
2.36.1
- [PULL 03/19] target/m68k: Raise the TRAPn exception with the correct pc, (continued)
- [PULL 03/19] target/m68k: Raise the TRAPn exception with the correct pc, Laurent Vivier, 2022/06/02
- [PULL 07/19] target/m68k: Remove retaddr in m68k_interrupt_all, Laurent Vivier, 2022/06/02
- [PULL 08/19] target/m68k: Fix address argument for EXCP_CHK, Laurent Vivier, 2022/06/02
- [PULL 18/19] linux-user/strace: Adjust get_thread_area for m68k, Laurent Vivier, 2022/06/02
- [PULL 12/19] target/m68k: Implement TRAPcc, Laurent Vivier, 2022/06/02
- [PULL 14/19] target/m68k: Implement TRAPV, Laurent Vivier, 2022/06/02
- [PULL 15/19] target/m68k: Implement FTRAPcc, Laurent Vivier, 2022/06/02
- [PULL 16/19] tests/tcg/m68k: Add trap.c, Laurent Vivier, 2022/06/02
- [PULL 09/19] target/m68k: Fix pc, c flag, and address argument for EXCP_DIV0, Laurent Vivier, 2022/06/02
- [PULL 11/19] target/m68k: Fix stack frame for EXCP_ILLEGAL, Laurent Vivier, 2022/06/02
- [PULL 05/19] target/m68k: Fix coding style in m68k_interrupt_all,
Laurent Vivier <=
- [PULL 10/19] target/m68k: Fix address argument for EXCP_TRACE, Laurent Vivier, 2022/06/02
- [PULL 13/19] target/m68k: Implement TPF in terms of TRAPcc, Laurent Vivier, 2022/06/02
- [PULL 17/19] linux-user/strace: Use is_error in print_syscall_err, Laurent Vivier, 2022/06/02
- [PULL 19/19] target/m68k: Mark helper_raise_exception as noreturn, Laurent Vivier, 2022/06/02
- Re: [PULL 00/19] M68k for 7.1 patches, Richard Henderson, 2022/06/02