From 51b833f4405426b63b66380117bbe1f4c8976021 Mon Sep 17 00:00:00 2001 From: Alexey Kardashevskiy Date: Mon, 2 Mar 2015 11:38:55 -0700 Subject: vfio: Make type1 listener symbols static They are not used from anywhere but common.c which is where these are defined so make them static. Signed-off-by: Alexey Kardashevskiy Signed-off-by: Alex Williamson --- include/hw/vfio/vfio-common.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'include/hw') diff --git a/include/hw/vfio/vfio-common.h b/include/hw/vfio/vfio-common.h index 5f3679b7b2..3d3892cdf4 100644 --- a/include/hw/vfio/vfio-common.h +++ b/include/hw/vfio/vfio-common.h @@ -131,7 +131,6 @@ void vfio_region_write(void *opaque, hwaddr addr, uint64_t data, unsigned size); uint64_t vfio_region_read(void *opaque, hwaddr addr, unsigned size); -void vfio_listener_release(VFIOContainer *container); int vfio_mmap_region(Object *vdev, VFIORegion *region, MemoryRegion *mem, MemoryRegion *submem, void **map, size_t size, off_t offset, @@ -143,7 +142,6 @@ int vfio_get_device(VFIOGroup *group, const char *name, VFIODevice *vbasedev); extern const MemoryRegionOps vfio_region_ops; -extern const MemoryListener vfio_memory_listener; extern QLIST_HEAD(vfio_group_head, VFIOGroup) vfio_group_list; extern QLIST_HEAD(vfio_as_head, VFIOAddressSpace) vfio_address_spaces; -- cgit v1.2.3 From 6ee47c90081b3ab5980eeef1a8b12b54bac98bb5 Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Mon, 2 Mar 2015 11:38:55 -0700 Subject: vfio: allow to disable MMAP per device with -x-mmap=off option Disabling MMAP support uses the slower read/write accesses but allows to trace all MMIO accesses, which is not good for performance, but very useful for reverse engineering PCI drivers. This option allows to disable MMAP per device without a compile-time change. Signed-off-by: Samuel Pitoiset Signed-off-by: Alex Williamson --- include/hw/vfio/vfio-common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/hw') diff --git a/include/hw/vfio/vfio-common.h b/include/hw/vfio/vfio-common.h index 3d3892cdf4..0d1fb805bb 100644 --- a/include/hw/vfio/vfio-common.h +++ b/include/hw/vfio/vfio-common.h @@ -36,7 +36,6 @@ #endif /* Extra debugging, trap acceleration paths for more logging */ -#define VFIO_ALLOW_MMAP 1 #define VFIO_ALLOW_KVM_INTX 1 #define VFIO_ALLOW_KVM_MSI 1 #define VFIO_ALLOW_KVM_MSIX 1 @@ -102,6 +101,7 @@ typedef struct VFIODevice { int type; bool reset_works; bool needs_reset; + bool allow_mmap; VFIODeviceOps *ops; unsigned int num_irqs; unsigned int num_regions; -- cgit v1.2.3