From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:56222) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJgYC-0008Ej-RM for qemu-devel@nongnu.org; Thu, 04 Oct 2012 04:13:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TJgY8-0008Ad-Jt for qemu-devel@nongnu.org; Thu, 04 Oct 2012 04:12:56 -0400 Received: from e06smtp15.uk.ibm.com ([195.75.94.111]:37886) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJgY8-0008AQ-BK for qemu-devel@nongnu.org; Thu, 04 Oct 2012 04:12:52 -0400 Received: from /spool/local by e06smtp15.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 4 Oct 2012 09:12:50 +0100 Received: from d06av12.portsmouth.uk.ibm.com (d06av12.portsmouth.uk.ibm.com [9.149.37.247]) by b06cxnps3074.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q948CeiY23986388 for ; Thu, 4 Oct 2012 08:12:40 GMT Received: from d06av12.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av12.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q948Ckj9027857 for ; Thu, 4 Oct 2012 02:12:47 -0600 Message-ID: <506D44FE.6000608@de.ibm.com> Date: Thu, 04 Oct 2012 10:12:46 +0200 From: Christian Borntraeger MIME-Version: 1.0 References: <1349280245-16341-1-git-send-email-avi@redhat.com> <1349280245-16341-19-git-send-email-avi@redhat.com> In-Reply-To: <1349280245-16341-19-git-send-email-avi@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC v1 18/22] s390: avoid reaching into memory core internals List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: Alexander Graf , Heinz Graalfs , "Michael S. Tsirkin" , qemu-devel@nongnu.org, liu ping fan , Blue Swirl , Jens Freimann , Anthony Liguori , Paolo Bonzini On 03/10/12 18:04, Avi Kivity wrote: > use cpu_physical_memory_is_io() instead. > > Signed-off-by: Avi Kivity > --- > target-s390x/misc_helper.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/target-s390x/misc_helper.c b/target-s390x/misc_helper.c > index e9b3cae..2da4c90 100644 > --- a/target-s390x/misc_helper.c > +++ b/target-s390x/misc_helper.c > @@ -81,7 +81,7 @@ int sclp_service_call(CPUS390XState *env, uint32_t sccb, uint64_t code) > #endif > > /* basic checks */ > - if (!memory_region_is_ram(phys_page_find(sccb >> TARGET_PAGE_BITS)->mr)) { > + if (cpu_physical_memory_is_io(sccb)) { > return -PGM_ADDRESSING; > } > if (sccb & ~0x7ffffff8ul) { > You can then probably also remove the #include "cputlb.h" As a heads up: We have some patches pending that move that code. see https://lists.gnu.org/archive/html/qemu-devel/2012-10/msg00121.html So let us know if we should refresh the patch - otherwise we will let that be resolved by the person that merges the commit. (will be a merge conflict) Christian