summaryrefslogtreecommitdiffstats
path: root/hw/timer/exynos4210_mct.c
diff options
context:
space:
mode:
authorPrasad J Pandit2016-10-24 17:26:55 +0200
committerPeter Maydell2016-10-24 17:26:55 +0200
commit84da15169b45f7080e4b1b32f70e68e726e02740 (patch)
treef491891e29e296bc46b8facb4a590ba7537b664c /hw/timer/exynos4210_mct.c
parenti2c: Fix SMBus read transactions to avoid double events (diff)
downloadqemu-84da15169b45f7080e4b1b32f70e68e726e02740.tar.gz
qemu-84da15169b45f7080e4b1b32f70e68e726e02740.tar.xz
qemu-84da15169b45f7080e4b1b32f70e68e726e02740.zip
timer: stm32f2xx_timer: add check for prescaler value
The STM32F2XX Timer emulator uses a 16 bit prescaler value to limit the timer clock rate. It does that by dividing the timer frequency. If the prescaler 's->tim_psc' was set to be UINT_MAX, it'd lead to divide by zero error. Limit prescaler value to 16 bits to avoid it. Reported-by: Huawei PSIRT <psirt@huawei.com> Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org> Message-id: 1476800269-31902-1-git-send-email-ppandit@redhat.com Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/timer/exynos4210_mct.c')
0 files changed, 0 insertions, 0 deletions