diff mbox series

[U-Boot,v2,5/9] efi_loader: guard against double inclusion of efi_loader.h

Message ID 20171013173314.22304-6-xypron.glpk@gmx.de
State Superseded, archived
Delegated to: Alexander Graf
Headers show
Series efi_loader: implement SetWatchdogTimer | expand

Commit Message

Heinrich Schuchardt Oct. 13, 2017, 5:33 p.m. UTC
Use a define to detect double inclusion of efi_loader.h.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
---
v2
	new patch
---
 include/efi_loader.h | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

Comments

Simon Glass Oct. 22, 2017, 2:33 p.m. UTC | #1
On 13 October 2017 at 19:33, Heinrich Schuchardt <xypron.glpk@gmx.de> wrote:
> Use a define to detect double inclusion of efi_loader.h.
>
> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> ---
> v2
>         new patch
> ---
>  include/efi_loader.h | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)

Reviewed-by: Simon Glass <sjg@chromium.org>
diff mbox series

Patch

diff --git a/include/efi_loader.h b/include/efi_loader.h
index af64b11cee..e506eeec61 100644
--- a/include/efi_loader.h
+++ b/include/efi_loader.h
@@ -6,6 +6,9 @@ 
  *  SPDX-License-Identifier:     GPL-2.0+
  */
 
+#ifndef _EFI_LOADER_H
+#define _EFI_LOADER_H 1
+
 #include <common.h>
 #include <part_efi.h>
 #include <efi_api.h>
@@ -345,4 +348,6 @@  static inline void efi_set_bootdev(const char *dev, const char *devnr,
 				   const char *path) { }
 static inline void efi_net_set_dhcp_ack(void *pkt, int len) { }
 
-#endif
+#endif /* CONFIG_EFI_LOADER && !CONFIG_SPL_BUILD */
+
+#endif /* _EFI_LOADER_H */