From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48478) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ai6gM-0000IA-Sx for qemu-devel@nongnu.org; Mon, 21 Mar 2016 16:44:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ai6gJ-0000i2-GO for qemu-devel@nongnu.org; Mon, 21 Mar 2016 16:44:10 -0400 Received: from mx1.redhat.com ([209.132.183.28]:45633) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ai6gJ-0000hN-89 for qemu-devel@nongnu.org; Mon, 21 Mar 2016 16:44:07 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (Postfix) with ESMTPS id A3F1AC00B8D1 for ; Mon, 21 Mar 2016 20:44:06 +0000 (UTC) Received: from blackfin.pond.sub.org (ovpn-116-41.ams2.redhat.com [10.36.116.41]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u2LKi4cm014894 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Mon, 21 Mar 2016 16:44:05 -0400 From: Markus Armbruster Date: Mon, 21 Mar 2016 21:43:23 +0100 Message-Id: <1458593043-31731-1-git-send-email-armbru@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PULL v2 00/40] ivshmem: Fixes, cleanups, device model split List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Major issues addressed by this series: * The specification document is incomplete and vague. Rewritten. * When a peer goes away, and its ID gets reused for another one, interrupts don't work. * When configured for interrupts, we receive shared memory from the server some time after realize(). This creates a (usually short-lived) "no shared memory, yet" state. If the guest wins the race, it is exposed to this state (known issue, if you count burying in docs/specs/ as "known"). If migration wins the race, it fails or corrupts memory. * Interrupts are unreliable in a (usually small) time window after the destination peer connects. I believe fixing this will require changing the client/server protocol, so just document it for now. * The device isn't capable to tell guest software whether it is configured for interrupts. Fix that in a new, backwards-compatible revision of the guest ABI, and bump the PCI revision. Deprecate the old revision. * The device properties are a confusing mess and badly checked. Clean that up. * Migration with interrupts relies on server behavior not guaranteed by the specification. Tighten the specification. v2: * PATCH 05: Include ivshmem-test only in configurations that include the device * PATCH 36: Fix ivshmem-plain not to assert its nonexistent INTx Markus Armbruster (40): target-ppc: Document TOCTTOU in hugepage support ivshmem-server: Fix and clean up command line help ivshmem-server: Don't overload POSIX shmem and file name qemu-doc: Fix ivshmem huge page example event_notifier: Make event_notifier_init_fd() #ifdef CONFIG_EVENTFD tests/libqos/pci-pc: Fix qpci_pc_iomap() to map BARs aligned ivshmem-test: Improve test case /ivshmem/single ivshmem-test: Clean up wait for devices to become operational ivshmem-test: Improve test cases /ivshmem/server-* ivshmem: Rewrite specification document ivshmem: Add missing newlines to debug printfs ivshmem: Compile debug prints unconditionally to prevent bit-rot ivshmem: Clean up after commit 9940c32 ivshmem: Drop ivshmem_event() stub ivshmem: Don't destroy the chardev on version mismatch ivshmem: Fix harmless misuse of Error ivshmem: Failed realize() can leave migration blocker behind ivshmem: Clean up register callbacks ivshmem: Clean up MSI-X conditions ivshmem: Leave INTx alone when using MSI-X ivshmem: Assert interrupts are set up once ivshmem: Simplify rejection of invalid peer ID from server ivshmem: Disentangle ivshmem_read() ivshmem: Plug leaks on unplug, fix peer disconnect ivshmem: Receive shared memory synchronously in realize() ivshmem: Propagate errors through ivshmem_recv_setup() ivshmem: Rely on server sending the ID right after the version ivshmem: Drop the hackish test for UNIX domain chardev ivshmem: Simplify how we cope with short reads from server ivshmem: Tighten check of property "size" ivshmem: Implement shm=3D... with a memory backend ivshmem: Simplify memory regions for BAR 2 (shared memory) ivshmem: Inline check_shm_size() into its only caller qdev: New DEFINE_PROP_ON_OFF_AUTO ivshmem: Replace int role_val by OnOffAuto master ivshmem: Split ivshmem-plain, ivshmem-doorbell off ivshmem ivshmem: Clean up after the previous commit ivshmem: Drop ivshmem property x-memdev ivshmem: Require master to have ID zero contrib/ivshmem-server: Print "not for production" warning contrib/ivshmem-server/ivshmem-server.c | 56 +- contrib/ivshmem-server/ivshmem-server.h | 4 +- contrib/ivshmem-server/main.c | 98 +-- default-configs/pci.mak | 2 +- docs/specs/ivshmem-spec.txt | 254 +++++++ docs/specs/ivshmem_device_spec.txt | 161 ----- hw/core/qdev-properties.c | 10 + hw/misc/ivshmem.c | 1104 +++++++++++++++++--------= ------ include/hw/qdev-properties.h | 3 + qemu-doc.texi | 47 +- target-ppc/kvm.c | 6 + tests/Makefile | 2 +- tests/ivshmem-test.c | 99 +-- tests/libqos/pci-pc.c | 8 +- util/event_notifier-posix.c | 6 + 15 files changed, 1031 insertions(+), 829 deletions(-) create mode 100644 docs/specs/ivshmem-spec.txt delete mode 100644 docs/specs/ivshmem_device_spec.txt --=20 2.4.3