aboutsummaryrefslogtreecommitdiff
path: root/target-i386/cpu.h
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2014-11-12 12:16:58 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2014-11-13 16:13:27 +0100
commite6a33e45c270ea024929f4afb49283d610577af3 (patch)
tree00cbaf9a21e262b154fa52171527deaea1ae4805 /target-i386/cpu.h
parentc2c00148ec54f77c9432fec16585834e1d677fda (diff)
downloadqemu-e6a33e45c270ea024929f4afb49283d610577af3.zip
qemu-e6a33e45c270ea024929f4afb49283d610577af3.tar.gz
qemu-e6a33e45c270ea024929f4afb49283d610577af3.tar.bz2
target-i386: fix Coverity complaints about overflows
sipi_vector is an int; it is shifted by 12 and passed as a 64-bit value, which makes Coverity think that we wanted (uint64_t)sipi_vector << 12. But actually it must be between 0 and 255. Make this explicit. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target-i386/cpu.h')
-rw-r--r--target-i386/cpu.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/target-i386/cpu.h b/target-i386/cpu.h
index 1b2c12a..015f5b5 100644
--- a/target-i386/cpu.h
+++ b/target-i386/cpu.h
@@ -1104,7 +1104,7 @@ static inline void cpu_x86_load_seg_cache(CPUX86State *env,
}
static inline void cpu_x86_load_seg_cache_sipi(X86CPU *cpu,
- int sipi_vector)
+ uint8_t sipi_vector)
{
CPUState *cs = CPU(cpu);
CPUX86State *env = &cpu->env;