From 461b0b089eb75a87d92e6d535652596074859746 Mon Sep 17 00:00:00 2001 From: Piotr Dymacz Date: Mon, 7 Nov 2016 22:25:39 +0100 Subject: [PATCH] Cosmetic: fix board order in u-boot/include/configs/ap121.h --- u-boot/include/configs/ap121.h | 163 ++++++++++++++++----------------- 1 file changed, 81 insertions(+), 82 deletions(-) diff --git a/u-boot/include/configs/ap121.h b/u-boot/include/configs/ap121.h index e50ddef..7bfe379 100644 --- a/u-boot/include/configs/ap121.h +++ b/u-boot/include/configs/ap121.h @@ -31,6 +31,13 @@ #define CONFIG_QCA_GPIO_MASK_OUT_INIT_H CONFIG_QCA_GPIO_MASK_LED_ACT_L #define CONFIG_QCA_GPIO_MASK_OUT_INIT_L CONFIG_QCA_GPIO_MASK_LED_ACT_H +#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) + + #define CONFIG_QCA_GPIO_MASK_LED_ACT_L GPIO27 + #define CONFIG_QCA_GPIO_MASK_OUT CONFIG_QCA_GPIO_MASK_LED_ACT_L + #define CONFIG_QCA_GPIO_MASK_IN GPIO11 + #define CONFIG_QCA_GPIO_MASK_OUT_INIT_H CONFIG_QCA_GPIO_MASK_LED_ACT_L + #elif defined(CONFIG_FOR_DLINK_DIR505_A1) #define CONFIG_QCA_GPIO_MASK_LED_ACT_L GPIO26 | GPIO27 @@ -49,6 +56,13 @@ #define CONFIG_QCA_GPIO_MASK_OUT_INIT_H CONFIG_QCA_GPIO_MASK_LED_ACT_L #define CONFIG_QCA_GPIO_MASK_OUT_INIT_L CONFIG_QCA_GPIO_MASK_LED_ACT_H +#elif defined(CONFIG_FOR_GL_INET) + + #define CONFIG_QCA_GPIO_MASK_LED_ACT_H GPIO0 | GPIO13 + #define CONFIG_QCA_GPIO_MASK_OUT CONFIG_QCA_GPIO_MASK_LED_ACT_H + #define CONFIG_QCA_GPIO_MASK_IN GPIO11 + #define CONFIG_QCA_GPIO_MASK_OUT_INIT_L CONFIG_QCA_GPIO_MASK_LED_ACT_H + #elif defined(CONFIG_FOR_GS_OOLITE_V1_DEV) #define CONFIG_QCA_GPIO_MASK_LED_ACT_L GPIO13 | GPIO15 | GPIO17 |\ @@ -57,13 +71,6 @@ #define CONFIG_QCA_GPIO_MASK_IN GPIO11 #define CONFIG_QCA_GPIO_MASK_OUT_INIT_H CONFIG_QCA_GPIO_MASK_LED_ACT_L -#elif defined(CONFIG_FOR_GL_INET) - - #define CONFIG_QCA_GPIO_MASK_LED_ACT_H GPIO0 | GPIO13 - #define CONFIG_QCA_GPIO_MASK_OUT CONFIG_QCA_GPIO_MASK_LED_ACT_H - #define CONFIG_QCA_GPIO_MASK_IN GPIO11 - #define CONFIG_QCA_GPIO_MASK_OUT_INIT_L CONFIG_QCA_GPIO_MASK_LED_ACT_H - #elif defined(CONFIG_FOR_TPLINK_MR10U_V1) #define CONFIG_QCA_GPIO_MASK_LED_ACT_L GPIO27 @@ -147,13 +154,6 @@ #define CONFIG_QCA_GPIO_MASK_OUT_INIT_H CONFIG_QCA_GPIO_MASK_LED_ACT_L #define CONFIG_QCA_GPIO_MASK_OUT_INIT_L CONFIG_QCA_GPIO_MASK_LED_ACT_H -#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) - - #define CONFIG_QCA_GPIO_MASK_LED_ACT_L GPIO27 - #define CONFIG_QCA_GPIO_MASK_OUT CONFIG_QCA_GPIO_MASK_LED_ACT_L - #define CONFIG_QCA_GPIO_MASK_IN GPIO11 - #define CONFIG_QCA_GPIO_MASK_OUT_INIT_H CONFIG_QCA_GPIO_MASK_LED_ACT_L - #endif /* @@ -161,25 +161,17 @@ * Default bootargs * ================ */ -#if defined(CONFIG_FOR_GL_INET) ||\ - defined(CONFIG_FOR_TPLINK_MR10U_V1) ||\ - defined(CONFIG_FOR_TPLINK_MR13U_V1) ||\ - defined(CONFIG_FOR_TPLINK_MR3020_V1) ||\ - defined(CONFIG_FOR_TPLINK_MR3040_V1V2) ||\ - defined(CONFIG_FOR_TPLINK_MR3220_V2) ||\ - defined(CONFIG_FOR_TPLINK_WR703N_V1) ||\ - defined(CONFIG_FOR_TPLINK_WR720N_V3) ||\ - defined(CONFIG_FOR_TPLINK_WR740N_V4) +#if defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) #define CONFIG_BOOTARGS "console=ttyS0,115200 root=31:02 "\ "rootfstype=squashfs init=/sbin/init "\ - "mtdparts=ar7240-nor0:128k(u-boot),1024k(kernel),2816k(rootfs),64k(config),64k(art)" + "mtdparts=ar7240-nor0:256k(u-boot),64k(u-boot-env),16000k(firmware),64k(art)" -#elif defined(CONFIG_FOR_TPLINK_WR710N_V1) +#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) #define CONFIG_BOOTARGS "console=ttyS0,115200 root=31:02 "\ "rootfstype=squashfs init=/sbin/init "\ - "mtdparts=ar7240-nor0:128k(u-boot),1024k(kernel),6912k(rootfs),64k(config),64k(art)" + "mtdparts=ar7240-nor0:128k(u-boot),64k(u-boot-env),16128k(firmware),64k(art)" #elif defined(CONFIG_FOR_DLINK_DIR505_A1) @@ -187,30 +179,38 @@ "rootfstype=squashfs init=/sbin/init "\ "mtdparts=ar7240-nor0:64k(u-boot),64k(art),64k(mac),64k(nvram),256k(language),1024k(uImage),6656k(rootfs)" -#elif defined(CONFIG_FOR_GS_OOLITE_V1_DEV) +#elif defined(CONFIG_FOR_DRAGINO_V2) ||\ + defined(CONFIG_FOR_MESH_POTATO_V2) #define CONFIG_BOOTARGS "console=ttyS0,115200 root=31:02 "\ "rootfstype=squashfs init=/sbin/init "\ - "mtdparts=ar7240-nor0:128k(u-boot),1024k(kernel),2816k(rootfs),64k(config),64k(art)" + "mtdparts=ar7240-nor0:192k(u-boot),64k(u-boot-env),16064k(firmware),64k(art)" -#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) +#elif defined(CONFIG_FOR_GL_INET) ||\ + defined(CONFIG_FOR_TPLINK_MR10U_V1) ||\ + defined(CONFIG_FOR_TPLINK_MR13U_V1) ||\ + defined(CONFIG_FOR_TPLINK_MR3020_V1) ||\ + defined(CONFIG_FOR_TPLINK_MR3040_V1V2) ||\ + defined(CONFIG_FOR_TPLINK_MR3220_V2) ||\ + defined(CONFIG_FOR_TPLINK_WR703N_V1) ||\ + defined(CONFIG_FOR_TPLINK_WR720N_V3) ||\ + defined(CONFIG_FOR_TPLINK_WR740N_V4) #define CONFIG_BOOTARGS "console=ttyS0,115200 root=31:02 "\ "rootfstype=squashfs init=/sbin/init "\ - "mtdparts=ar7240-nor0:128k(u-boot),64k(u-boot-env),16128k(firmware),64k(art)" + "mtdparts=ar7240-nor0:128k(u-boot),1024k(kernel),2816k(rootfs),64k(config),64k(art)" -#elif defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) +#elif defined(CONFIG_FOR_GS_OOLITE_V1_DEV) #define CONFIG_BOOTARGS "console=ttyS0,115200 root=31:02 "\ "rootfstype=squashfs init=/sbin/init "\ - "mtdparts=ar7240-nor0:256k(u-boot),64k(u-boot-env),16000k(firmware),64k(art)" + "mtdparts=ar7240-nor0:128k(u-boot),1024k(kernel),2816k(rootfs),64k(config),64k(art)" -#elif defined(CONFIG_FOR_DRAGINO_V2) ||\ - defined(CONFIG_FOR_MESH_POTATO_V2) +#elif defined(CONFIG_FOR_TPLINK_WR710N_V1) #define CONFIG_BOOTARGS "console=ttyS0,115200 root=31:02 "\ "rootfstype=squashfs init=/sbin/init "\ - "mtdparts=ar7240-nor0:192k(u-boot),64k(u-boot-env),16064k(firmware),64k(art)" + "mtdparts=ar7240-nor0:128k(u-boot),1024k(kernel),6912k(rootfs),64k(config),64k(art)" #endif @@ -219,15 +219,15 @@ * Load address and boot command * ============================= */ -#if defined(CONFIG_FOR_DLINK_DIR505_A1) - #define CFG_LOAD_ADDR 0x9F080000 -#elif defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) +#if defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) #define CFG_LOAD_ADDR 0x9F050000 +#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) + #define CFG_LOAD_ADDR 0x9F030000 +#elif defined(CONFIG_FOR_DLINK_DIR505_A1) + #define CFG_LOAD_ADDR 0x9F080000 #elif defined(CONFIG_FOR_DRAGINO_V2) ||\ defined(CONFIG_FOR_MESH_POTATO_V2) #define CFG_LOAD_ADDR 0x9F040000 -#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) - #define CFG_LOAD_ADDR 0x9F030000 #else #define CFG_LOAD_ADDR 0x9F020000 #endif @@ -239,7 +239,15 @@ * Environment configuration * ========================= */ -#if defined(CONFIG_FOR_DLINK_DIR505_A1) +#if defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) + #define CFG_ENV_ADDR 0x9F040000 + #define CFG_ENV_SIZE 0x8000 + #define CFG_ENV_SECT_SIZE 0x10000 +#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) + #define CFG_ENV_ADDR 0x9F020000 + #define CFG_ENV_SIZE 0x8000 + #define CFG_ENV_SECT_SIZE 0x10000 +#elif defined(CONFIG_FOR_DLINK_DIR505_A1) #define CFG_ENV_ADDR 0x9F028000 #define CFG_ENV_SIZE 0x7C00 #define CFG_ENV_SECT_SIZE 0x10000 @@ -248,14 +256,6 @@ #define CFG_ENV_ADDR 0x9F030000 #define CFG_ENV_SIZE 0x8000 #define CFG_ENV_SECT_SIZE 0x10000 -#elif defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) - #define CFG_ENV_ADDR 0x9F040000 - #define CFG_ENV_SIZE 0x8000 - #define CFG_ENV_SECT_SIZE 0x10000 -#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) - #define CFG_ENV_ADDR 0x9F020000 - #define CFG_ENV_SIZE 0x8000 - #define CFG_ENV_SECT_SIZE 0x10000 #else #define CFG_ENV_ADDR 0x9F01EC00 #define CFG_ENV_SIZE 0x1000 @@ -278,17 +278,13 @@ * MAC address/es, model and WPS pin offsets in FLASH * ================================================== */ -#if defined(CONFIG_FOR_DRAGINO_V2) ||\ - defined(CONFIG_FOR_MESH_POTATO_V2) ||\ - defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) +#if defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) ||\ + defined(CONFIG_FOR_DRAGINO_V2) ||\ + defined(CONFIG_FOR_MESH_POTATO_V2) #define OFFSET_MAC_DATA_BLOCK 0xFF0000 #define OFFSET_MAC_DATA_BLOCK_LENGTH 0x010000 #define OFFSET_MAC_ADDRESS 0x000000 #define OFFSET_MAC_ADDRESS2 0x000006 -#elif defined(CONFIG_FOR_GS_OOLITE_V1_DEV) - #define OFFSET_MAC_DATA_BLOCK 0x010000 - #define OFFSET_MAC_DATA_BLOCK_LENGTH 0x010000 - #define OFFSET_MAC_ADDRESS 0x00FC00 #elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) #define OFFSET_MAC_DATA_BLOCK 0xFF0000 #define OFFSET_MAC_DATA_BLOCK_LENGTH 0x010000 @@ -303,6 +299,10 @@ * #define OFFSET_MAC_ADDRESS 0x000004 * #define OFFSET_MAC_ADDRESS2 0x000016 */ +#elif defined(CONFIG_FOR_GS_OOLITE_V1_DEV) + #define OFFSET_MAC_DATA_BLOCK 0x010000 + #define OFFSET_MAC_DATA_BLOCK_LENGTH 0x010000 + #define OFFSET_MAC_ADDRESS 0x00FC00 #else #define OFFSET_MAC_DATA_BLOCK 0x010000 #define OFFSET_MAC_DATA_BLOCK_LENGTH 0x010000 @@ -310,19 +310,19 @@ #endif #if !defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) &&\ + !defined(CONFIG_FOR_BLACK_SWIFT_BOARD) &&\ !defined(CONFIG_FOR_DLINK_DIR505_A1) &&\ - !defined(CONFIG_FOR_GS_OOLITE_V1_DEV) &&\ !defined(CONFIG_FOR_DRAGINO_V2) &&\ - !defined(CONFIG_FOR_MESH_POTATO_V2) &&\ !defined(CONFIG_FOR_GL_INET) &&\ - !defined(CONFIG_FOR_BLACK_SWIFT_BOARD) + !defined(CONFIG_FOR_GS_OOLITE_V1_DEV) &&\ + !defined(CONFIG_FOR_MESH_POTATO_V2) #define OFFSET_ROUTER_MODEL 0xFD00 #endif #if defined(CONFIG_FOR_TPLINK_MR3020_V1) ||\ - defined(CONFIG_FOR_TPLINK_WR740N_V4) ||\ defined(CONFIG_FOR_TPLINK_MR3220_V2) ||\ - defined(CONFIG_FOR_TPLINK_WR710N_V1) + defined(CONFIG_FOR_TPLINK_WR710N_V1) ||\ + defined(CONFIG_FOR_TPLINK_WR740N_V4) #define OFFSET_PIN_NUMBER 0xFE00 #endif @@ -342,13 +342,13 @@ #endif /* Dragino 2 and Black Swift boards use different prompts */ -#if defined(CONFIG_FOR_DRAGINO_V2) ||\ - defined(CONFIG_FOR_MESH_POTATO_V2) - #undef CFG_PROMPT - #define CFG_PROMPT "dr_boot> " -#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) +#if defined(CONFIG_FOR_BLACK_SWIFT_BOARD) #undef CFG_PROMPT #define CFG_PROMPT "BSB> " +#elif defined(CONFIG_FOR_DRAGINO_V2) ||\ + defined(CONFIG_FOR_MESH_POTATO_V2) + #undef CFG_PROMPT + #define CFG_PROMPT "dr_boot> " #endif /* D-Link DIR-505 is limited to 64 KB only and doesn't use env */ @@ -369,22 +369,21 @@ #endif /* Firmware size limit */ -#if defined(CONFIG_FOR_DLINK_DIR505_A1) - #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (512 * 1024) -#elif defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) +#if defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (384 * 1024) +#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) + #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (256 * 1024) +#elif defined(CONFIG_FOR_DLINK_DIR505_A1) + #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (512 * 1024) #elif defined(CONFIG_FOR_DRAGINO_V2) ||\ defined(CONFIG_FOR_MESH_POTATO_V2) #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (320 * 1024) #elif defined(CONFIG_FOR_GS_OOLITE_V1_DEV) #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (192 * 1024) -#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) - #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (256 * 1024) #else #define WEBFAILSAFE_UPLOAD_LIMITED_AREA_IN_BYTES (192 * 1024) #endif - /* * ======================== * PLL/Clocks configuration @@ -392,15 +391,15 @@ */ #define CONFIG_QCA_PLL QCA_PLL_PRESET_400_400_200 -#if defined(CONFIG_FOR_DLINK_DIR505_A1) ||\ - defined(CONFIG_FOR_BLACK_SWIFT_BOARD) +#if defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) - #define CONFIG_QCA_PLL_IN_FLASH_BLOCK_OFFSET 0x20000 + #define CONFIG_QCA_PLL_IN_FLASH_BLOCK_OFFSET 0x40000 #define CONFIG_QCA_PLL_IN_FLASH_BLOCK_SIZE 0x10000 -#elif defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) +#elif defined(CONFIG_FOR_BLACK_SWIFT_BOARD) ||\ + defined(CONFIG_FOR_DLINK_DIR505_A1) - #define CONFIG_QCA_PLL_IN_FLASH_BLOCK_OFFSET 0x40000 + #define CONFIG_QCA_PLL_IN_FLASH_BLOCK_OFFSET 0x20000 #define CONFIG_QCA_PLL_IN_FLASH_BLOCK_SIZE 0x10000 #elif defined(CONFIG_FOR_DRAGINO_V2) ||\ @@ -421,11 +420,11 @@ * For upgrade scripts in environment * ================================== */ -#if !defined(CONFIG_FOR_BLACK_SWIFT_BOARD) &&\ - !defined(CONFIG_FOR_DLINK_DIR505_A1) &&\ - !defined(CONFIG_FOR_DRAGINO_V2) &&\ - !defined(CONFIG_FOR_MESH_POTATO_V2) &&\ - !defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) +#if !defined(CONFIG_FOR_8DEVICES_CARAMBOLA2) &&\ + !defined(CONFIG_FOR_BLACK_SWIFT_BOARD) &&\ + !defined(CONFIG_FOR_DLINK_DIR505_A1) &&\ + !defined(CONFIG_FOR_DRAGINO_V2) &&\ + !defined(CONFIG_FOR_MESH_POTATO_V2) #define CONFIG_UPG_SCRIPTS_UBOOT_SIZE_BCKP_HEX 0x20000 #endif -- 2.25.1