Received: from eggs.gnu.org ([2001:4830:134:3::10]:40646) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VshR6-00088K-Qb for qemu-devel@nongnu.org; Mon, 16 Dec 2013 18:18:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VshR0-0003gz-Qx for qemu-devel@nongnu.org; Mon, 16 Dec 2013 18:18:52 -0500 Received: from cantor2.suse.de ([195.135.220.15]:52398 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VshR0-0003gs-Ke for qemu-devel@nongnu.org; Mon, 16 Dec 2013 18:18:46 -0500 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 7.1 \(1827\)) From: Alexander Graf In-Reply-To: <66752973-0E0C-4D70-9470-72EE48BD0642@suse.de> Date: Tue, 17 Dec 2013 00:18:42 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <0635E44F-AAAC-4059-813B-20DD5141369F@suse.de> References: <1387227072-21965-1-git-send-email-mjrosato@linux.vnet.ibm.com> <1387227072-21965-6-git-send-email-mjrosato@linux.vnet.ibm.com> <66752973-0E0C-4D70-9470-72EE48BD0642@suse.de> Subject: Re: [Qemu-devel] [PATCH 5/5] sclp-s390: Add memory hotplug SCLPs List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Matthew Rosato Cc: Gleb Natapov , QEMU Developers , Christian Borntraeger , aliguori@amazon.com, Cornelia Huck , Paolo Bonzini , Richard Henderson On 16.12.2013, at 22:42, Alexander Graf wrote: >=20 > On 16.12.2013, at 21:51, Matthew Rosato = wrote: >=20 [...] >=20 >> + } >> + } >> + } >> + sccb->h.response_code =3D = cpu_to_be16(SCLP_RC_NORMAL_COMPLETION); >> +} >> + >> static void sclp_execute(SCCB *sccb, uint64_t code) >> { >> S390SCLPDevice *sdev =3D get_event_facility(); >> @@ -50,6 +255,22 @@ static void sclp_execute(SCCB *sccb, uint64_t = code) >> case SCLP_CMDW_READ_SCP_INFO_FORCED: >> read_SCP_info(sccb); >> break; >> + case SCLP_READ_STORAGE_ELEMENT_INFO: >> + if (code & 0xff00) { >> + read_storage_element1_info(sccb); >> + } else { >> + read_storage_element0_info(sccb); >> + } >> + break; >> + case SCLP_ATTACH_STORAGE_ELEMENT: >> + attach_storage_element(sccb, (code & 0xff00) >> 8); >> + break; >> + case SCLP_ASSIGN_STORAGE: >> + assign_storage(sccb); >> + break; >> + case SCLP_UNASSIGN_STORAGE: >> + unassign_storage(sccb); >> + break; >=20 > Do you think it'd be possible to model this whole thing as a device = that has its own state? That's where you could keep the bitmap for = example. You'd only need some callback mechanism to hook into the SCLP = calls, but the PPC guys already have something similar with their = hypercalls. Speaking of state - in the current model the "is standby storage active" = bitmap doesn't get migrated, no? Alex