f4202fb108 ("i386: Populate AMD Processor Cache Information for cpuid
0x801D")
Signed-off-by: Yanan Wang
---
target/i386/cpu.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 1242bd541a..17c367c5ba 100644
--- a/tar
The pointer assignment "const char *p = path;" in function
qemu_fdt_add_path is unnecessary. Let's remove it and just
use the "path" passed in. No functional change.
Suggested-by: Richard Henderson
Signed-off-by: Yanan Wang
---
Based on: softmmu/device_tree: Sile
Use g_queue APIs to reduce the nested loops and code indentation
with the processor hierarchy levels increasing. Consenquently,
it's more scalable to add new topology level to build_pptt.
No functional change intended.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
hw/acp
List test/data/acpi/virt/PPTT as the expected files allowed to
be changed in tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
Acked-by: Ani Sinha
---
tests/qtest/bios-tables-test-allowed-diff.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/qtest/bios-tables
-0040: 24 00 00 00 00 00 00 00 00 00 00 00 // $...
+0030: 00 00 00 00 00 00 00 00 00 14 00 00 00 00 00 00 //
+0040: 24 00 00 00 00 00 00 00 00 00 00 00 00 14 00 00 // $...
+0050: 0A 00 00 00 38 00 00 00 00 00 00 00 00 00 00 00 /
scheduling
performance improvement from cache affinity of CPU cluster.
So let's enable the support for this new parameter on ARM
virt machines. After this patch, we can define a 4-level
CPU hierarchy like: cpus=*,maxcpus=*,sockets=*,clusters=*,
cores=*,threads=*.
Signed-off-by: Yanan
Support CPU cluster topology level in generation of ACPI
Processor Properties Topology Table (PPTT).
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
hw/acpi/aml-build.c | 18 ++
1 file changed, 18 insertions(+)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
Support one cluster level between core and physical package in the
cpu-map of Arm/virt devicetree. This is also consistent with Linux
Doc "Documentation/devicetree/bindings/cpu/cpu-topology.txt".
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
hw/arm/virt.c | 15 -
part which is in upstream now
- rebased on latest master
- v5: https://patchew.org/QEMU/20211228092221.21068-1-wangyana...@huawei.com/
Yanan Wang (6):
hw/arm/virt: Support CPU cluster on ARM virt machine
hw/arm/virt: Support cluster level in DT cpu-map
hw/acpi/aml-build: Improve scalability of
Support cluster level in generation of ACPI Processor Properties
Topology Table (PPTT) for ARM virt machines.
Signed-off-by: Yanan Wang
---
hw/arm/virt-acpi-build.c | 15 +++
1 file changed, 15 insertions(+)
diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c
index
List test/data/acpi/virt/PPTT as the expected files allowed to
be changed in tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
---
tests/qtest/bios-tables-test-allowed-diff.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/qtest/bios-tables-test-allowed-diff.h
b
0 00 00 00 00 00 00 00 00 00 00 14 00 00 // $...
+0050: 0A 00 00 00 38 00 00 00 00 00 00 00 00 00 00 00 // ....8...
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | Bin 76 -> 96 bytes
tests/qtest/bios-tables-test-allowed-diff.h | 1 -
2 files changed, 1 deletion(-
Support one cluster level between core and physical package in the
cpu-map of Arm/virt devicetree. This is also consistent with Linux
Doc "Documentation/devicetree/bindings/cpu/cpu-topology.txt".
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 15 ---
1 file changed, 8
of build_pptt by reducing
the loops, and intends to make no functional change.
Signed-off-by: Yanan Wang
---
hw/acpi/aml-build.c | 50 +
1 file changed, 32 insertions(+), 18 deletions(-)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index
el through
ACPI PPTT and DT cpu-map.
Changelog:
v5->v6:
- drop the generic part which is in upstream now
- rebased on latest master
- v5: https://patchew.org/QEMU/20211228092221.21068-1-wangyana...@huawei.com/
Yanan Wang (7):
hw/arm/virt: Support CPU cluster on ARM virt machine
hw/arm/
ently only used by ARM, let's just
move build_pptt() from aml-build.c to virt-acpi-build.c with
minor update.
Signed-off-by: Yanan Wang
---
hw/acpi/aml-build.c | 80 ++---
hw/arm/virt-acpi-build.c| 77 ++-
include/hw/a
scheduling
performance improvement from cache affinity of CPU cluster.
So let's enable the support for this new parameter on ARM
virt machines. After this patch, we can define a 4-level
CPU hierarchy like: cpus=*,maxcpus=*,sockets=*,clusters=*,
cores=*,threads=*.
Signed-off-by: Yanan Wang
--
List test/data/acpi/virt/PPTT as the expected files allowed to
be changed in tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
---
tests/qtest/bios-tables-test-allowed-diff.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/qtest/bios-tables-test-allowed-diff.h
b
0 00 00 00 00 00 00 00 00 00 00 14 00 00 // $...
+0050: 0A 00 00 00 38 00 00 00 00 00 00 00 00 00 00 00 // ....8...
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | Bin 76 -> 96 bytes
tests/qtest/bios-tables-test-allowed-diff.h | 1 -
2 files changed, 1 deletion(-
Support cluster level in generation of ACPI Processor Properties
Topology Table (PPTT) for ARM virt machines.
Signed-off-by: Yanan Wang
---
hw/arm/virt-acpi-build.c | 15 +++
1 file changed, 15 insertions(+)
diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c
index
ently only used by ARM, let's just
move build_pptt() from aml-build.c to virt-acpi-build.c with
minor update.
Signed-off-by: Yanan Wang
---
hw/acpi/aml-build.c | 80 ++---
hw/arm/virt-acpi-build.c| 77 ++-
include/hw/a
upport
this new parameter on ARM virt machines.
After this, we can define a 4-level CPU topology hierarchy like:
cpus=*,maxcpus=*,sockets=*,clusters=*,cores=*,threads=*.
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 1 +
qemu-options.hx | 10 ++
2 files changed, 11 insertions(+)
diff
of build_pptt by reducing
the loops, and intends to make no functional change.
Signed-off-by: Yanan Wang
---
hw/acpi/aml-build.c | 50 +
1 file changed, 32 insertions(+), 18 deletions(-)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index
The default value of the MachineClass members is 0, which
means we don't have to explicitly zero them. Also the value
of "mc->smp_props.prefer_sockets" will be taken care of by
smp_parse_test(), we don't necessarily need the statement
in machine_base_class_init() either.
Si
I've built interests in the generic machine subsystem and
have also been working on projects related to this part,
self-recommand myself as a reviewer so that I can help to
review some patches familiar to me, and have a chance to
learn more continuously.
Signed-off-by: Yanan
Support one cluster level between core and physical package in the
cpu-map of Arm/virt devicetree. This is also consistent with Linux
Doc "Documentation/devicetree/bindings/cpu/cpu-topology.txt".
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 15 ---
1 file changed, 8
zation function.
Signed-off-by: Yanan Wang
---
tests/unit/test-smp-parse.c | 16 ++--
1 file changed, 2 insertions(+), 14 deletions(-)
diff --git a/tests/unit/test-smp-parse.c b/tests/unit/test-smp-parse.c
index 72d83d1bbc..fdc39a846c 100644
--- a/tests/unit/test-smp-parse.c
+++ b/test
Wrap the CPU target specific parameters together into a single
variable except generic sockets/cores/threads, to make related
code lines shorter and more concise.
No functional change intended.
Signed-off-by: Yanan Wang
---
hw/core/machine-smp.c | 17 ++---
1 file changed, 10
all the sub-hierarchies currently
supported in QEMU, and correspondingly give an example of
-smp configuration for each of them.
Signed-off-by: Yanan Wang
---
qemu-options.hx | 76 ++---
1 file changed, 59 insertions(+), 17 deletions(-)
dif
Add testcases for parsing of the four-level CPU topology hierarchy,
ie sockets/clusters/cores/threads, which will be supported on ARM
virt machines.
Signed-off-by: Yanan Wang
---
tests/unit/test-smp-parse.c | 130 ++--
1 file changed, 123 insertions(+), 7
ned-off-by: Yanan Wang
---
hw/core/machine-smp.c | 26 +++---
hw/core/machine.c | 3 +++
include/hw/boards.h | 6 +-
qapi/machine.json | 5 -
qemu-options.hx | 7 ---
softmmu/vl.c | 3 +++
6 files changed, 38 insertions(+), 12 deletion
1121122502.9844-1-wangyana...@huawei.com/
Yanan Wang (14):
qemu-options: Improve readability of SMP related Docs
hw/core/machine: Introduce CPU cluster topology support
hw/core/machine: Wrap target specific parameters together
tests/unit/test-smp-parse: Add testcases for CPU clusters
tests/unit/
In terms of scope, die-id should mean "the die number within
socket the CPU belongs to" instead of "the die number within
node/board the CPU belongs to". Fix it to avoid confusing
the Doc reader.
Fixes: 176d2cda0d ("i386/cpu: Consolidate die-id validity in smp context&qu
of build_pptt by reducing
the loops, and intends to make no functional change.
Signed-off-by: Yanan Wang
---
hw/acpi/aml-build.c | 50 +
1 file changed, 32 insertions(+), 18 deletions(-)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index
ently only used by ARM, let's just
move build_pptt() from aml-build.c to virt-acpi-build.c with
minor update.
Signed-off-by: Yanan Wang
---
hw/acpi/aml-build.c | 80 ++---
hw/arm/virt-acpi-build.c| 77 ++-
include/hw/a
List test/data/acpi/virt/PPTT as the expected files allowed to
be changed in tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
---
tests/qtest/bios-tables-test-allowed-diff.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/qtest/bios-tables-test-allowed-diff.h
b
all the sub-hierarchies currently
supported in QEMU, and correspondingly give an example of
-smp configuration for each of them.
Signed-off-by: Yanan Wang
---
qemu-options.hx | 76 ++---
1 file changed, 59 insertions(+), 17 deletions(-)
dif
0 00 00 00 00 00 00 00 00 00 00 14 00 00 // $...
+0050: 0A 00 00 00 38 00 00 00 00 00 00 00 00 00 00 00 // ....8...
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | Bin 76 -> 96 bytes
tests/qtest/bios-tables-test-allowed-diff.h | 1 -
2 files changed, 1 deletion(-
Wrap the CPU target specific parameters together into a single
variable, so that we don't need to update the other lines but
a single line when new topology parameters are introduced.
No functional change intended.
Signed-off-by: Yanan Wang
---
hw/core/machine-smp.c | 17 ++-
ned-off-by: Yanan Wang
---
hw/core/machine-smp.c | 26 +++---
hw/core/machine.c | 3 +++
include/hw/boards.h | 6 +-
qapi/machine.json | 5 -
qemu-options.hx | 7 ---
softmmu/vl.c | 3 +++
6 files changed, 38 insertions(+), 12 deletion
PTT and DT cpu-map.
Changelog:
v3->v4:
- Significant change from v3 to v4, since the whole series is reworked
based on latest QEMU SMP frame.
- v3:
https://lore.kernel.org/qemu-devel/20210516103228.37792-1-wangyana...@huawei.com/
Yanan Wang (10):
qemu-options: Improve readability of SMP rela
Support one cluster level between core and physical package in the
cpu-map of Arm/virt devicetree. This is also consistent with Linux
Doc "Documentation/devicetree/bindings/cpu/cpu-topology.txt".
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 15 ---
1 file changed, 8
Support cluster level in generation of ACPI Processor Properties
Topology Table (PPTT) for ARM virt machines.
Signed-off-by: Yanan Wang
---
hw/arm/virt-acpi-build.c | 15 +++
1 file changed, 15 insertions(+)
diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c
index
upport
this new parameter on ARM virt machines.
After this, we can define a 4-level CPU topology hierarchy like:
cpus=*,maxcpus=*,sockets=*,clusters=*,cores=*,threads=*.
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 1 +
qemu-options.hx | 10 ++
2 files changed, 11 insertions(+)
diff
Checkpatch.pl reports errors like below for commit 9e8e393bb7.
Let's fix it with a simpler format.
ERROR: space required after that close brace '}'
+SMPTestData *data = &(SMPTestData){{ }};
Fixes: 9e8e393bb7 ("tests/unit: Add an unit test for smp parsing&quo
et's rename the tested machine with an unified string and
tweak the expected error messages accordingly.
Fixes: 9e8e393bb7 ("tests/unit: Add an unit test for smp parsing")
Reported-by: Philippe Mathieu-Daudé
Signed-off-by: Yanan Wang
---
tests/unit/test-smp-parse.c | 38
/5823855357853696
History:
v1->v2:
- tweak the structure zero-initialization format from { {0} } to {}
as Markus suggested (patch #2).
Thanks,
Yanan
Yanan Wang (2):
tests/unit/test-smp-parse: Make an unified name for the tested machine
tests/unit/test-smp-parse: Fix a check-patch compl
/5823855357853696
Thanks,
Yanan
Yanan Wang (2):
tests/unit/test-smp-parse: Make an unified name for the tested machine
tests/unit/test-smp-parse: Fix a check-patch complain
tests/unit/test-smp-parse.c | 42 +
1 file changed, 29 insertions(+), 13 deletions
Checkpatch.pl reports errors like below for commit 9e8e393bb7. Fix it.
ERROR: space required after that close brace '}'
+SMPTestData *data = &(SMPTestData){{ }};
Fixes: 9e8e393bb7 ("tests/unit: Add an unit test for smp parsing")
Signed-off-by: Yanan Wang
---
tests/u
et's rename the tested machine with an unified string and
tweak the expected error messages accordingly.
Fixes: 9e8e393bb7 ("tests/unit: Add an unit test for smp parsing")
Reported-by: Philippe Mathieu-Daudé
Signed-off-by: Yanan Wang
---
tests/unit/test-smp-parse.c | 38
Now that we have a generic parser smp_parse(), let's add an unit
test for the code. All possible valid/invalid SMP configurations
that the user can specify are covered.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
MAINTAINERS | 1 +
tests/unit/meson.
separate file, i.e., machine-smp.c and
build it in common field.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
MAINTAINERS | 1 +
hw/core/machine-smp.c | 181 ++
hw/core/machine.c | 159 -
hw/core
ry function and add Andrew's R-b (patch #2)
- v1:
https://lore.kernel.org/qemu-devel/20211010103954.20644-1-wangyana...@huawei.com/
Yanan Wang (2):
hw/core/machine: Split out the smp parsing code
tests/unit: Add an unit test for smp parsing
MAINTAINERS | 2 +
hw/co
m/virt: Add cpu-map to device tree
hw/acpi/aml-build: Add PPTT table
Yanan Wang (6):
hw/arm/virt: Only describe cpu topology since virt-6.2
device_tree: Add qemu_fdt_add_path
hw/acpi/aml-build: Add Processor hierarchy node structure
tests/data/acpi/virt: Add an empty expected file for
sible that an user application
has a dependency on the default topology and if the default one
gets changed it will probably behave differently.
Based on above consideration we'd better only describe topology
information to the guest on 6.2 and later machine types.
Signed-off-by: Yanan Wang
R
ndrew Jones
Co-developed-by: Yanan Wang
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 70 +++
1 file changed, 60 insertions(+), 10 deletions(-)
diff --git a/hw/arm/virt.c b/hw/arm/virt.c
index 15e8d8cf4a..ca433adb5b 100644
--- a/hw/arm/virt.c
++
loped-by: Yanan Wang
Signed-off-by: Yanan Wang
Reviewed-by: Michael S. Tsirkin
---
hw/acpi/aml-build.c | 59 +
include/hw/acpi/aml-build.h | 3 ++
2 files changed, 62 insertions(+)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index 51
Add a generic empty binary file for the new introduced PPTT table
under tests/data/acpi/virt, and list it as files to be changed in
tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
Reviewed-by: Eric Auger
---
tests/data/acpi/virt/PPTT | 0
tests/qtest
0 00 00 00 00 00 00 14 00 00 0A 00 00 00 //
0040: 24 00 00 00 00 00 00 00 00 00 00 00 // $...
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | Bin 0 -> 76 bytes
tests/qtest/bios-tables-test-allowed-diff.h | 1 -
2 files changed, 1 deletion(-
Wang
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Michael S. Tsirkin
Reviewed-by: Eric Auger
---
hw/acpi/aml-build.c | 30 ++
1 file changed, 30 insertions(+)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index 76af0ebaf9..5195324585
Generate the Processor Properties Topology Table (PPTT) for ARM
virt machines supporting it (>= 6.2).
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Eric Auger
---
hw/arm/virt-acpi-build.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/hw/arm/v
ancis
Co-developed-by: Andrew Jones
Signed-off-by: Yanan Wang
Reviewed-by: David Gibson
Reviewed-by: Andrew Jones
---
include/sysemu/device_tree.h | 1 +
softmmu/device_tree.c| 44 ++--
2 files changed, 43 insertions(+), 2 deletions(-)
diff --git a/in
0 00 00 00 00 00 00 14 00 00 0A 00 00 00 //
0040: 24 00 00 00 00 00 00 00 00 00 00 00 // $...
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | Bin 0 -> 76 bytes
tests/qtest/bios-tables-test-allowed-diff.h | 1 -
2 files changed, 1 deletion(-
u-devel/20210824122016.144364-1-wangyana...@huawei.com/
Andrew Jones (2):
hw/arm/virt: Add cpu-map to device tree
hw/acpi/aml-build: Add PPTT table
Yanan Wang (6):
hw/arm/virt: Only describe cpu topology since virt-6.2
device_tree: Add qemu_fdt_add_path
hw/acpi/aml-build: Add Processor hierar
ancis
Co-developed-by: Andrew Jones
Signed-off-by: Yanan Wang
Reviewed-by: David Gibson
Reviewed-by: Andrew Jones
---
include/sysemu/device_tree.h | 1 +
softmmu/device_tree.c| 44 ++--
2 files changed, 43 insertions(+), 2 deletions(-)
diff --git a/in
Add a generic empty binary file for the new introduced PPTT table
under tests/data/acpi/virt, and list it as files to be changed in
tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | 0
tests/qtest/bios-tables-test-allowed
sible that an user application
has a dependency on the default topology and if the default one
gets changed it will probably behave differently.
Based on above consideration we'd better only describe topology
information to the guest on 6.2 and later machine types.
Signed-off-by: Yanan Wang
R
Wang
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Michael S. Tsirkin
---
hw/acpi/aml-build.c | 26 ++
include/hw/acpi/aml-build.h | 4
2 files changed, 30 insertions(+)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index
h the ID-valid flag set, which will be
consistent with MADT.
Signed-off-by: Andrew Jones
Co-developed-by: Yanan Wang
Signed-off-by: Yanan Wang
Reviewed-by: Michael S. Tsirkin
---
hw/acpi/aml-build.c | 60 +
include/hw/acpi/aml-build.h | 3 ++
ndrew Jones
Co-developed-by: Yanan Wang
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 70 +++
1 file changed, 60 insertions(+), 10 deletions(-)
diff --git a/hw/arm/virt.c b/hw/arm/virt.c
index d241516523..f80af19cd3 100644
--- a/hw/arm/virt.c
++
Generate PPTT table for Arm virt machines.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
hw/arm/virt-acpi-build.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c
index 6cec97352b..658a0a5d39 100644
--- a
/
Changelog:
v1->v2:
- split smp_parse out into a separate .c file instead of a header (patch #1)
- dropped an unnecessary function and add Andrew's R-b (patch #2)
- v1:
https://lore.kernel.org/qemu-devel/20211010103954.20644-1-wangyana...@huawei.com/
Yanan Wang (2):
hw/core/machine: Split out
Now that we have a generic parser smp_parse(), let's add an unit
test for the code. All possible valid/invalid SMP configurations
that the user can specify are covered.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
---
MAINTAINERS | 1 +
tests/unit/meson.
separate file, i.e., machine-smp.c and
build it in common field.
Signed-off-by: Yanan Wang
---
MAINTAINERS | 1 +
hw/core/machine-smp.c | 181 ++
hw/core/machine.c | 159 -
hw/core/meson.build | 2
e out
into a separate header as an inline API.
Signed-off-by: Yanan Wang
---
MAINTAINERS | 1 +
hw/core/machine.c | 160 +---
include/hw/core/smp.h | 185 ++
3 files changed, 187 insertions(+), 159 deletions(-)
c
originally posted test is here [2]:
[2]
https://lore.kernel.org/qemu-devel/20210910073025.16480-17-wangyana...@huawei.com/
Compared to [2], the test in this series is reworked and more brief.
Yanan Wang (2):
hw/core/machine: Split out smp_parse as an inline API
tests/unit: Add an unit test
Now that we have a generic parser smp_parse(), let's add an unit
test for the code. All possible valid/invalid SMP configurations
that the user can specify are covered.
Signed-off-by: Yanan Wang
---
MAINTAINERS | 1 +
tests/unit/meson.build | 1 +
tests/unit/tes
id validity in smp context")
Signed-off-by: Yanan Wang
---
hw/core/machine.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/hw/core/machine.c b/hw/core/machine.c
index b8d95eec32..0a23ae3106 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -1157,6 +1157,9 @@ static char
Rewrite part of the -smp documentation in qemu-option.hx,
so that we can easily/clearly extend it with more target
specific CPU topology members introduced in the future.
Signed-off-by: Yanan Wang
---
qemu-options.hx | 90 +++--
1 file changed, 73
Rewrite the comments related to SMP in qapi/machine.json,
so that we can easily/clearly extend it with more target
specific CPU topology members introduced in the future.
Signed-off-by: Yanan Wang
---
qapi/machine.json | 47 ++-
1 file changed, 38
ested in having a look at this. Comments welcome!
Thanks,
Yanan
.
Yanan Wang (3):
qemu-options: Improve scalability of the -smp documentation
include/hw/boards: Improve scalability of the CpuTopology comment
qapi/machine.json: Improve scalability of the SMP related comments
include/hw/boa
Rewrite the comment of struct CpuTopology in include/hw/boards.h,
so that we can easily/clearly extend it with more target specific
CPU topology members introduced in the future.
Signed-off-by: Yanan Wang
---
include/hw/boards.h | 26 ++
1 file changed, 22 insertions
h the ID-valid flag set, which will be
consistent with MADT.
Signed-off-by: Andrew Jones
Co-developed-by: Yanan Wang
Signed-off-by: Yanan Wang
Reviewed-by: Michael S. Tsirkin
---
hw/acpi/aml-build.c | 60 +
include/hw/acpi/aml-build.h | 3 ++
0 00 00 00 00 00 00 14 00 00 0A 00 00 00 //
0040: 24 00 00 00 00 00 00 00 00 00 00 00 // $...
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | Bin 0 -> 76 bytes
tests/data/acpi/virt/PPTT.memhp | Bin 0 -> 76 bytes
tests/data/
ndrew Jones
Co-developed-by: Yanan Wang
Signed-off-by: Yanan Wang
---
hw/arm/virt.c | 70 +++
1 file changed, 60 insertions(+), 10 deletions(-)
diff --git a/hw/arm/virt.c b/hw/arm/virt.c
index d241516523..f80af19cd3 100644
--- a/hw/arm/virt.c
++
Generate PPTT table for Arm virt machines.
Signed-off-by: Yanan Wang
---
hw/arm/virt-acpi-build.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c
index 6cec97352b..658a0a5d39 100644
--- a/hw/arm/virt-acpi-build.c
Add empty binary files for the new introduced PPTT table under
tests/data/acpi/virt, and list them as files to be changed in
tests/qtest/bios-tables-test-allowed-diff.h
Signed-off-by: Yanan Wang
---
tests/data/acpi/virt/PPTT | 0
tests/data/acpi/virt/PPTT.memhp | 0
Wang
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Michael S. Tsirkin
---
hw/acpi/aml-build.c | 26 ++
include/hw/acpi/aml-build.h | 4
2 files changed, 30 insertions(+)
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index
sible that an user application
has a dependency on the default topology and if the default one
gets changed it will probably behave differently.
Based on above consideration we'd better only describe topology
information to the guest on 6.2 and later machine types.
Signed-off-by: Yanan Wang
R
files for PPTT to fix broken bios-table-test for Aarch64
virt machine (patch #6-#8 added)
- v6:
https://lore.kernel.org/qemu-devel/20210824122016.144364-1-wangyana...@huawei.com/
Andrew Jones (2):
hw/arm/virt: Add cpu-map to device tree
hw/acpi/aml-build: Add PPTT table
Yanan Wang (6):
ancis
Co-developed-by: Andrew Jones
Signed-off-by: Yanan Wang
Reviewed-by: David Gibson
Reviewed-by: Andrew Jones
---
include/sysemu/device_tree.h | 1 +
softmmu/device_tree.c| 44 ++--
2 files changed, 43 insertions(+), 2 deletions(-)
diff --git a/in
Now we have a common structure SMPCompatProps used to store information
about SMP compatibility stuff, so we can also move smp_prefer_sockets
there for cleaner code.
No functional change intended.
Signed-off-by: Yanan Wang
Acked-by: David Gibson
Reviewed-by: Andrew Jones
Reviewed-by: Daniel P
Now that all the possible topology parameters are integrated in struct
CpuTopology, tweak the order of topology members to be "cpus/sockets/
dies/cores/threads/maxcpus" for readability and consistency. We also
tweak the comment by adding explanation of dies parameter.
Signed-off-by:
d.
Making smp_parse() generic enough can reduce code duplication and
ease the code maintenance, and also allows extending the topology
with more arch specific members (e.g., clusters) in the future.
Suggested-by: Andrew Jones
Suggested-by: Daniel P. Berrangé
Signed-off-by: Yanan Wang
Reviewed-by
e can more laconically check whether the parsing has
succeeded without touching the errp.
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Yanan Wang
---
hw/core/machine.c | 17 +
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/hw/core/machine.c b/hw/core/machi
Now we have a generic smp parser for all arches, and there will
not be any other arch specific ones, so let's remove the callback
from MachineClass and call the parser directly.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Daniel P. Berrangé
---
hw/core/machine.c
fix a hidden defect by avoiding directly using
the provided *zero value* in the calculation, which could cause
a segment fault (e.g. using dies=0 in the calculation).
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Daniel P. Berrangé
---
hw/core/machine.c |
igs to be valid.
Signed-off-by: Yanan Wang
Reviewed-by: Andrew Jones
Reviewed-by: Daniel P. Berrangé
---
hw/core/machine.c | 29 -
hw/i386/pc.c | 29 -
qemu-options.hx | 11 ---
3 files changed, 40 insertions(+), 29 deletions(-
patch, a boolean "smp_prefer_sockets" is added, and we only
enable the old preference on older machines and enable the new one
since type 6.2 for all arches by using the machine compat mechanism.
Suggested-by: Daniel P. Berrange
Signed-off-by: Yanan Wang
Acked-by: David Gibson
Acked-by
Put both sanity-check of the input SMP configuration and sanity-check
of the output SMP configuration uniformly in the generic parser. Then
machine_set_smp() will become cleaner, also all the invalid scenarios
can be tested only by calling the parser.
Signed-off-by: Yanan Wang
Reviewed-by
1 - 100 of 347 matches
Mail list logo