Home
last modified time | relevance | path

Searched +full:pci +full:- +full:test (Results 1 – 12 of 12) sorted by relevance

/kvm-unit-tests/arm/
H A Dpci-test.c2 * PCI bus operation test
9 #include <pci.h>
18 printf("PCI bus probing failed, skipping tests...\n"); in main()
22 report_prefix_push("pci"); in main()
27 if (ret == -1) in main()
28 report_skip("No PCI test device"); in main()
30 report(ret >= NR_TESTS, "PCI test device passed %d/%d tests", in main()
H A Dunittests.cfg11 # Test that the configured number of processors (smp = <num>), and
12 # that the configured amount of memory (-m <MB>) are correctly setup
15 [selftest-setup]
19 qemu_params = -m 256
20 kvmtool_params = --mem 256
23 # Test vector setup and exception handling (kernel mode).
24 [selftest-vectors-kernel]
26 test_args = vectors-kernel
29 # Test vector setup and exception handling (user mode).
30 [selftest-vectors-user]
[all …]
H A DMakefile.common7 tests-common = $(TEST_DIR)/selftest.$(exe)
8 tests-common += $(TEST_DIR)/spinlock-test.$(exe)
9 tests-common += $(TEST_DIR)/pci-test.$(exe)
10 tests-common += $(TEST_DIR)/pmu.$(exe)
11 tests-common += $(TEST_DIR)/gic.$(exe)
12 tests-common += $(TEST_DIR)/psci.$(exe)
13 tests-common += $(TEST_DIR)/sieve.$(exe)
14 tests-common += $(TEST_DIR)/pl031.$(exe)
15 tests-common += $(TEST_DIR)/dummy.$(exe)
17 tests-all = $(tests-common) $(tests)
[all …]
/kvm-unit-tests/lib/
H A Dpci-testdev.c2 * QEMU "pci-testdev" PCI test device
8 #include "pci.h"
98 static bool pci_testdev_one(struct pci_test_dev_hdr *test, in pci_testdev_one() argument
107 ops->io_writeb(test_nr, &test->test); in pci_testdev_one()
108 count = ops->io_readl(&test->count); in pci_testdev_one()
112 width = ops->io_readb(&test->width); in pci_testdev_one()
116 sig = ops->io_readl(&test->data); in pci_testdev_one()
117 off = ops->io_readl(&test->offset); in pci_testdev_one()
121 case 1: ops->io_writeb(sig, (void *)test + off); break; in pci_testdev_one()
122 case 2: ops->io_writew(sig, (void *)test + off); break; in pci_testdev_one()
[all …]
H A Dpci.h4 * API for scanning a PCI bus for a given device, as well to access
49 * @bar_num in all BAR access functions below is the index of the 32-bit
52 * In cases where the BAR size is 64-bit, a caller should still provide
53 * @bar_num in terms of 32-bit words. For example, if a device has a 64-bit
54 * BAR#0 and a 32-bit BAR#1, then caller should provide 2 to address BAR#1,
58 * tries to address the middle of a 64-bit register.
77 * pci-testdev is a driver for the pci-testdev qemu pci device. The
85 * pci-testdev supports at least three types of tests (via mmio and
86 * portio BARs): no-eventfd, wildcard-eventfd and datamatch-eventfd
94 uint8_t test; member
/kvm-unit-tests/x86/
H A Drun3 if [ -z "$KUT_STANDALONE" ]; then
4 if [ ! -f config.mak ]; then
5 echo "run ./configure && make first. See ./configure -h"
9 source scripts/arch-run.bash
18 if ! ${qemu} -device '?' 2>&1 | grep -F -e \"testdev\" -e \"pc-testdev\" > /dev/null;
20 echo "No Qemu test device support found"
25 ${qemu} -device '?' 2>&1 | grep -F "pci-testdev" > /dev/null;
27 pci_testdev="-device pci-testdev"
33 ${qemu} -device '?' 2>&1 | grep -F "pc-testdev" > /dev/null;
35 pc_testdev="-device pc-testdev -device isa-debug-exit,iobase=0xf4,iosize=0x4"
[all …]
H A Dintel-iommu.c2 * Intel IOMMU unit test.
13 #include "intel-iommu.h"
14 #include "pci-edu.h"
19 #define VTD_TEST_DMAR_4B ("DMAR 4B memcpy test")
41 vtd_map_range(dev->pci_dev.bdf, 0, virt_to_phys(page), PAGE_SIZE); in vtd_test_dmar()
51 * with offset 4 (so it'll be using 4-7 bytes). in vtd_test_dmar()
56 * Check data match between 0-3 bytes and 4-7 bytes of the in vtd_test_dmar()
81 struct pci_dev *pci_dev = &dev->pci_dev; in vtd_test_ir()
108 * Setup EDU PCI device MSI, using interrupt remapping. By in vtd_test_ir()
112 printf("edu device does not support MSI, skip test\n"); in vtd_test_ir()
[all …]
H A Dvmexit.c5 #include "pci.h"
13 struct test { struct
18 bool (*next)(struct test *); argument
76 tsc_eoi += rdtsc() - start; in self_ipi_isr()
83 tsc_ipi += rdtsc() - start; in x2apic_self_ipi()
91 tsc_ipi += rdtsc() - start; in apic_self_ipi()
193 tsc_ipi += rdtsc() - start; in ipi()
213 pm_tmr_blk = fadt->pm_tmr_blk; in inl_pmtimer()
245 static struct counter counters[64] = { { -1, 0 } }; in ple_round_robin()
250 while (p->n1 == p->n2) in ple_round_robin()
[all …]
H A DMakefile.common1 #This is a make file with common rules for both x86 & x86-64
6 cflatobjs += lib/pci.o
7 cflatobjs += lib/pci-edu.o
35 $(libcflat): CFLAGS += -ffreestanding -I $(SRCDIR)/lib -I lib
37 COMMON_CFLAGS += -m$(bits)
39 COMMON_CFLAGS += -Wa,--divide
41 COMMON_CFLAGS += -O1
52 $(LD) -T $(SRCDIR)/x86/efi/elf_x86_64_efi.lds $(EFI_LDFLAGS) -o $@ \
54 @chmod a-x $@
57 $(OBJCOPY) --only-keep-debug $^ $@.debug
[all …]
H A Dvmx_tests.c2 * All test cases of nested virtualization should be in this file
14 #include "pci.h"
51 int pos = -1; in ffs()
75 report_pass("Basic VMX test"); in basic_guest_main()
80 report_fail("Basic VMX test"); in basic_exit_handler()
90 report_pass("test vmlaunch"); in vmenter_main()
100 report((rax == 0xFFFF) && (rsp == resume_rsp), "test vmresume"); in vmenter_main()
110 report_fail("test vmresume"); in vmenter_exit_handler()
117 report_fail("test vmresume"); in vmenter_exit_handler()
156 if (((rdtsc() - tsc_val) >> preempt_scale) in preemption_timer_main()
[all …]
/kvm-unit-tests/
H A D.gitlab-ci.yml4 - dnf update -y
5 - dnf install -y make python
8 # because the test logs are important to help diagnose failures.
15 - logs
23 - build/logs
25 build-aarch64:
28 - dnf install -y qemu-system-aarch64 gcc-aarch64-linux-gnu
29 - ./configure --arch=aarch64 --cross-prefix=aarch64-linux-gnu-
30 - make -j2
31 - ACCEL=tcg MAX_SMP=8 ./run_tests.sh
[all …]
/kvm-unit-tests/lib/x86/
H A Dintel-iommu.c13 #include "intel-iommu.h"
15 #include "pci.h"
20 * VT-d in QEMU currently only support 39 bits address width, which is
21 * 3-level translation.
67 uint16_t source_id:16; /* Source-ID */
68 uint64_t sid_q:2; /* Source-ID Qualifier */
69 uint64_t sid_vtype:2; /* Source-ID Validation Type */
101 /* One-shot bits are taking effect immediately */ in vtd_gcmd_or()
119 printf("VT-d version: %#x\n", version); in vtd_dump_init_info()
150 for (level = VTD_PAGE_LEVEL; level > level_target; level--) { in vtd_install_pte()
[all …]