diff options
author | Thomas Chou | 2015-10-31 11:09:36 +0800 |
---|---|---|
committer | Stefan Roese | 2015-11-30 13:00:00 +0100 |
commit | 5aeeabf43c27b1bf4b3bb86e2b713dd98801df63 (patch) | |
tree | 629e68c0192401576ecf262f914c5ef1013b82af /include | |
parent | fa8883a1e39a20e72aaa5093af0c80062cb95757 (diff) |
cfi_flash: give default CONFIG_SYS_MAX_FLASH_SECT in flash.h
Give default CONFIG_SYS_MAX_FLASH_SECT in flash.h, so that
the header can be included regardless of the present of flash.
The value 512 is the most used.
Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
Signed-off-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/flash.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/flash.h b/include/flash.h index 13e03842c84..f53ace7889c 100644 --- a/include/flash.h +++ b/include/flash.h @@ -8,7 +8,10 @@ #ifndef _FLASH_H_ #define _FLASH_H_ -#ifndef CONFIG_SYS_NO_FLASH +#ifndef CONFIG_SYS_MAX_FLASH_SECT +#define CONFIG_SYS_MAX_FLASH_SECT 512 +#endif + /*----------------------------------------------------------------------- * FLASH Info: contains chip specific data, per FLASH bank */ @@ -503,6 +506,4 @@ extern flash_info_t *flash_get_info(ulong base); #define FLASH_ERASE_TIMEOUT 120000 /* timeout for erasing in ms */ #define FLASH_WRITE_TIMEOUT 500 /* timeout for writes in ms */ -#endif /* !CONFIG_SYS_NO_FLASH */ - #endif /* _FLASH_H_ */ |