You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
qemu/target/ppc
Denis Sergeev 6c51df580d
target/ppc: use MAKE_64BIT_MASK for mcrfs exception clear mask
In gen_mcrfs() the FPSCR nibble mask is computed as:
      `~((0xF << shift) & FP_EX_CLEAR_BITS)`

Here, 0xF is of type int, so the left shift is performed in
32-bit signed arithmetic. For bfa=0 we get shift=28,
and (0xF << 28) = 0xF0000000, which is not representable as a 32-bit
signed int. Static analyzers flag this as a potential integer
overflow.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Signed-off-by: Denis Sergeev <zeff@altlinux.org>
Reviewed-by: Chinmay Rath <rathc@linux.ibm.com>
Signed-off-by: Harsh Prateek Bora <harshpb@linux.ibm.com>
Link: https://lore.kernel.org/r/20250915080118.29898-1-zeff@altlinux.org
Message-ID: <20250915080118.29898-1-zeff@altlinux.org>
2 weeks ago
..
translate target/ppc: use MAKE_64BIT_MASK for mcrfs exception clear mask 2 weeks ago
Kconfig
arch_dump.c include: Rename sysemu/ -> system/ 10 months ago
compat.c include: Rename sysemu/ -> system/ 10 months ago
cpu-models.c target/ppc: Deprecate Power8E and Power8NVL 2 weeks ago
cpu-models.h target/ppc: IBM PPE42 general regs and flags 2 weeks ago
cpu-param.h tcg: Remove the TCG_GUEST_DEFAULT_MO definition globally 6 months ago
cpu-qom.h
cpu.c include/exec: Split out watchpoint.h 6 months ago
cpu.h target/ppc: IBM PPE42 exception flags and regs 2 weeks ago
cpu_init.c target/ppc: Introduce macro for deprecating PowerPC CPUs 2 weeks ago
cpu_init.h target/ppc: Add Power11 DD2.0 processor 11 months ago
dfp_helper.c target/ppc: replace assert(0) with g_assert_not_reached() 1 year ago
excp_helper.c target/ppc: Add IBM PPE42 exception model 2 weeks ago
fpu_helper.c target/ppc: Move floating-point compare instructions to decodetree. 2 weeks ago
gdbstub.c
helper.h target/ppc: Move floating-point compare instructions to decodetree. 2 weeks ago
helper_regs.c target/ppc: Support for IBM PPE42 MMU 2 weeks ago
helper_regs.h codebase: prepare to remove cpu.h from exec/exec-all.h 6 months ago
insn32.decode target/ppc: Move remaining floating-point move instructions to decodetree. 2 weeks ago
insn64.decode
int_helper.c
internal.h accel/tcg: Move cpu_get_tb_cpu_state to TCGCPUOps 6 months ago
kvm.c target/ppc/kvm: Avoid using alloca() 1 month ago
kvm_ppc.h cleanup: Drop pointless return at end of function 6 months ago
machine.c include: Remove 'exec/exec-all.h' 6 months ago
mem_helper.c accel/tcg: Split out accel/tcg/helper-retaddr.h 6 months ago
meson.build target/ppc: Move TCG specific exception handlers to tcg-excp_helper.c 7 months ago
misc_helper.c hw/ppc: Fix build error with CONFIG_POWERNV disabled 1 month ago
mmu-book3s-v3.c exec/cpu-all: remove system/memory include 6 months ago
mmu-book3s-v3.h target/ppc: Remove includes from mmu-book3s-v3.h 1 year ago
mmu-booke.c
mmu-booke.h
mmu-books.h
mmu-hash32.c include: Remove 'exec/exec-all.h' 6 months ago
mmu-hash32.h exec/cpu-all: remove system/memory include 6 months ago
mmu-hash64.c include: Remove 'exec/exec-all.h' 6 months ago
mmu-hash64.h qemu: Declare all load/store helper in 'qemu/bswap.h' 3 months ago
mmu-radix64.c include: Remove 'exec/exec-all.h' 6 months ago
mmu-radix64.h target/ppc/mmu-radix64: Remove externally unused parts from header 1 year ago
mmu_common.c include: Remove 'exec/exec-all.h' 6 months ago
mmu_helper.c include: Remove 'exec/exec-all.h' 6 months ago
power8-pmu-regs.c.inc
power8-pmu.c include: Remove 'exec/exec-all.h' 6 months ago
power8-pmu.h
ppc-qmp-cmds.c qapi: make most CPU commands unconditionally available 5 months ago
spr_common.h ppc: Enable 2nd DAWR support on Power10 PowerNV machine 7 months ago
tcg-excp_helper.c target/ppc: Add IBM PPE42 exception model 2 weeks ago
tcg-stub.c
timebase_helper.c include: Remove 'exec/exec-all.h' 6 months ago
trace-events
trace.h
translate.c target/ppc: Add IBM PPE42 special instructions 2 weeks ago
user_only_helper.c include: Remove 'exec/exec-all.h' 6 months ago