Commit 5c1a7ea6adf80decf6a9e998afc6a26508c68dbc
Committed by
Tom Rini
1 parent
c8a311d9dd
Exists in
master
and in
53 other branches
__HAVE_ARCH_GENERIC_BOARD controls availabilty of generic board
We are introducing a new unified board setup. Add a check to make sure that board config files do not define CONFIG_SYS_GENERIC_BOARD unless their architecture defines __HAVE_ARCH_GENERIC_BOARD __HAVE_ARCH_GENERIC_BOARD will currently not be the default setting, but we can switch this later when most architecture support generic board. Signed-off-by: Simon Glass <sjg@chromium.org>
Showing 2 changed files with 18 additions and 0 deletions Side-by-side Diff
README
... | ... | @@ -3212,6 +3212,16 @@ |
3212 | 3212 | If defined, don't allow the -f switch to env set override variable |
3213 | 3213 | access flags. |
3214 | 3214 | |
3215 | +- CONFIG_SYS_GENERIC_BOARD | |
3216 | + This selects the architecture-generic board system instead of the | |
3217 | + architecture-specific board files. It is intended to move boards | |
3218 | + to this new framework over time. Defining this will disable the | |
3219 | + arch/foo/lib/board.c file and use common/board_f.c and | |
3220 | + common/board_r.c instead. To use this option your architecture | |
3221 | + must support it (i.e. must define __HAVE_ARCH_GENERIC_BOARD in | |
3222 | + its config.mk file). If you find problems enabling this option on | |
3223 | + your board please report the problem and send patches! | |
3224 | + | |
3215 | 3225 | The following definitions that deal with the placement and management |
3216 | 3226 | of environment data (variable area); in general, we support the |
3217 | 3227 | following configurations: |
config.mk
... | ... | @@ -221,6 +221,14 @@ |
221 | 221 | CPPFLAGS += -DCONFIG_SPL_BUILD |
222 | 222 | endif |
223 | 223 | |
224 | +# Does this architecture support generic board init? | |
225 | +ifeq ($(__HAVE_ARCH_GENERIC_BOARD),) | |
226 | +ifneq ($(CONFIG_SYS_GENERIC_BOARD),) | |
227 | +$(error Your architecture does not support generic board. Please undefined \ | |
228 | +CONFIG_SYS_GENERIC_BOARD in your board config file) | |
229 | +endif | |
230 | +endif | |
231 | + | |
224 | 232 | ifneq ($(RESET_VECTOR_ADDRESS),) |
225 | 233 | CPPFLAGS += -DRESET_VECTOR_ADDRESS=$(RESET_VECTOR_ADDRESS) |
226 | 234 | endif |