[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v5 02/22] arm/acpi: Add a helper function to get the acpi table offset



On Fri, 4 Mar 2016, Shannon Zhao wrote:
> On 2016年03月04日 18:59, Stefano Stabellini wrote:
> >> diff --git a/xen/include/asm-arm/acpi.h b/xen/include/asm-arm/acpi.h
> >> > index 7f59761..6db3711 100644
> >> > --- a/xen/include/asm-arm/acpi.h
> >> > +++ b/xen/include/asm-arm/acpi.h
> >> > @@ -25,6 +25,7 @@
> >> >  
> >> >  #include <xen/init.h>
> >> >  #include <asm/page.h>
> >> > +#include <asm/setup.h>
> >> >  
> >> >  #define COMPILER_DEPENDENT_INT64   long long
> >> >  #define COMPILER_DEPENDENT_UINT64  unsigned long long
> >> > @@ -58,10 +59,15 @@ static inline void enable_acpi(void)
> >> >  {
> >> >      acpi_disabled = 0;
> >> >  }
> >> > +
> >> > +paddr_t acpi_get_table_offset(struct membank tbl_add[], EFI_MEM_RES 
> >> > index);
> >> >  #else
> >> >  #define acpi_disabled (1)
> >> >  #define disable_acpi()
> >> >  #define enable_acpi()
> >> > +paddr_t inline acpi_get_table_offset(struct membank tbl_add[],
> >> > +                                     EFI_MEM_RES index)
> >> > +{ return 0; }
> > Why did you move the declaration of acpi_get_table_offset to within the
> > ifdef?  It was just above the ifdef in the previous version of the
> > patch.
> > 
> If we don't do this, when we compile Xen just only apply the first 11
> patches of this series and since the acpi_create_efi_system_table is not
> covered by #ifdef CONFIG_ACPI, it will throw out an error says something
> like "acpi_get_table_offset not defined".

Just build efi-dom0 only if CONFIG_ACPI, then you can move back the
declaration of acpi_get_table_offset where is was before:

diff --git a/xen/arch/arm/efi/Makefile b/xen/arch/arm/efi/Makefile
index b38a0c9..d34c916 100644
--- a/xen/arch/arm/efi/Makefile
+++ b/xen/arch/arm/efi/Makefile
@@ -1,3 +1,4 @@
 CFLAGS += -fshort-wchar
 
-obj-y +=  boot.init.o runtime.o efi-dom0.init.o
+obj-y +=  boot.init.o runtime.o
+obj-$(CONFIG_ACPI) +=  efi-dom0.init.o
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.