From patchwork Thu Mar 21 10:47:35 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shameerali Kolothum Thodi X-Patchwork-Id: 10863301 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 3E5E31515 for ; Thu, 21 Mar 2019 11:00:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 222512A0BD for ; Thu, 21 Mar 2019 11:00:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 168952A0C0; Thu, 21 Mar 2019 11:00:59 +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 A8D582A0BD for ; Thu, 21 Mar 2019 11:00:58 +0000 (UTC) Received: from localhost ([127.0.0.1]:34873 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6vRS-0003wR-2p for patchwork-qemu-devel@patchwork.kernel.org; Thu, 21 Mar 2019 07:00:58 -0400 Received: from eggs.gnu.org ([209.51.188.92]:46974) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6vHm-0004Og-0M for qemu-devel@nongnu.org; Thu, 21 Mar 2019 06:50:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h6vFr-0001Oi-7I for qemu-devel@nongnu.org; Thu, 21 Mar 2019 06:49:00 -0400 Received: from szxga05-in.huawei.com ([45.249.212.191]:2251 helo=huawei.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1h6vFp-0000Mn-7g; Thu, 21 Mar 2019 06:48:57 -0400 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id AA5F01A24D99B9141026; Thu, 21 Mar 2019 18:48:47 +0800 (CST) Received: from S00345302A-PC.china.huawei.com (10.202.227.237) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.408.0; Thu, 21 Mar 2019 18:48:37 +0800 From: Shameer Kolothum To: , , , , , , , Date: Thu, 21 Mar 2019 10:47:35 +0000 Message-ID: <20190321104745.28068-1-shameerali.kolothum.thodi@huawei.com> X-Mailer: git-send-email 2.12.0.windows.1 MIME-Version: 1.0 X-Originating-IP: [10.202.227.237] X-CFilter-Loop: Reflected X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 45.249.212.191 Subject: [Qemu-devel] [PATCH v3 00/10] ARM virt: ACPI memory hotplug support 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: linuxarm@huawei.com, xuwei5@hisilicon.com Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP This series is an attempt to provide device memory hotplug support on ARM virt platform. This is based on Eric's recent works here[1] and carries some of the pc-dimm related patches dropped from his series. The kernel support for arm64 memory hot add was added recently by Robin and hence the guest kernel should be => 5.0-rc1. NVDIM support is not included currently as we still have an unresolved issue while hot adding NVDIMM[2]. However NVDIMM cold plug patches can be included, but not done for now, for keeping it simple. This makes use of GED device to sent hotplug ACPI events to the Guest. GED code is based on Nemu. Thanks to the efforts of Samuel and Sebastien to add the hardware-reduced support to Nemu using GED device[3]. (Please shout if I got the author/signed-off wrong for those patches or missed any names). Thanks, Shameer [1] https://patchwork.kernel.org/cover/10837565/ [2] https://patchwork.kernel.org/cover/10783589/ [3] https://github.com/intel/nemu/blob/topic/virt-x86/hw/acpi/ged.c v2 --> v2 Addressed comments from Igor and Eric, -Made virt acpi device platform independent and moved to hw/acpi/generic_event_device.c -Moved ged specific code into hw/acpi/generic_event_device.c -Introduced an opt-in feature "fdt" to resolve device-memory being treated as early boot memory. -Dropped patch #1 from v2. RFC --> v2 -Use GED device instead of GPIO for ACPI hotplug events. -Removed NVDIMM support for now. -Includes dropped patches from Eric's v9 series. Eric Auger (1): hw/arm/virt: Add memory hotplug framework Samuel Ortiz (3): hw/acpi: Do not create memory hotplug method when handler is not defined hw/arm/virt: Add virtual ACPI device hw/acpi: Add ACPI Generic Event Device Support Shameer Kolothum (6): hw/acpi: Make ACPI IO address space configurable hw/arm/virt: Add ACPI support for device memory cold-plug hw/arm/virt-acpi-build: Add PC-DIMM in SRAT hw/arm/virt: Introduce opt-in feature "fdt" hw/arm/boot: Expose the PC-DIMM nodes in the DT hw/arm/virt: Init GED device and enable memory hotplug default-configs/arm-softmmu.mak | 5 + hw/acpi/Kconfig | 4 + hw/acpi/Makefile.objs | 1 + hw/acpi/generic_event_device.c | 313 +++++++++++++++++++++++++++++++++ hw/acpi/memory_hotplug.c | 34 ++-- hw/arm/boot.c | 44 +++++ hw/arm/virt-acpi-build.c | 27 +++ hw/arm/virt.c | 121 ++++++++++++- hw/i386/acpi-build.c | 3 +- include/hw/acpi/generic_event_device.h | 68 +++++++ include/hw/acpi/memory_hotplug.h | 8 +- include/hw/arm/virt.h | 5 + 12 files changed, 614 insertions(+), 19 deletions(-) create mode 100644 hw/acpi/generic_event_device.c create mode 100644 include/hw/acpi/generic_event_device.h