[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFC 3/3] target-i386: add qmp command 'query-cpus' to disp
|
From: |
Chen Fan |
|
Subject: |
[Qemu-devel] [RFC 3/3] target-i386: add qmp command 'query-cpus' to display apic_id |
|
Date: |
Tue, 14 Jan 2014 17:27:22 +0800 |
this patch provided the apic_id display as using command 'query-cpus'.
Signed-off-by: Chen Fan <address@hidden>
---
cpus.c | 1 +
qapi-schema.json | 4 +++-
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/cpus.c b/cpus.c
index ca4c59f..e6ed098 100644
--- a/cpus.c
+++ b/cpus.c
@@ -1351,6 +1351,7 @@ CpuInfoList *qmp_query_cpus(Error **errp)
#if defined(TARGET_I386)
info->value->has_pc = true;
info->value->pc = env->eip + env->segs[R_CS].base;
+ info->value->apic_id = env->cpuid_apic_id;
#elif defined(TARGET_PPC)
info->value->has_nip = true;
info->value->nip = env->nip;
diff --git a/qapi-schema.json b/qapi-schema.json
index c3c939c..40c67ac 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -783,6 +783,8 @@
#
# @thread_id: ID of the underlying host thread
#
+# @apic_id: the apic id of the virtual CPU
+#
# Since: 0.14.0
#
# Notes: @halted is a transient state that changes frequently. By the time the
@@ -790,7 +792,7 @@
##
{ 'type': 'CpuInfo',
'data': {'CPU': 'int', 'current': 'bool', 'halted': 'bool', '*pc': 'int',
- '*nip': 'int', '*npc': 'int', '*PC': 'int', 'thread_id': 'int'} }
+ '*nip': 'int', '*npc': 'int', '*PC': 'int', 'thread_id': 'int',
'apic_id': 'int'} }
##
# @query-cpus:
--
1.8.1.4
- [Qemu-devel] [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn(), (continued)
- [Qemu-devel] [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn(), Chen Fan, 2014/01/14
- Re: [Qemu-devel] [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn(), Igor Mammedov, 2014/01/14
- Re: [Qemu-devel] [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn(), Chen Fan, 2014/01/15
- Re: [Qemu-devel] [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn(), Igor Mammedov, 2014/01/15
- [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn()), Eduardo Habkost, 2014/01/17
- Re: [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn()), Igor Mammedov, 2014/01/20
- Re: [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn()), Chen Fan, 2014/01/21
- Re: [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn()), Igor Mammedov, 2014/01/21
- Re: [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn()), Chen Fan, 2014/01/21
- Re: [Qemu-devel] Exposing and calculating CPU APIC IDs (was Re: [RFC 1/3] target-i386: moving registers of vmstate from cpu_exec_init() to x86_cpu_realizefn()), Andreas Färber, 2014/01/21
[Qemu-devel] [RFC 3/3] target-i386: add qmp command 'query-cpus' to display apic_id,
Chen Fan <=
[Qemu-devel] [RFC 2/3] target-i386: add -smp X,apics=0x option, Chen Fan, 2014/01/14