From e64befe929cc4c4a53a79ff469b1b52c210a3468 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Tue, 15 Mar 2016 19:34:28 +0100 Subject: [PATCH] ivshmem: Clean up after commit 9940c32 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit IVShmemState member eventfd_chr is useless since commit 9940c32. Drop it. Signed-off-by: Markus Armbruster Reviewed-by: Marc-André Lureau Message-Id: <1458066895-20632-14-git-send-email-armbru@redhat.com> --- hw/misc/ivshmem.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/hw/misc/ivshmem.c b/hw/misc/ivshmem.c index 6ac8c0d707..9ea79ab01d 100644 --- a/hw/misc/ivshmem.c +++ b/hw/misc/ivshmem.c @@ -79,7 +79,6 @@ typedef struct IVShmemState { uint32_t intrmask; uint32_t intrstatus; - CharDriverState **eventfd_chr; CharDriverState *server_chr; Fifo8 incoming_fifo; MemoryRegion ivshmem_mmio; @@ -942,8 +941,6 @@ static void pci_ivshmem_realize(PCIDevice *dev, Error **errp) pci_register_bar(dev, 2, attr, &s->bar); - s->eventfd_chr = g_malloc0(s->vectors * sizeof(CharDriverState *)); - qemu_chr_add_handlers(s->server_chr, ivshmem_can_receive, ivshmem_check_version, ivshmem_event, s); } else { @@ -1007,15 +1004,6 @@ static void pci_ivshmem_exit(PCIDevice *dev) memory_region_del_subregion(&s->bar, &s->ivshmem); } - if (s->eventfd_chr) { - for (i = 0; i < s->vectors; i++) { - if (s->eventfd_chr[i]) { - qemu_chr_free(s->eventfd_chr[i]); - } - } - g_free(s->eventfd_chr); - } - if (s->peers) { for (i = 0; i < s->nb_peers; i++) { close_peer_eventfds(s, i);