qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH for-1.2 v2] target-xtensa: return ENOSYS for unimplemented simcalls
@ 2012-08-22 18:03 Max Filippov
  2012-08-29  9:32 ` Max Filippov
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Max Filippov @ 2012-08-22 18:03 UTC (permalink / raw)
  To: qemu-devel; +Cc: Max Filippov

This prevents guest from proceeding with uninitialised garbage returned
from unimplemented simcalls.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
---
 target-xtensa/xtensa-semi.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/target-xtensa/xtensa-semi.c b/target-xtensa/xtensa-semi.c
index 1c8a19e..6d001c2 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;
     }
 }
-- 
1.7.7.6

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-09-01 11:36 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-22 18:03 [Qemu-devel] [PATCH for-1.2 v2] target-xtensa: return ENOSYS for unimplemented simcalls Max Filippov
2012-08-29  9:32 ` Max Filippov
2012-08-29  9:38 ` Peter Maydell
2012-08-29 10:13   ` Max Filippov
2012-08-29 10:34     ` Peter Maydell
2012-08-29 10:54       ` Max Filippov
2012-09-01 11:36 ` Blue Swirl

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).