target/arm: Fix coding style issues in gdbstub code in helper.c
We're going to move this code to a different file; fix the coding style first so checkpatch doesn't complain. This includes deleting the spurious 'break' statements after returns in the vfp_gdb_get_reg() function. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20210921162901.17508-3-peter.maydell@linaro.org
This commit is contained in:
parent
0e2a761104
commit
d59b7cdccc
@ -72,9 +72,12 @@ static int vfp_gdb_get_reg(CPUARMState *env, GByteArray *buf, int reg)
|
||||
}
|
||||
}
|
||||
switch (reg - nregs) {
|
||||
case 0: return gdb_get_reg32(buf, env->vfp.xregs[ARM_VFP_FPSID]); break;
|
||||
case 1: return gdb_get_reg32(buf, vfp_get_fpscr(env)); break;
|
||||
case 2: return gdb_get_reg32(buf, env->vfp.xregs[ARM_VFP_FPEXC]); break;
|
||||
case 0:
|
||||
return gdb_get_reg32(buf, env->vfp.xregs[ARM_VFP_FPSID]);
|
||||
case 1:
|
||||
return gdb_get_reg32(buf, vfp_get_fpscr(env));
|
||||
case 2:
|
||||
return gdb_get_reg32(buf, env->vfp.xregs[ARM_VFP_FPEXC]);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
@ -98,9 +101,15 @@ static int vfp_gdb_set_reg(CPUARMState *env, uint8_t *buf, int reg)
|
||||
}
|
||||
}
|
||||
switch (reg - nregs) {
|
||||
case 0: env->vfp.xregs[ARM_VFP_FPSID] = ldl_p(buf); return 4;
|
||||
case 1: vfp_set_fpscr(env, ldl_p(buf)); return 4;
|
||||
case 2: env->vfp.xregs[ARM_VFP_FPEXC] = ldl_p(buf) & (1 << 30); return 4;
|
||||
case 0:
|
||||
env->vfp.xregs[ARM_VFP_FPSID] = ldl_p(buf);
|
||||
return 4;
|
||||
case 1:
|
||||
vfp_set_fpscr(env, ldl_p(buf));
|
||||
return 4;
|
||||
case 2:
|
||||
env->vfp.xregs[ARM_VFP_FPEXC] = ldl_p(buf) & (1 << 30);
|
||||
return 4;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
@ -119,7 +128,7 @@ static int aarch64_fpu_gdb_get_reg(CPUARMState *env, GByteArray *buf, int reg)
|
||||
return gdb_get_reg32(buf, vfp_get_fpsr(env));
|
||||
case 33:
|
||||
/* FPCR */
|
||||
return gdb_get_reg32(buf,vfp_get_fpcr(env));
|
||||
return gdb_get_reg32(buf, vfp_get_fpcr(env));
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user