target/ppc: Fix nip on power management instructions
[qemu/ar7.git] / tests / display-vga-test.c
blobbd176dcf3a2d9e52eeec3a28c0dd4b01dc5932c6
1 /*
2 * QTest testcase for vga cards
4 * Copyright (c) 2014 Red Hat, Inc
6 * This work is licensed under the terms of the GNU GPL, version 2 or later.
7 * See the COPYING file in the top-level directory.
8 */
10 #include "qemu/osdep.h"
11 #include "libqtest.h"
13 static void pci_cirrus(void)
15 qtest_start("-vga none -device cirrus-vga");
16 qtest_end();
19 static void pci_stdvga(void)
21 qtest_start("-vga none -device VGA");
22 qtest_end();
25 static void pci_secondary(void)
27 qtest_start("-vga none -device secondary-vga");
28 qtest_end();
31 static void pci_multihead(void)
33 qtest_start("-vga none -device VGA -device secondary-vga");
34 qtest_end();
37 static void pci_virtio_gpu(void)
39 qtest_start("-vga none -device virtio-gpu-pci");
40 qtest_end();
43 static void pci_virtio_vga(void)
45 qtest_start("-vga none -device virtio-vga");
46 qtest_end();
49 int main(int argc, char **argv)
51 const char *arch = qtest_get_arch();
53 g_test_init(&argc, &argv, NULL);
55 if (strcmp(arch, "alpha") == 0 || strcmp(arch, "i386") == 0 ||
56 strcmp(arch, "mips") == 0 || strcmp(arch, "x86_64") == 0) {
57 qtest_add_func("/display/pci/cirrus", pci_cirrus);
59 qtest_add_func("/display/pci/stdvga", pci_stdvga);
60 qtest_add_func("/display/pci/secondary", pci_secondary);
61 qtest_add_func("/display/pci/multihead", pci_multihead);
62 qtest_add_func("/display/pci/virtio-gpu", pci_virtio_gpu);
63 if (g_str_equal(arch, "i386") || g_str_equal(arch, "x86_64") ||
64 g_str_equal(arch, "hppa") || g_str_equal(arch, "ppc64")) {
65 qtest_add_func("/display/pci/virtio-vga", pci_virtio_vga);
68 return g_test_run();