diff mbox series

[1/3] x86: Fix member check in intel_gnvs

Message ID 20210223103542.1386572-1-sjg@chromium.org
State Accepted
Delegated to: Bin Meng
Headers show
Series [1/3] x86: Fix member check in intel_gnvs | expand

Commit Message

Simon Glass Feb. 23, 2021, 10:35 a.m. UTC
When CONFIG_CHROMEOS is not enabled this currently does not build. Fix it.

Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Simon Glass <sjg@chromium.org>
---

 arch/x86/include/asm/intel_gnvs.h | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Bin Meng Feb. 25, 2021, 1:25 p.m. UTC | #1
On Tue, Feb 23, 2021 at 6:35 PM Simon Glass <sjg@chromium.org> wrote:
>
> When CONFIG_CHROMEOS is not enabled this currently does not build. Fix it.
>
> Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> Signed-off-by: Simon Glass <sjg@chromium.org>
> ---
>
>  arch/x86/include/asm/intel_gnvs.h | 4 ++++
>  1 file changed, 4 insertions(+)
>

Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng Feb. 25, 2021, 1:31 p.m. UTC | #2
On Thu, Feb 25, 2021 at 9:25 PM Bin Meng <bmeng.cn@gmail.com> wrote:
>
> On Tue, Feb 23, 2021 at 6:35 PM Simon Glass <sjg@chromium.org> wrote:
> >
> > When CONFIG_CHROMEOS is not enabled this currently does not build. Fix it.
> >
> > Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> > Signed-off-by: Simon Glass <sjg@chromium.org>
> > ---
> >
> >  arch/x86/include/asm/intel_gnvs.h | 4 ++++
> >  1 file changed, 4 insertions(+)
> >
>
> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>

applied to u-boot-x86, thanks!
diff mbox series

Patch

diff --git a/arch/x86/include/asm/intel_gnvs.h b/arch/x86/include/asm/intel_gnvs.h
index 69a20812e5e..fc743dc9285 100644
--- a/arch/x86/include/asm/intel_gnvs.h
+++ b/arch/x86/include/asm/intel_gnvs.h
@@ -107,6 +107,10 @@  struct __packed acpi_global_nvs {
 	u8	unused2[0x1000 - 0x100];	/* Pad out to 4096 bytes */
 #endif
 };
+#ifdef CONFIG_CHROMEOS
 check_member(acpi_global_nvs, chromeos, GNVS_CHROMEOS_ACPI_OFFSET);
+#else
+check_member(acpi_global_nvs, unused2, GNVS_CHROMEOS_ACPI_OFFSET);
+#endif
 
 #endif /* _INTEL_GNVS_H_ */