From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: [PATCH v5 3/8] xen/arm: return int from flush_page_to_ram and *_dcache_va_range Date: Mon, 13 Oct 2014 16:35:11 +0100 Message-ID: <543BF12F.6070309@linaro.org> References: <1413212324-664-3-git-send-email-stefano.stabellini@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1413212324-664-3-git-send-email-stefano.stabellini@eu.citrix.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: Stefano Stabellini , xen-devel@lists.xensource.com Cc: julien.grall@citrix.com, Ian.Campbell@citrix.com List-Id: xen-devel@lists.xenproject.org On 10/13/2014 03:58 PM, Stefano Stabellini wrote: > These functions cannot really fail on ARM, but their x86 equivalents can > (-EOPNOTSUPP). Change the prototype to return int. > > Signed-off-by: Stefano Stabellini > --- > xen/arch/arm/mm.c | 6 ++++-- > xen/include/asm-arm/page.h | 8 +++++--- > xen/include/asm-x86/page.h | 3 ++- > 3 files changed, 11 insertions(+), 6 deletions(-) > > diff --git a/xen/arch/arm/mm.c b/xen/arch/arm/mm.c > index 996687b..f6f20aa 100644 > --- a/xen/arch/arm/mm.c > +++ b/xen/arch/arm/mm.c > @@ -377,12 +377,14 @@ unsigned long domain_page_map_to_mfn(const void *ptr) > } > #endif > > -void flush_page_to_ram(unsigned long mfn) > +int flush_page_to_ram(unsigned long mfn) If you decide to change the prototype of flush_page_to_ram, you need to check the return on every call-site. IHMO, as this function is implemented as a no-op on x86, I would keep the void and add an ASSERT below to check ret. Regards, -- Julien Grall