Skip to contentSkip to conversation

tests: pc: acpi: piix4: add sparse CPU hotplug case

PATCH In review Igor Mammedov 2 participants 2 messages Mar 14, 2016

lore
Share & tools
lore
#0 lore raw

PATCH v6 1/1 tests: pc: acpi: piix4: add sparse CPU hotplug case

---
- rebased on top of todays PCI tree to match
modified tables

---
 tests/acpi-test-data/pc/APIC.cpuhp_sparse | Bin 0 -> 160 bytes
 tests/acpi-test-data/pc/DSDT.cpuhp_sparse | Bin 0 -> 5930 bytes
 tests/acpi-test-data/pc/SRAT.cpuhp_sparse | Bin 0 -> 264 bytes
 tests/bios-tables-test.c                  |  16 ++++++++++++++++
 4 files changed, 16 insertions(+)
 create mode 100644 tests/acpi-test-data/pc/APIC.cpuhp_sparse
 create mode 100644 tests/acpi-test-data/pc/DSDT.cpuhp_sparse
 create mode 100644 tests/acpi-test-data/pc/SRAT.cpuhp_sparse
tests/acpi-test-data/pc/APIC.cpuhp_sparse new file binary +0 -0
new file mode 100644
index 0000000000000000000000000000000000000000..67918d51b7b7fbd26aff57802b3cf358864fb36a
GIT binary patch
tests/acpi-test-data/pc/DSDT.cpuhp_sparse new file binary +0 -0
new file mode 100644
index 0000000000000000000000000000000000000000..c8ce867d6d241b76ecef1e1fc322b68390a23bee
GIT binary patch
tests/acpi-test-data/pc/SRAT.cpuhp_sparse new file binary +0 -0
new file mode 100644
index 0000000000000000000000000000000000000000..8deeaee3bde46a891d8946b21368c4cef55d7d4f
GIT binary patch
tests/bios-tables-test.c +16 -0
index 0a80ddf..15fa3c9 100644
@@ -781,6 +781,20 @@ static void test_acpi_q35_tcg_bridge(void)
     free_test_data(&data);
 }
 
+static void test_acpi_piix4_tcg_cpuhp_sparse(void)
+{
+    test_data data;
+
+    memset(&data, 0, sizeof(data));
+    data.machine = MACHINE_PC;
+    data.variant = ".cpuhp_sparse";
+    test_acpi_one("-machine accel=tcg"
+                  " -numa node -smp 1,sockets=2,cores=3,maxcpus=6",
+                  &data);
+    free_test_data(&data);
+}
+
+
 int main(int argc, char *argv[])
 {
     const char *arch = qtest_get_arch();
@@ -797,6 +811,8 @@ int main(int argc, char *argv[])
         qtest_add_func("acpi/piix4/tcg/bridge", test_acpi_piix4_tcg_bridge);
         qtest_add_func("acpi/q35/tcg", test_acpi_q35_tcg);
         qtest_add_func("acpi/q35/tcg/bridge", test_acpi_q35_tcg_bridge);
+        qtest_add_func("acpi/piix4/tcg/cpuhp_sparse",
+                       test_acpi_piix4_tcg_cpuhp_sparse);
     }
     ret = g_test_run();
     boot_sector_cleanup(disk);
Signature · 1 line
1.8.3.1
Reviewed-by on v6 1/1
#1 lore raw
Quoted 125 lines · Igor Mammedov

---
- rebased on top of todays PCI tree to match
modified tables

---
  tests/acpi-test-data/pc/APIC.cpuhp_sparse | Bin 0 -> 160 bytes
  tests/acpi-test-data/pc/DSDT.cpuhp_sparse | Bin 0 -> 5930 bytes
  tests/acpi-test-data/pc/SRAT.cpuhp_sparse | Bin 0 -> 264 bytes
  tests/bios-tables-test.c                  |  16 ++++++++++++++++
  4 files changed, 16 insertions(+)

create mode 100644 tests/acpi-test-data/pc/APIC.cpuhp_sparse create mode 100644 tests/acpi-test-data/pc/DSDT.cpuhp_sparse create mode 100644 tests/acpi-test-data/pc/SRAT.cpuhp_sparse

tests/acpi-test-data/pc/APIC.cpuhp_sparse new file binary +0 -0
new file mode 100644
index 0000000000000000000000000000000000000000..67918d51b7b7fbd26aff57802b3cf358864fb36a
GIT binary patch
tests/acpi-test-data/pc/DSDT.cpuhp_sparse new file binary +0 -0
new file mode 100644
index 0000000000000000000000000000000000000000..c8ce867d6d241b76ecef1e1fc322b68390a23bee
GIT binary patch
tests/acpi-test-data/pc/SRAT.cpuhp_sparse new file binary +0 -0
new file mode 100644
index 0000000000000000000000000000000000000000..8deeaee3bde46a891d8946b21368c4cef55d7d4f
GIT binary patch
tests/bios-tables-test.c +14 -0
index 0a80ddf..15fa3c9 100644
@@ -781,6 +781,20 @@ static void test_acpi_q35_tcg_bridge(void)
      free_test_data(&data);
  }
 
+static void test_acpi_piix4_tcg_cpuhp_sparse(void)
+{
+    test_data data;
+
+    memset(&data, 0, sizeof(data));
+    data.machine = MACHINE_PC;
+    data.variant = ".cpuhp_sparse";
+    test_acpi_one("-machine accel=tcg"
+                  " -numa node -smp 1,sockets=2,cores=3,maxcpus=6",
+                  &data);
+    free_test_data(&data);
+}
+
+
  int main(int argc, char *argv[])
  {
      const char *arch = qtest_get_arch();

tests/bios-tables-test.c int main(int argc, char *argv[]) · line 818

Quoted 8 lines
tests/bios-tables-test.c +2 -0
@@ -797,6 +811,8 @@ int main(int argc, char *argv[])
          qtest_add_func("acpi/piix4/tcg/bridge", test_acpi_piix4_tcg_bridge);
          qtest_add_func("acpi/q35/tcg", test_acpi_q35_tcg);
          qtest_add_func("acpi/q35/tcg/bridge", test_acpi_q35_tcg_bridge);
+        qtest_add_func("acpi/piix4/tcg/cpuhp_sparse",
+                       test_acpi_piix4_tcg_cpuhp_sparse);
      }
      ret = g_test_run();
      boot_sector_cleanup(disk);

Looks OK to me.

Thanks,
Marcel