From nobody Mon Feb 9 05:37:52 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1528787278021567.0192633254475; Tue, 12 Jun 2018 00:07:58 -0700 (PDT) Received: from localhost ([::1]:53334 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSdPF-0004Rc-Bo for importer@patchew.org; Tue, 12 Jun 2018 03:07:53 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59161) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSd3t-0002ri-Oq for qemu-devel@nongnu.org; Tue, 12 Jun 2018 02:45:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSd3s-00021t-GB for qemu-devel@nongnu.org; Tue, 12 Jun 2018 02:45:49 -0400 Received: from ozlabs.org ([203.11.71.1]:51469) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fSd3s-0001wV-3X; Tue, 12 Jun 2018 02:45:48 -0400 Received: by ozlabs.org (Postfix, from userid 1007) id 414gPZ6L7PzB3t4; Tue, 12 Jun 2018 16:45:37 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1528785938; bh=+zg/zjkd9cQ07degxMS7eJQPQ7Um/9Fmn0JF37IzGn4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=M+QuDq9MDZ2vCsfYMvN+ENSjfVYthv2VVChhbcKBnuP8XK7E1BTv+GsOFPuqnjAfw OYUGLeVMnBq9F6HeTzGANaDrtLO//FC8KxvORZd7bjhaYD+Sy3kVsbaH9M/uKI8M4D KGuoDwiE5iBSVnsZqHgyaCy+FAdDir7XIu2xVqEQ= From: David Gibson To: peter.maydell@linaro.org Date: Tue, 12 Jun 2018 16:44:58 +1000 Message-Id: <20180612064503.14282-29-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180612064503.14282-1-david@gibson.dropbear.id.au> References: <20180612064503.14282-1-david@gibson.dropbear.id.au> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 203.11.71.1 Subject: [Qemu-devel] [PULL 28/33] spapr: introduce machine unplug handler 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: lvivier@redhat.com, David Hildenbrand , qemu-devel@nongnu.org, groug@kaod.org, qemu-ppc@nongnu.org, clg@kaod.org, David Gibson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: David Hildenbrand We'll be handling unplug of e.g. CPUs and PCDIMMs via the general hotplug handler soon, so let's add that handler function. Acked-by: David Gibson Reviewed-by: Greg Kurz Signed-off-by: David Hildenbrand Signed-off-by: David Gibson --- hw/ppc/spapr.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 9b8b4068b1..c45f8bc75b 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -3584,6 +3584,11 @@ static void spapr_machine_device_plug(HotplugHandler= *hotplug_dev, } } =20 +static void spapr_machine_device_unplug(HotplugHandler *hotplug_dev, + DeviceState *dev, Error **errp) +{ +} + static void spapr_machine_device_unplug_request(HotplugHandler *hotplug_de= v, DeviceState *dev, Error **= errp) { @@ -3978,6 +3983,7 @@ static void spapr_machine_class_init(ObjectClass *oc,= void *data) mc->get_default_cpu_node_id =3D spapr_get_default_cpu_node_id; mc->possible_cpu_arch_ids =3D spapr_possible_cpu_arch_ids; hc->unplug_request =3D spapr_machine_device_unplug_request; + hc->unplug =3D spapr_machine_device_unplug; =20 smc->dr_lmb_enabled =3D true; mc->default_cpu_type =3D POWERPC_CPU_TYPE_NAME("power8_v2.0"); --=20 2.17.1