qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Get current env within io_handler ?


From: nicolas.sauzede
Subject: [Qemu-devel] Get current env within io_handler ?
Date: Tue, 15 May 2012 17:12:46 +0200

Hi list,

I've implemented a way to link a qemu instance (arm) to a running TLM simulation.
That allows me to use qemu-system-arm as a minimal ARM ISS without any hardware device implemented within qemu,
all the peripherals are implemented in the TLM simulation.
This works by entering the TLM world when called back in the io_handlers.

This works fine for uniprocessor mode.
But when trying smp mode, I can't manage to retrieve the current env (ie: current smp processor number, registers, etc..),
because it seems like the "cpu_single_env" variable is set to NULL explicitly in cpu-exec.c :
     /* fail safe : never use cpu_single_env outside cpu_exec() */
     cpu_single_env = NULL;
     return ret;
 }

Is this intentional ? Would it be very bad to get access to the current env in io_handler ? (it works if commenting out "cpu_single_env = NULL;")

Thanks by advance,
NS.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]