From 56a571d9c803b7a2348373ca3feb44ca4e0d9131 Mon Sep 17 00:00:00 2001 From: Tetsuya Mukawa Date: Mon, 21 Dec 2015 12:47:34 +0900 Subject: ivshmem: Store file descriptor for vhost-user negotiation If virtio-net driver allocates memory in ivshmem shared memory, vhost-net will work correctly, but vhost-user will not work because a fd of shared memory will not be sent to vhost-user backend. This patch fixes ivshmem to store file descriptor of shared memory. It will be used when vhost-user negotiates vhost-user backend. Signed-off-by: Tetsuya Mukawa Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- include/exec/ram_addr.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/exec/ram_addr.h') diff --git a/include/exec/ram_addr.h b/include/exec/ram_addr.h index ba4c04d202..ef1489da77 100644 --- a/include/exec/ram_addr.h +++ b/include/exec/ram_addr.h @@ -72,6 +72,7 @@ ram_addr_t qemu_ram_alloc_resizeable(ram_addr_t size, ram_addr_t max_size, void *host), MemoryRegion *mr, Error **errp); int qemu_get_ram_fd(ram_addr_t addr); +void qemu_set_ram_fd(ram_addr_t addr, int fd); void *qemu_get_ram_block_host_ptr(ram_addr_t addr); void qemu_ram_free(ram_addr_t addr); -- cgit v1.2.3