From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: [PATCH RESEND v9 07/14] xen/common: add ARM stub for the function memory_type_changed() Date: Thu, 24 Jul 2014 15:07:53 +0100 Message-ID: <53D11339.5070500@linaro.org> References: <53BFEBFB.1090602@linaro.org> <1405299035-2988-1-git-send-email-avanzini.arianna@gmail.com> <1405299035-2988-8-git-send-email-avanzini.arianna@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1405299035-2988-8-git-send-email-avanzini.arianna@gmail.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Arianna Avanzini , xen-devel@lists.xen.org Cc: julien.grall@citrix.com, paolo.valente@unimore.it, keir@xen.org, stefano.stabellini@eu.citrix.com, tim@xen.org, dario.faggioli@citrix.com, Ian.Jackson@eu.citrix.com, Ian.Campbell@eu.citrix.com, etrudeau@broadcom.com, JBeulich@suse.com, andrew.cooper3@citrix.com, viktor.kleinik@globallogic.com List-Id: xen-devel@lists.xenproject.org Hi Arianna, On 07/14/2014 01:50 AM, Arianna Avanzini wrote: > MTRR-related code is not available for the ARM architecture. Given > that the memory_type_changed() function would be called also from > common code, its invocation is currently ifdef'd out to be only > compiled in on an x86 machine. This commit adds an empty stub for ARM. > > Signed-off-by: Arianna Avanzini Acked-by: Julien Grall Regards, > Cc: Dario Faggioli > Cc: Paolo Valente > Cc: Stefano Stabellini > Cc: Julien Grall > Cc: Ian Campbell > Cc: Jan Beulich > Cc: Keir Fraser > Cc: Tim Deegan > Cc: Ian Jackson > Cc: Andrew Cooper > Cc: Eric Trudeau > Cc: Viktor Kleinik > > --- > > v9: > - Don't expose the memory_type_changed() function to common code, > just add an empty stub in arch/arm/p2m.c and in the related header > for ARM. > > --- > xen/arch/arm/p2m.c | 4 ++++ > xen/common/domctl.c | 2 -- > xen/include/asm-arm/p2m.h | 2 ++ > 3 files changed, 6 insertions(+), 2 deletions(-) > > diff --git a/xen/arch/arm/p2m.c b/xen/arch/arm/p2m.c > index e9f7c96..6add407 100644 > --- a/xen/arch/arm/p2m.c > +++ b/xen/arch/arm/p2m.c > @@ -47,6 +47,10 @@ void p2m_dump_info(struct domain *d) > spin_unlock(&p2m->lock); > } > > +void memory_type_changed(struct domain *d) > +{ > +} > + > void dump_p2m_lookup(struct domain *d, paddr_t addr) > { > struct p2m_domain *p2m = &d->arch.p2m; > diff --git a/xen/common/domctl.c b/xen/common/domctl.c > index c326aba..24102c0 100644 > --- a/xen/common/domctl.c > +++ b/xen/common/domctl.c > @@ -897,10 +897,8 @@ long do_domctl(XEN_GUEST_HANDLE_PARAM(xen_domctl_t) u_domctl) > ret = iomem_permit_access(d, mfn, mfn + nr_mfns - 1); > else > ret = iomem_deny_access(d, mfn, mfn + nr_mfns - 1); > -#ifdef CONFIG_X86 > if ( !ret ) > memory_type_changed(d); > -#endif > } > break; > > diff --git a/xen/include/asm-arm/p2m.h b/xen/include/asm-arm/p2m.h > index 06c93a0..13fea36 100644 > --- a/xen/include/asm-arm/p2m.h > +++ b/xen/include/asm-arm/p2m.h > @@ -5,6 +5,8 @@ > > struct domain; > > +extern void memory_type_changed(struct domain *); > + > /* Per-p2m-table state */ > struct p2m_domain { > /* Lock that protects updates to the p2m */ > -- Julien Grall