Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Simon Glass | 50ad221 | 2013-05-08 08:06:02 +0000 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (c) 2013, Google Inc. |
| 4 | * |
| 5 | * Copyright (C) 2011 |
Simon Schwarz | 6a597b9 | 2012-03-15 04:01:45 +0000 | [diff] [blame] | 6 | * Corscience GmbH & Co. KG - Simon Schwarz <schwarz@corscience.de> |
Simon Schwarz | 6a597b9 | 2012-03-15 04:01:45 +0000 | [diff] [blame] | 7 | */ |
| 8 | #ifndef ARM_BOOTM_H |
| 9 | #define ARM_BOOTM_H |
| 10 | |
Simon Schwarz | 6a597b9 | 2012-03-15 04:01:45 +0000 | [diff] [blame] | 11 | extern void udc_disconnect(void); |
Simon Glass | 50ad221 | 2013-05-08 08:06:02 +0000 | [diff] [blame] | 12 | |
| 13 | #if defined(CONFIG_SETUP_MEMORY_TAGS) || \ |
| 14 | defined(CONFIG_CMDLINE_TAG) || \ |
| 15 | defined(CONFIG_INITRD_TAG) || \ |
| 16 | defined(CONFIG_SERIAL_TAG) || \ |
| 17 | defined(CONFIG_REVISION_TAG) |
| 18 | # define BOOTM_ENABLE_TAGS 1 |
| 19 | #else |
| 20 | # define BOOTM_ENABLE_TAGS 0 |
| 21 | #endif |
| 22 | |
| 23 | #ifdef CONFIG_SETUP_MEMORY_TAGS |
| 24 | # define BOOTM_ENABLE_MEMORY_TAGS 1 |
| 25 | #else |
| 26 | # define BOOTM_ENABLE_MEMORY_TAGS 0 |
| 27 | #endif |
| 28 | |
| 29 | #ifdef CONFIG_CMDLINE_TAG |
| 30 | #define BOOTM_ENABLE_CMDLINE_TAG 1 |
| 31 | #else |
| 32 | #define BOOTM_ENABLE_CMDLINE_TAG 0 |
| 33 | #endif |
| 34 | |
| 35 | #ifdef CONFIG_INITRD_TAG |
| 36 | #define BOOTM_ENABLE_INITRD_TAG 1 |
| 37 | #else |
| 38 | #define BOOTM_ENABLE_INITRD_TAG 0 |
| 39 | #endif |
| 40 | |
Simon Glass | 30db774 | 2017-05-17 08:22:59 -0600 | [diff] [blame] | 41 | struct tag_serialnr; |
Simon Glass | 50ad221 | 2013-05-08 08:06:02 +0000 | [diff] [blame] | 42 | #ifdef CONFIG_SERIAL_TAG |
| 43 | #define BOOTM_ENABLE_SERIAL_TAG 1 |
Simon Glass | 50ad221 | 2013-05-08 08:06:02 +0000 | [diff] [blame] | 44 | #else |
| 45 | #define BOOTM_ENABLE_SERIAL_TAG 0 |
Tom Rini | ae21e7f | 2021-08-30 09:16:29 -0400 | [diff] [blame^] | 46 | #endif |
| 47 | #if defined(CONFIG_SERIAL_TAG) || defined(CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG) |
| 48 | void get_board_serial(struct tag_serialnr *serialnr); |
| 49 | #else |
Simon Glass | 50ad221 | 2013-05-08 08:06:02 +0000 | [diff] [blame] | 50 | static inline void get_board_serial(struct tag_serialnr *serialnr) |
| 51 | { |
| 52 | } |
| 53 | #endif |
| 54 | |
| 55 | #ifdef CONFIG_REVISION_TAG |
| 56 | #define BOOTM_ENABLE_REVISION_TAG 1 |
| 57 | u32 get_board_rev(void); |
| 58 | #else |
| 59 | #define BOOTM_ENABLE_REVISION_TAG 0 |
| 60 | static inline u32 get_board_rev(void) |
| 61 | { |
| 62 | return 0; |
| 63 | } |
Simon Schwarz | 6a597b9 | 2012-03-15 04:01:45 +0000 | [diff] [blame] | 64 | #endif |
| 65 | |
| 66 | #endif |