From: "Jan Beulich" Subject: Re: [PATCH 3/4] xen/arm: introduce XENMEM_cache_flush Date: Thu, 02 Oct 2014 12:49:07 +0100 Message-ID: <542D57D3020000780003BF2C@mail.emea.novell.com> References: <1412244158-12124-3-git-send-email-stefano.stabellini@eu.citrix.com> <542D5457020000780003BE7B@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta4.messagelabs.com ([85.158.143.247]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XZesg-0000kz-4q for xen-devel@lists.xenproject.org; Thu, 02 Oct 2014 11:49:10 +0000 In-Reply-To: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Stefano Stabellini Cc: julien.grall@citrix.com, xen-devel , Ian.Campbell@citrix.com List-Id: xen-devel@lists.xenproject.org >>> On 02.10.14 at 13:41, wrote: > On Thu, 2 Oct 2014, Jan Beulich wrote: >> With that, wouldn't the whole operation be a better fit with >> the other MMUEXT_* ones instead of being XENMEM_*? > > Or maybe a GNTTABOP_? > After all we are only interested in flushing foreign pages with the > hypercall. It would still need to take an mfn (or better a dev_bus_addr) > because dom0 doesn't know the grant_ref either. If the op is really meant to only be used on grants, then yes, XENMEM_ as well as MMUEXT_ would seem the wrong ones (but then you also incorrectly implemented it, as right now it permits flushes on non-foreign pages). But again I don't see why Dom0 can't track state for the mappings it establishes - after all, a grant-ref would be the most natural thing to pass in here. Jan