]> git.ipfire.org Git - thirdparty/qemu.git/commit
target/mips: Fix RDHWR CC with icount
authorJames Hogan <james.hogan@imgtec.com>
Wed, 2 Aug 2017 09:59:17 +0000 (10:59 +0100)
committerYongbok Kim <yongbok.kim@imgtec.com>
Wed, 2 Aug 2017 21:18:13 +0000 (22:18 +0100)
commitd673a68db6963e86536b125af464bb6ed03eba33
tree1dbfcc5d36030e5b7219ff85e12a8320862486a9
parent51ca717b079dccae5b6cc9f45153f5044abd34f0
target/mips: Fix RDHWR CC with icount

RDHWR CC reads the CPU timer like MFC0 CP0_Count, so with icount enabled
it must set can_do_io while it calls the helper to avoid the "Bad icount
read" error. It should also break out of the translation loop to ensure
that timer interrupts are immediately handled.

Fixes: 2e70f6efa8b9 ("Add instruction counter.")
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: Aurelien Jarno <aurelien@aurel32.net>
Cc: Yongbok Kim <yongbok.kim@imgtec.com>
Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Yongbok Kim <yongbok.kim@imgtec.com>
target/mips/translate.c