From patchwork Mon Jan 7 18:39:33 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?C=C3=A9dric_Le_Goater?= X-Patchwork-Id: 10751047 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 40E92746 for ; Mon, 7 Jan 2019 18:41:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 27FDA289A6 for ; Mon, 7 Jan 2019 18:41:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 17EF6289A8; Mon, 7 Jan 2019 18:41:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B08BD289A6 for ; Mon, 7 Jan 2019 18:41:51 +0000 (UTC) Received: from localhost ([127.0.0.1]:46960 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggZqP-0003nd-Ul for patchwork-qemu-devel@patchwork.kernel.org; Mon, 07 Jan 2019 13:41:49 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43500) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggZok-00025W-Lw for qemu-devel@nongnu.org; Mon, 07 Jan 2019 13:40:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ggZoj-0001zj-LX for qemu-devel@nongnu.org; Mon, 07 Jan 2019 13:40:06 -0500 Received: from 18.mo3.mail-out.ovh.net ([87.98.172.162]:45472) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ggZoi-0001qE-DK for qemu-devel@nongnu.org; Mon, 07 Jan 2019 13:40:04 -0500 Received: from player687.ha.ovh.net (unknown [10.109.159.90]) by mo3.mail-out.ovh.net (Postfix) with ESMTP id 574E51EF4A8 for ; Mon, 7 Jan 2019 19:40:00 +0100 (CET) Received: from kaod.org (lfbn-1-10605-110.w90-89.abo.wanadoo.fr [90.89.196.110]) (Authenticated sender: clg@kaod.org) by player687.ha.ovh.net (Postfix) with ESMTPSA id 389911604DA6; Mon, 7 Jan 2019 18:39:52 +0000 (UTC) From: =?utf-8?q?C=C3=A9dric_Le_Goater?= To: David Gibson Date: Mon, 7 Jan 2019 19:39:33 +0100 Message-Id: <20190107183946.7230-1-clg@kaod.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-Ovh-Tracer-Id: 11313042265881218022 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: -100 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedtledrvdejgdduudefucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecuhedttdenucesvcftvggtihhpihgvnhhtshculddquddttddm X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 87.98.172.162 Subject: [Qemu-devel] [PATCH 00/13] spapr: add KVM support to the XIVE interrupt mode X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-ppc@nongnu.org, qemu-devel@nongnu.org, =?utf-8?q?C=C3=A9dric_Le_Goa?= =?utf-8?q?ter?= Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP Hello, Following the 'dual' IRQ backend, this series adds KVM support to the XIVE interrupt mode. The first patches introduce the XIVE KVM device, state synchronization and migration support under KVM. The second part of the patchset modifies the XICS and XIVE interrupt models to add KVM support to the 'dual' IRQ backend. This is a first round to check that the interfaces with Linux/KVM are well in place. GitHub trees available here : QEMU sPAPR: https://github.com/legoater/qemu/commits/xive-next Linux/KVM: https://github.com/legoater/linux/commits/xive-5.0 OPAL: https://github.com/legoater/skiboot/commits/xive Thanks, C. Cédric Le Goater (13): linux-headers: update to 5.0 spapr/xive: add KVM support spapr/xive: add state synchronization with KVM spapr/xive: introduce a VM state change handler spapr/xive: add migration support for KVM spapr/xive: fix migration of the XiveTCTX under TCG ppc/xics: introduce a icp_kvm_connect() routine spapr/rtas: modify spapr_rtas_register() to remove RTAS handlers sysbus: add a sysbus_mmio_unmap() helper spapr: introduce routines to delete the KVM IRQ device spapr: check for the activation of the KVM IRQ device spapr/xics: ignore the lower 4K in the IRQ number space spapr: add KVM support to the 'dual' machine default-configs/ppc64-softmmu.mak | 1 + include/hw/ppc/spapr.h | 4 + include/hw/ppc/spapr_xive.h | 26 + include/hw/ppc/xics.h | 1 + include/hw/ppc/xive.h | 24 + include/hw/sysbus.h | 1 + linux-headers/asm-powerpc/kvm.h | 46 ++ linux-headers/linux/kvm.h | 9 + target/ppc/kvm_ppc.h | 6 + hw/core/sysbus.c | 10 + hw/intc/spapr_xive.c | 83 ++- hw/intc/spapr_xive_kvm.c | 886 ++++++++++++++++++++++++++++++ hw/intc/xics_kvm.c | 154 +++++- hw/intc/xive.c | 45 +- hw/ppc/spapr_irq.c | 114 +++- hw/ppc/spapr_rtas.c | 2 +- target/ppc/kvm.c | 7 + hw/intc/Makefile.objs | 1 + 18 files changed, 1363 insertions(+), 57 deletions(-) create mode 100644 hw/intc/spapr_xive_kvm.c