aboutsummaryrefslogtreecommitdiff
path: root/qapi
diff options
context:
space:
mode:
authorSong Gao <gaosong@loongson.cn>2023-10-20 16:49:25 +0800
committerSong Gao <gaosong@loongson.cn>2023-11-03 14:13:07 +0800
commit31f694b91188d2077c5d85a5064b54b127635718 (patch)
treeaf0bfe9a2e40e52f1e4809eecd2cfdbc025b2499 /qapi
parent464136ceb65ddebbd60fecd486628cc82fd722ab (diff)
downloadqemu-31f694b91188d2077c5d85a5064b54b127635718.zip
qemu-31f694b91188d2077c5d85a5064b54b127635718.tar.gz
qemu-31f694b91188d2077c5d85a5064b54b127635718.tar.bz2
target/loongarch: Implement query-cpu-model-expansion
Add support for the query-cpu-model-expansion QMP command to LoongArch. We support query the cpu features. e.g la464 and max cpu support LSX/LASX, default enable, la132 not support LSX/LASX. 1. start with '-cpu max,lasx=off' (QEMU) query-cpu-model-expansion type=static model={"name":"max"} {"return": {"model": {"name": "max", "props": {"lasx": false, "lsx": true}}}} 2. start with '-cpu la464,lasx=off' (QEMU) query-cpu-model-expansion type=static model={"name":"la464"} {"return": {"model": {"name": "max", "props": {"lasx": false, "lsx": true}}} 3. start with '-cpu la132,lasx=off' qemu-system-loongarch64: can't apply global la132-loongarch-cpu.lasx=off: Property 'la132-loongarch-cpu.lasx' not found 4. start with '-cpu max,lasx=off' or start with '-cpu la464,lasx=off' query cpu model la132 (QEMU) query-cpu-model-expansion type=static model={"name":"la132"} {"return": {"model": {"name": "la132"}}} Acked-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Song Gao <gaosong@loongson.cn> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20231020084925.3457084-4-gaosong@loongson.cn>
Diffstat (limited to 'qapi')
-rw-r--r--qapi/machine-target.json6
1 files changed, 4 insertions, 2 deletions
diff --git a/qapi/machine-target.json b/qapi/machine-target.json
index 4e55adb..c8d7d98 100644
--- a/qapi/machine-target.json
+++ b/qapi/machine-target.json
@@ -230,7 +230,8 @@
'data': { 'model': 'CpuModelInfo' },
'if': { 'any': [ 'TARGET_S390X',
'TARGET_I386',
- 'TARGET_ARM' ] } }
+ 'TARGET_ARM',
+ 'TARGET_LOONGARCH64' ] } }
##
# @query-cpu-model-expansion:
@@ -275,7 +276,8 @@
'returns': 'CpuModelExpansionInfo',
'if': { 'any': [ 'TARGET_S390X',
'TARGET_I386',
- 'TARGET_ARM' ] } }
+ 'TARGET_ARM',
+ 'TARGET_LOONGARCH64' ] } }
##
# @CpuDefinitionInfo: