提交 99b7796f 编写于 作者: L Luiz Capitulino

Monitor: Introduce monitor_get_cpu_index()

Returns 'cur_mons's CPU index. A future commit will use it.
Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
上级 b025c8b4
......@@ -794,6 +794,11 @@ static CPUState *mon_get_cpu(void)
return cur_mon->mon_cpu;
}
int monitor_get_cpu_index(void)
{
return mon_get_cpu()->cpu_index;
}
static void do_info_registers(Monitor *mon)
{
CPUState *env;
......
......@@ -58,6 +58,7 @@ void monitor_printf(Monitor *mon, const char *fmt, ...) GCC_FMT_ATTR(2, 3);
void monitor_print_filename(Monitor *mon, const char *filename);
void monitor_flush(Monitor *mon);
int monitor_set_cpu(int cpu_index);
int monitor_get_cpu_index(void);
typedef void (MonitorCompletion)(void *opaque, QObject *ret_data);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册