summaryrefslogtreecommitdiffstats
path: root/tests/pxe-test.c
diff options
context:
space:
mode:
authorPeter Maydell2016-10-06 14:34:00 +0200
committerPeter Maydell2016-10-06 14:34:00 +0200
commite902754e3d0890945ddcc1b33748ed73762ddb8d (patch)
treee6947598bebb9b361951d01ec65baae8c8dff015 /tests/pxe-test.c
parentrules.mak: quiet-command: Split command name and args to print (diff)
parenthw/ppc/spapr: Use POWER8 by default for the pseries-2.8 machine (diff)
downloadqemu-e902754e3d0890945ddcc1b33748ed73762ddb8d.tar.gz
qemu-e902754e3d0890945ddcc1b33748ed73762ddb8d.tar.xz
qemu-e902754e3d0890945ddcc1b33748ed73762ddb8d.zip
Merge remote-tracking branch 'remotes/dgibson/tags/ppc-for-2.8-20161006' into staging
ppc patch queue 2016-10-06 Currently accumulated target-ppc and spapr machine related patches. - More POWER9 instruction implementations - Additional test case / enabling of test cases for Power - Assorted fixes # gpg: Signature made Thu 06 Oct 2016 07:05:07 BST # gpg: using RSA key 0x6C38CACA20D9B392 # gpg: Good signature from "David Gibson <david@gibson.dropbear.id.au>" # gpg: aka "David Gibson (Red Hat) <dgibson@redhat.com>" # gpg: aka "David Gibson (ozlabs.org) <dgibson@ozlabs.org>" # gpg: aka "David Gibson (kernel.org) <dwg@kernel.org>" # Primary key fingerprint: 75F4 6586 AE61 A66C C44E 87DC 6C38 CACA 20D9 B392 * remotes/dgibson/tags/ppc-for-2.8-20161006: (29 commits) hw/ppc/spapr: Use POWER8 by default for the pseries-2.8 machine tests/pxe: Use -nodefaults to speed up ppc64/ipv6 pxe test spapr: fix check of cpu alias name in spapr_get_cpu_core_type() tests: enable ohci/uhci/xhci tests on PPC64 libqos: use generic qtest_shutdown() libqos: add PCI management in qtest_vboot()/qtest_shutdown() libqos: add PPC64 PCI support target-ppc: fix vmx instruction type/type2 target-ppc/kvm: Enable transactional memory on POWER8 with KVM-HV, too target-ppc/kvm: Add a wrapper function to check for KVM-PR MAINTAINERS: Add two more ppc related files target-ppc: Implement mtvsrws instruction target-ppc: add vclzlsbb/vctzlsbb instructions target-ppc: add vector compare not equal instructions target-ppc: fix invalid mask - cmpl, bctar target-ppc: add stxvb16x instruction target-ppc: add lxvb16x instruction target-ppc: add stxvh8x instruction target-ppc: add lxvh8x instruction target-ppc: improve stxvw4x implementation ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'tests/pxe-test.c')
-rw-r--r--tests/pxe-test.c22
1 files changed, 15 insertions, 7 deletions
diff --git a/tests/pxe-test.c b/tests/pxe-test.c
index b2cc355a95..5d3ddbe5e9 100644
--- a/tests/pxe-test.c
+++ b/tests/pxe-test.c
@@ -21,14 +21,14 @@
static const char *disk = "tests/pxe-test-disk.raw";
-static void test_pxe_one(const char *params)
+static void test_pxe_one(const char *params, bool ipv6)
{
char *args;
- args = g_strdup_printf("-machine accel=tcg "
- "-netdev user,id=" NETNAME ",tftp=./,bootfile=%s "
- "%s ",
- disk, params);
+ args = g_strdup_printf("-machine accel=tcg -nodefaults -boot order=n "
+ "-netdev user,id=" NETNAME ",tftp=./,bootfile=%s,"
+ "ipv4=%s,ipv6=%s %s", disk, ipv6 ? "off" : "on",
+ ipv6 ? "on" : "off", params);
qtest_start(args);
boot_sector_test();
@@ -38,12 +38,17 @@ static void test_pxe_one(const char *params)
static void test_pxe_e1000(void)
{
- test_pxe_one("-device e1000,netdev=" NETNAME);
+ test_pxe_one("-device e1000,netdev=" NETNAME, false);
}
static void test_pxe_virtio_pci(void)
{
- test_pxe_one("-device virtio-net-pci,netdev=" NETNAME);
+ test_pxe_one("-device virtio-net-pci,netdev=" NETNAME, false);
+}
+
+static void test_pxe_spapr_vlan(void)
+{
+ test_pxe_one("-device spapr-vlan,netdev=" NETNAME, true);
}
int main(int argc, char *argv[])
@@ -60,6 +65,9 @@ int main(int argc, char *argv[])
if (strcmp(arch, "i386") == 0 || strcmp(arch, "x86_64") == 0) {
qtest_add_func("pxe/e1000", test_pxe_e1000);
qtest_add_func("pxe/virtio", test_pxe_virtio_pci);
+ } else if (strcmp(arch, "ppc64") == 0) {
+ qtest_add_func("pxe/virtio", test_pxe_virtio_pci);
+ qtest_add_func("pxe/spapr-vlan", test_pxe_spapr_vlan);
}
ret = g_test_run();
boot_sector_cleanup(disk);