From e7eee62a90c671d22d50964b7de05e3f4fd96f5f Mon Sep 17 00:00:00 2001 From: Max Filippov Date: Wed, 22 Aug 2012 22:03:35 +0400 Subject: target-xtensa: return ENOSYS for unimplemented simcalls This prevents guest from proceeding with uninitialised garbage returned from unimplemented simcalls. Signed-off-by: Max Filippov Signed-off-by: Blue Swirl --- target-xtensa/xtensa-semi.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'target-xtensa/xtensa-semi.c') diff --git a/target-xtensa/xtensa-semi.c b/target-xtensa/xtensa-semi.c index 1c8a19ed56..6d001c2c1a 100644 --- a/target-xtensa/xtensa-semi.c +++ b/target-xtensa/xtensa-semi.c @@ -218,6 +218,8 @@ void HELPER(simcall)(CPUXtensaState *env) default: qemu_log("%s(%d): not implemented\n", __func__, regs[2]); + regs[2] = -1; + regs[3] = ENOSYS; break; } } -- cgit v1.2.3