@echo "#define CONFIG_BOOTDELAY "$(CONFIG_BOOTDELAY) >> include/config.h
endif
+ifdef CONFIG_MAX_UBOOT_SIZE_KB
+ @echo "#define CONFIG_MAX_UBOOT_SIZE_KB "$(CONFIG_MAX_UBOOT_SIZE_KB) >> include/config.h
+endif
+
ifdef CFG_PLL_FREQ
@echo "#define CFG_PLL_FREQ "$(CFG_PLL_FREQ) >> include/config.h
endif
// U-Boot partition size and offset
#define WEBFAILSAFE_UPLOAD_UBOOT_ADDRESS CFG_FLASH_BASE
+#define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (CONFIG_MAX_UBOOT_SIZE_KB * 1024)
#if defined(CONFIG_FOR_DLINK_DIR505_A1)
- #define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (64 * 1024)
#define UPDATE_SCRIPT_UBOOT_SIZE_IN_BYTES "0x10000"
#elif defined(CONFIG_FOR_8DEVICES_CARAMBOLA2)
- #define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (256 * 1024)
#define UPDATE_SCRIPT_UBOOT_SIZE_IN_BYTES "0x40000"
#elif defined(CONFIG_FOR_DRAGINO_V2) || \
defined(CONFIG_FOR_MESH_POTATO_V2)
- #define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (192 * 1024)
#define UPDATE_SCRIPT_UBOOT_SIZE_IN_BYTES "0x30000"
#else
- #define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (64 * 1024)
#define UPDATE_SCRIPT_UBOOT_SIZE_IN_BYTES "0x10000"
#endif
#define WEBFAILSAFE_UPLOAD_KERNEL_ADDRESS WEBFAILSAFE_UPLOAD_UBOOT_ADDRESS + 0x20000\r
\r
// U-Boot partition size\r
-#define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (64 * 1024)\r
+#define WEBFAILSAFE_UPLOAD_UBOOT_SIZE_IN_BYTES (CONFIG_MAX_UBOOT_SIZE_KB * 1024)\r
#define UPDATE_SCRIPT_UBOOT_SIZE_IN_BYTES "0x10000"\r
\r
// ART partition size\r