diff options
| author | Alistair Francis | 2016-12-27 15:59:22 +0100 |
|---|---|---|
| committer | Peter Maydell | 2016-12-27 15:59:22 +0100 |
| commit | 450aaae8638e4c75ac6547ce6e09d63281a5a925 (patch) | |
| tree | 4edb7705b6150b2bfcfd7c9195e3282970b577ea /target | |
| parent | Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (diff) | |
| download | qemu-450aaae8638e4c75ac6547ce6e09d63281a5a925.tar.gz qemu-450aaae8638e4c75ac6547ce6e09d63281a5a925.tar.xz qemu-450aaae8638e4c75ac6547ce6e09d63281a5a925.zip | |
cadence_uart: Check baud rate generator and divider values on migration
The Cadence UART device emulator calculates speed by dividing the
baud rate by a 'baud rate generator' & 'baud rate divider' value.
The device specification defines these register values to be
non-zero and within certain limits. Checks were recently added when
writing to these registers but not when restoring from migration.
This patch adds checks when restoring from migration to avoid divide by
zero errors.
Reported-by: Huawei PSIRT <psirt@huawei.com>
Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
Message-id: 04ae30ed8ee1758cd2d2af880da4d28f74c67738.1481132150.git.alistair.francis@xilinx.com
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target')
0 files changed, 0 insertions, 0 deletions
