xref: /openbmc/u-boot/arch/nds32/include/asm/bootm.h (revision 90c08fa0)
1 /* SPDX-License-Identifier: GPL-2.0+ */
2 /*
3  * Copyright (c) 2013, Google Inc.
4  *
5  * Copyright (C) 2011
6  * Corscience GmbH & Co. KG - Simon Schwarz <schwarz@corscience.de>
7  */
8 #ifndef NDS32_BOOTM_H
9 #define NDS32_BOOTM_H
10 
11 #include <asm/setup.h>
12 
13 extern void udc_disconnect(void);
14 
15 #if defined(CONFIG_SETUP_MEMORY_TAGS) || \
16 		defined(CONFIG_CMDLINE_TAG) || \
17 		defined(CONFIG_INITRD_TAG) || \
18 		defined(CONFIG_SERIAL_TAG) || \
19 		defined(CONFIG_REVISION_TAG)
20 # define BOOTM_ENABLE_TAGS		1
21 #else
22 # define BOOTM_ENABLE_TAGS		0
23 #endif
24 
25 #ifdef CONFIG_SETUP_MEMORY_TAGS
26 # define BOOTM_ENABLE_MEMORY_TAGS	1
27 #else
28 # define BOOTM_ENABLE_MEMORY_TAGS	0
29 #endif
30 
31 #ifdef CONFIG_CMDLINE_TAG
32  #define BOOTM_ENABLE_CMDLINE_TAG	1
33 #else
34  #define BOOTM_ENABLE_CMDLINE_TAG	0
35 #endif
36 
37 #ifdef CONFIG_INITRD_TAG
38  #define BOOTM_ENABLE_INITRD_TAG	1
39 #else
40  #define BOOTM_ENABLE_INITRD_TAG	0
41 #endif
42 
43 #ifdef CONFIG_SERIAL_TAG
44  #define BOOTM_ENABLE_SERIAL_TAG	1
45 void get_board_serial(struct tag_serialnr *serialnr);
46 #else
47  #define BOOTM_ENABLE_SERIAL_TAG	0
48 static inline void get_board_serial(struct tag_serialnr *serialnr)
49 {
50 }
51 #endif
52 
53 #ifdef CONFIG_REVISION_TAG
54  #define BOOTM_ENABLE_REVISION_TAG	1
55 u32 get_board_rev(void);
56 #else
57  #define BOOTM_ENABLE_REVISION_TAG	0
58 static inline u32 get_board_rev(void)
59 {
60 	return 0;
61 }
62 #endif
63 
64 #endif
65