Convert bootcount drivers to Kconfig
v2 cover Convert bootcount drivers to Kconfig
This patch set converts bootcount drivers to Kconfig, it also merges CONFIG_BOOTCOUNT and CONFIG_BOOTCOUNT_LIMIT.
Green Travis build:
https://travis-ci.org/akiernan/u-boot/builds/341811354
This patch has been applied on top of u-boot/master:
SHA1: 7d531e8a4f9265ade08bc1d35135ff8888381a15
This patch series shall be applied on top of:
[U-Boot,1/2] Convert CONFIG_BOOTCOUNT_LIMIT to Kconfig
http://patchwork.ozlabs.org/patch/871585/
[U-Boot,2/2] Convert CONFIG_SYS_BOOTCOUNT_SINGLEWORD to Kconfig
http://patchwork.ozlabs.org/patch/871586/
Changes in v2:
- Fix erroneously removed line in README
- Convert CONFIG_BOOTCOUNT_EXT too - it had only been partially done
- Reword CONFIG_BOOTCOUNT_DRAM
- Update README for AT91 driver
- Remove CONFIG_BOOTCOUNT_LIMIT and CONFIG_SYS_BOOTCOUNT_SINGLEWORD from whitelist
- Rename CONFIG_SYS_BOOTCOUNT_ADDR to BOOTCOUNT_ADDR and remove from Kconfig
- Migrate CONFIG_BOOTCOUNT_ALEN to Kconfig
Alex Kiernan (13):
Merge CONFIG_BOOTCOUNT and CONFIG_BOOTCOUNT_LIMIT Prepare for multiple bootcount drivers Convert CONFIG_BOOTCOUNT_AM33XX to Kconfig Convert CONFIG_BOOTCOUNT_ENV to Kconfig Convert CONFIG_BOOTCOUNT_RAM to Kconfig Convert CONFIG_BOOTCOUNT_I2C to Kconfig Convert CONFIG_BOOTCOUNT_EXT to Kconfig Integrate AT91 bootcount driver
Migrate generic bootcount to Kconfig Remove SYS_BOOTCOUNT_ADDR from Kconfig Rename CONFIG_SYS_BOOTCOUNT_ADDR to BOOTCOUNT_ADDR Migrate CONFIG_BOOTCOUNT_ALEN to Kconfig Remove CONFIG_SYS_BOOTCOUNT_SINGLEWORD
README | 32 ----------- configs/draco_defconfig | 1 + configs/etamin_defconfig | 1 + configs/ge_b450v3_defconfig | 2 + configs/ge_b650v3_defconfig | 2 + configs/ge_b850v3_defconfig | 2 + configs/ids8313_defconfig | 1 + configs/km_kirkwood_128m16_defconfig | 1 + configs/km_kirkwood_defconfig | 1 + configs/km_kirkwood_pci_defconfig | 1 + configs/kmcoge5un_defconfig | 1 + configs/kmnusa_defconfig | 1 + configs/kmsugp1_defconfig | 1 + configs/kmsuv31_defconfig | 1 + configs/mgcoge3un_defconfig | 1 + configs/mx53ppd_defconfig | 1 - configs/portl2_defconfig | 1 + configs/pxm2_defconfig | 1 + configs/rastaban_defconfig | 1 + configs/rut_defconfig | 1 + configs/theadorable_debug_defconfig | 1 + configs/thuban_defconfig | 1 + drivers/bootcount/Kconfig | 98 ++++++++++++++++++++++++---------- drivers/bootcount/Makefile | 5 +- drivers/bootcount/bootcount.c | 16 +++--- drivers/bootcount/bootcount_davinci.c | 4 +- drivers/bootcount/bootcount_ext.c | 8 +-- drivers/bootcount/bootcount_i2c.c | 6 +-- include/configs/am335x_evm.h | 1 - include/configs/am335x_sl50.h | 1 - include/configs/baltos.h | 2 - include/configs/bav335x.h | 1 - include/configs/brppt1.h | 3 +- include/configs/calimain.h | 2 +- include/configs/chiliboard.h | 1 - include/configs/dh_imx6.h | 2 +- include/configs/ge_bx50v3.h | 6 +-- include/configs/highbank.h | 2 +- include/configs/ids8313.h | 4 +- include/configs/km/km_arm.h | 2 - include/configs/km/kmp204x-common.h | 2 +- include/configs/mx53ppd.h | 2 + include/configs/siemens-am33x-common.h | 2 - include/configs/socfpga_is1.h | 2 +- include/configs/socfpga_sr1500.h | 2 +- include/configs/theadorable.h | 1 - include/configs/ti_am335x_common.h | 2 +- include/configs/tqma6_wru4.h | 2 +- include/configs/x600.h | 2 +- scripts/config_whitelist.txt | 7 --- 50 files changed, 127 insertions(+), 117 deletions(-)
Signature · 1 line
2.7.4
PATCH v2 1/13 Merge CONFIG_BOOTCOUNT and CONFIG_BOOTCOUNT_LIMIT
CONFIG_BOOTCOUNT was only used in mx53ppd, merge it with CONFIG_BOOTCOUNT_LIMIT
CONFIG_BOOTCOUNT was only used in mx53ppd, merge it with CONFIG_BOOTCOUNT_LIMIT
---
Changes in v2:
- Fix erroneously removed line in README
- Convert CONFIG_BOOTCOUNT_EXT too - it had only been partially done
- Reword CONFIG_BOOTCOUNT_DRAM
- Update README for AT91 driver
- Remove CONFIG_BOOTCOUNT_LIMIT and CONFIG_SYS_BOOTCOUNT_SINGLEWORD from whitelist
- Rename CONFIG_SYS_BOOTCOUNT_ADDR to BOOTCOUNT_ADDR and remove from Kconfig
- Migrate CONFIG_BOOTCOUNT_ALEN to Kconfig
configs/mx53ppd_defconfig | 1 - drivers/bootcount/Kconfig | 9 +-------- scripts/config_whitelist.txt | 1 - 3 files changed, 1 insertion(+), 10 deletions(-)
configs/mx53ppd_defconfig +0 -1
@@ -21,7 +21,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_BOOTCOUNT=y CONFIG_BOOTCOUNT_LIMIT=y CONFIG_BOOTCOUNT_EXT=y CONFIG_SYS_BOOTCOUNT_EXT_DEVPART="0:5"
drivers/bootcount/Kconfig +1 -8
@@ -4,13 +4,6 @@ menu "Boot count support" -config BOOTCOUNT - bool "Enable Boot count support" - help - Enable boot count support, which provides the ability to store the - number of times the board has booted on a number of different - persistent storage mediums. - config BOOTCOUNT_LIMIT bool "Enable support for checking boot count limit" help
@@ -23,7 +16,7 @@ config SYS_BOOTCOUNT_SINGLEWORD This option enables packing boot count magic value and boot count into single word (32 bits). -if BOOTCOUNT +if BOOTCOUNT_LIMIT config BOOTCOUNT_EXT bool "Boot counter on EXT filesystem"
scripts/config_whitelist.txt +0 -1
@@ -151,7 +151,6 @@ CONFIG_BOOTCOUNT_ALEN CONFIG_BOOTCOUNT_AM33XX CONFIG_BOOTCOUNT_ENV CONFIG_BOOTCOUNT_I2C -CONFIG_BOOTCOUNT_LIMIT CONFIG_BOOTCOUNT_RAM CONFIG_BOOTFILE CONFIG_BOOTMAPSZ
Signature · 1 line
2.7.4
PATCH v2 1/13 Merge CONFIG_BOOTCOUNT and CONFIG_BOOTCOUNT_LIMIT
Hi Alex,
Quoted 5 lines
CONFIG_BOOTCOUNTwas only used in mx53ppd, merge it withCONFIG_BOOTCOUNT_LIMIT
CONFIG_BOOTCOUNTwas only used in mx53ppd, merge it withCONFIG_BOOTCOUNT_LIMIT
Please remove one instance.
Quoted 68 lines
Signed-off-by Alex Kiernan <[email protected]>Reviewed-by Lukasz Majewski <[email protected]>Reviewed-by Ian Ray <[email protected]>---
Changes in v2:
- Fix erroneously removed line in README
- ConvertCONFIG_BOOTCOUNT_EXTtoo - it had only been partially done
- RewordCONFIG_BOOTCOUNT_DRAM
- Update README for AT91 driver
- RemoveCONFIG_BOOTCOUNT_LIMITandCONFIG_SYS_BOOTCOUNT_SINGLEWORDfrom whitelist
- RenameCONFIG_SYS_BOOTCOUNT_ADDRtoBOOTCOUNT_ADDRand remove fromKconfig
- MigrateCONFIG_BOOTCOUNT_ALENtoKconfigconfigs/mx53ppd_defconfig | 1 - drivers/bootcount/Kconfig | 9 +-------- scripts/config_whitelist.txt | 1 - 3 files changed, 1 insertion(+), 10 deletions(-)configs/mx53ppd_defconfig +0
-1@@ -21,7 +21,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_BOOTCOUNT=y CONFIG_BOOTCOUNT_LIMIT=y CONFIG_BOOTCOUNT_EXT=y CONFIG_SYS_BOOTCOUNT_EXT_DEVPART="0:5"drivers/bootcount/Kconfig +0
-4@@ -4,13 +4,6 @@ menu "Boot count support" -config BOOTCOUNT - bool "Enable Boot count support" - help - Enable boot count support, which provides the ability tostore the
drivers/bootcount/Kconfig +0
-1- number of times the board has booted on a number ofdifferent
drivers/bootcount/Kconfig +0
-2- persistent storage mediums. - config BOOTCOUNT_LIMIT bool "Enable support for checking boot count limit" help@@ -23,7 +16,7 @@ config SYS_BOOTCOUNT_SINGLEWORD This option enables packing boot count magic value andboot count into single word (32 bits).
drivers/bootcount/Kconfig +1
-1-if BOOTCOUNT +if BOOTCOUNT_LIMIT config BOOTCOUNT_EXT bool "Boot counter on EXT filesystem"(quoted diff) +0
-0
b/scripts/config_whitelist.txtindex 38ce88e..b3a5d93 100644
scripts/config_whitelist.txt CONFIG_BOOTCOUNT_ALEN · line 156
Quoted 7 lines
scripts/config_whitelist.txt +0
-1@@ -151,7 +151,6 @@ CONFIG_BOOTCOUNT_ALEN CONFIG_BOOTCOUNT_AM33XX CONFIG_BOOTCOUNT_ENV CONFIG_BOOTCOUNT_I2C -CONFIG_BOOTCOUNT_LIMIT CONFIG_BOOTCOUNT_RAM CONFIG_BOOTFILE CONFIG_BOOTMAPSZ
Best regards,
Lukasz Majewski
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de -------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180216/e7a1f318/attachment.sig>
PATCH v2 2/13 Prepare for multiple bootcount drivers
In reply to Alex Kiernan---
Changes in v2: None
drivers/bootcount/Kconfig | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-)
drivers/bootcount/Kconfig +11 -14
@@ -2,29 +2,30 @@ # Boot count configuration # -menu "Boot count support" - -config BOOTCOUNT_LIMIT +menuconfig BOOTCOUNT_LIMIT bool "Enable support for checking boot count limit" help Enable checking for exceeding the boot count limit. More information: http://www.denx.de/wiki/DULG/UBootBootCountLimit -config SYS_BOOTCOUNT_SINGLEWORD - bool "Use single word to pack boot count and magic value" - help - This option enables packing boot count magic value and boot count - into single word (32 bits). - if BOOTCOUNT_LIMIT +choice + prompt "Boot count device" + config BOOTCOUNT_EXT bool "Boot counter on EXT filesystem" help Add support for maintaining boot count in a file on an EXT filesystem. -if BOOTCOUNT_EXT +endchoice + +config SYS_BOOTCOUNT_SINGLEWORD + bool "Use single word to pack boot count and magic value" + help + This option enables packing boot count magic value and boot count + into single word (32 bits). config SYS_BOOTCOUNT_EXT_INTERFACE string "Interface on which to find boot counter EXT filesystem"
@@ -57,7 +58,3 @@ config SYS_BOOTCOUNT_ADDR Set the address used for reading and writing the boot counter. endif - -endif - -endmenu
Signature · 1 line
2.7.4
PATCH v2 3/13 Convert CONFIG_BOOTCOUNT_AM33XX to Kconfig
In reply to Alex KiernanThis converts the following to Kconfig:
CONFIG_BOOTCOUNT_AM33XX
---
Changes in v2: None
README | 2 -- drivers/bootcount/Kconfig | 9 +++++++++ drivers/bootcount/Makefile | 1 - include/configs/am335x_evm.h | 1 - include/configs/am335x_sl50.h | 1 - include/configs/baltos.h | 2 -- include/configs/bav335x.h | 1 - include/configs/brppt1.h | 1 - include/configs/chiliboard.h | 1 - scripts/config_whitelist.txt | 1 - 10 files changed, 9 insertions(+), 11 deletions(-)
README +0 -2
@@ -2320,8 +2320,6 @@ The following options need to be configured: - bootcount support: CONFIG_AT91SAM9XE enable special bootcounter support on at91sam9xe based boards. - CONFIG_SOC_DA8XX - enable special bootcounter support on da850 based boards. CONFIG_BOOTCOUNT_RAM enable support for the bootcounter in RAM CONFIG_BOOTCOUNT_I2C
drivers/bootcount/Kconfig +9 -0
@@ -12,6 +12,7 @@ if BOOTCOUNT_LIMIT choice prompt "Boot count device" + default BOOTCOUNT_AM33XX if AM33XX || SOC_DA8XX config BOOTCOUNT_EXT bool "Boot counter on EXT filesystem"
@@ -19,6 +20,14 @@ config BOOTCOUNT_EXT Add support for maintaining boot count in a file on an EXT filesystem. +config BOOTCOUNT_AM33XX + bool "Boot counter in AM33XX RTC IP block" + depends on AM33XX || SOC_DA8XX + help + A bootcount driver for the RTC IP block found on many TI platforms. + This requires the RTC clocks, etc, to be enabled prior to use and + not all boards with this IP block on it will have the RTC in use. + endchoice config SYS_BOOTCOUNT_SINGLEWORD
drivers/bootcount/Makefile +0 -1
@@ -4,7 +4,6 @@ obj-y += bootcount.o obj-$(CONFIG_AT91SAM9XE) += bootcount_at91.o -obj-$(CONFIG_SOC_DA8XX) += bootcount_davinci.o obj-$(CONFIG_BOOTCOUNT_AM33XX) += bootcount_davinci.o obj-$(CONFIG_BOOTCOUNT_RAM) += bootcount_ram.o obj-$(CONFIG_BOOTCOUNT_ENV) += bootcount_env.o
include/configs/am335x_evm.h +0 -1
@@ -177,7 +177,6 @@/* SPL */ #ifndef CONFIG_NOR_BOOT /* Bootcount using the RTC block */ -#define CONFIG_BOOTCOUNT_AM33XX #define CONFIG_SYS_BOOTCOUNT_BE /* USB gadget RNDIS */
include/configs/am335x_sl50.h +0 -1
@@ -74,7 +74,6 @@/* SPL */ /* Bootcount using the RTC block */ -#define CONFIG_BOOTCOUNT_AM33XX #define CONFIG_SYS_BOOTCOUNT_BE #if defined(CONFIG_SPL_BUILD ) && defined(CONFIG_SPL_USBETH_SUPPORT )
include/configs/baltos.h +0 -2
@@ -230,8 +230,6 @@/* SPL */ #ifndef CONFIG_NOR_BOOT -/* Bootcount using the RTC block */ -#define CONFIG_BOOTCOUNT_AM33XX /* USB gadget RNDIS */
include/configs/bav335x.h +0 -1
@@ -339,7 +339,6 @@ DEFAULT_LINUX_BOOT_ENV \/* SPL */ #ifndef CONFIG_NOR_BOOT /* Bootcount using the RTC block */ -#define CONFIG_BOOTCOUNT_AM33XX #define CONFIG_SYS_BOOTCOUNT_BE /* USB gadget RNDIS */
include/configs/brppt1.h +0 -1
@@ -22,7 +22,6 @@/* Bootcount using the RTC block */ #define CONFIG_SYS_BOOTCOUNT_ADDR 0x44E3E000 -#define CONFIG_BOOTCOUNT_AM33XX /* memory */ #define CONFIG_SYS_MALLOC_LEN (5 * 1024 * 1024)
include/configs/chiliboard.h +0 -1
@@ -123,7 +123,6 @@/* SPL */ /* Bootcount using the RTC block */ -#define CONFIG_BOOTCOUNT_AM33XX #define CONFIG_SYS_BOOTCOUNT_BE /* NAND: device related configs */
scripts/config_whitelist.txt +0 -1
@@ -148,7 +148,6 @@ CONFIG_BOOGER CONFIG_BOOM CONFIG_BOOTBLOCK CONFIG_BOOTCOUNT_ALEN -CONFIG_BOOTCOUNT_AM33XX CONFIG_BOOTCOUNT_ENV CONFIG_BOOTCOUNT_I2C CONFIG_BOOTCOUNT_RAM
Signature · 1 line
2.7.4
PATCH v2 4/13 Convert CONFIG_BOOTCOUNT_ENV to Kconfig
In reply to Alex KiernanThis converts the following to Kconfig:
CONFIG_BOOTCOUNT_ENV
---
Changes in v2: None
README | 11 ----------- configs/draco_defconfig | 1 + configs/etamin_defconfig | 1 + configs/pxm2_defconfig | 1 + configs/rastaban_defconfig | 1 + configs/rut_defconfig | 1 + configs/thuban_defconfig | 1 + drivers/bootcount/Kconfig | 12 ++++++++++++ include/configs/siemens-am33x-common.h | 2 -- scripts/config_whitelist.txt | 1 - 10 files changed, 18 insertions(+), 14 deletions(-)
README +0 -11
@@ -714,17 +714,6 @@ The following options need to be configured: RAM and NFS. - Bootcount: - CONFIG_BOOTCOUNT_ENV - If no softreset save registers are found on the hardware - "bootcount" is stored in the environment. To prevent a - saveenv on all reboots, the environment variable - "upgrade_available" is used. If "upgrade_available" is - 0, "bootcount" is always 0, if "upgrade_available" is - 1 "bootcount" is incremented in the environment. - So the Userspace Applikation must set the "upgrade_available" - and "bootcount" variable to 0, if a boot was successfully. - -- Pre-Boot Commands: CONFIG_PREBOOT When this option is #defined, the existence of the
configs/draco_defconfig +1 -0
@@ -52,6 +52,7 @@ CONFIG_OF_CONTROL=y CONFIG_OF_EMBED=y CONFIG_ENV_IS_IN_NAND=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_ENV=y CONFIG_DFU_NAND=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y
configs/etamin_defconfig +1 -0
@@ -52,6 +52,7 @@ CONFIG_OF_CONTROL=y CONFIG_OF_EMBED=y CONFIG_ENV_IS_IN_NAND=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_ENV=y CONFIG_DFU_NAND=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y
configs/pxm2_defconfig +1 -0
@@ -55,6 +55,7 @@ CONFIG_OF_CONTROL=y CONFIG_OF_EMBED=y CONFIG_ENV_IS_IN_NAND=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_ENV=y CONFIG_DFU_NAND=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y
configs/rastaban_defconfig +1 -0
@@ -52,6 +52,7 @@ CONFIG_OF_CONTROL=y CONFIG_OF_EMBED=y CONFIG_ENV_IS_IN_NAND=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_ENV=y CONFIG_DFU_NAND=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y
configs/rut_defconfig +1 -0
@@ -56,6 +56,7 @@ CONFIG_OF_CONTROL=y CONFIG_OF_EMBED=y CONFIG_ENV_IS_IN_NAND=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_ENV=y CONFIG_DFU_NAND=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y
configs/thuban_defconfig +1 -0
@@ -52,6 +52,7 @@ CONFIG_OF_CONTROL=y CONFIG_OF_EMBED=y CONFIG_ENV_IS_IN_NAND=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_ENV=y CONFIG_DFU_NAND=y CONFIG_MMC_OMAP_HS=y CONFIG_NAND=y
drivers/bootcount/Kconfig +12 -0
@@ -28,6 +28,18 @@ config BOOTCOUNT_AM33XX This requires the RTC clocks, etc, to be enabled prior to use and not all boards with this IP block on it will have the RTC in use. +config BOOTCOUNT_ENV + bool "Boot counter in environment" + help + If no softreset save registers are found on the hardware + "bootcount" is stored in the environment. To prevent a + saveenv on all reboots, the environment variable + "upgrade_available" is used. If "upgrade_available" is + 0, "bootcount" is always 0, if "upgrade_available" is + 1 "bootcount" is incremented in the environment. + So the Userspace Application must set the "upgrade_available" + and "bootcount" variable to 0, if a boot was successfully. + endchoice config SYS_BOOTCOUNT_SINGLEWORD
include/configs/siemens-am33x-common.h +0 -2
@@ -499,6 +499,4 @@#define CONFIG_RESET_TO_RETRY #define CONFIG_BOOT_RETRY_TIME 60 -#define CONFIG_BOOTCOUNT_ENV -#endif /* ! __CONFIG_SIEMENS_AM33X_COMMON_H */
scripts/config_whitelist.txt +0 -1
@@ -148,7 +148,6 @@ CONFIG_BOOGER CONFIG_BOOM CONFIG_BOOTBLOCK CONFIG_BOOTCOUNT_ALEN -CONFIG_BOOTCOUNT_ENV CONFIG_BOOTCOUNT_I2C CONFIG_BOOTCOUNT_RAM CONFIG_BOOTFILE
Signature · 1 line
2.7.4
PATCH v2 5/13 Convert CONFIG_BOOTCOUNT_RAM to Kconfig
In reply to Alex KiernanThis converts the following to Kconfig:
CONFIG_BOOTCOUNT_RAM
---
Changes in v2: None
README | 2 -- configs/km_kirkwood_128m16_defconfig | 1 + configs/km_kirkwood_defconfig | 1 + configs/km_kirkwood_pci_defconfig | 1 + configs/kmcoge5un_defconfig | 1 + configs/kmnusa_defconfig | 1 + configs/kmsugp1_defconfig | 1 + configs/kmsuv31_defconfig | 1 + configs/mgcoge3un_defconfig | 1 + configs/portl2_defconfig | 1 + configs/theadorable_debug_defconfig | 1 + drivers/bootcount/Kconfig | 6 ++++++ include/configs/km/km_arm.h | 2 -- include/configs/theadorable.h | 1 - scripts/config_whitelist.txt | 1 - 15 files changed, 16 insertions(+), 6 deletions(-)
README +0 -2
@@ -2309,8 +2309,6 @@ The following options need to be configured: - bootcount support: CONFIG_AT91SAM9XE enable special bootcounter support on at91sam9xe based boards. - CONFIG_BOOTCOUNT_RAM - enable support for the bootcounter in RAM CONFIG_BOOTCOUNT_I2C enable support for the bootcounter on an i2c (like RTC) device. CONFIG_SYS_I2C_RTC_ADDR = i2c chip address
configs/km_kirkwood_128m16_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_EEPROM=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/km_kirkwood_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_EEPROM=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/km_kirkwood_pci_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_EEPROM=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/kmcoge5un_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/kmnusa_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/kmsugp1_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/kmsuv31_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/mgcoge3un_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_EEPROM=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/portl2_defconfig +1 -0
@@ -27,6 +27,7 @@ CONFIG_CMD_UBI=y # CONFIG_CMD_UBIFS is not set CONFIG_ENV_IS_IN_EEPROM=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y
configs/theadorable_debug_defconfig +1 -0
@@ -45,6 +45,7 @@ CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_OF_TRANSLATE=y CONFIG_SATA_MV=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_RAM=y CONFIG_FPGA_ALTERA=y CONFIG_DM_GPIO=y # CONFIG_MMC is not set
drivers/bootcount/Kconfig +6 -0
@@ -40,6 +40,12 @@ config BOOTCOUNT_ENV So the Userspace Application must set the "upgrade_available" and "bootcount" variable to 0, if a boot was successfully. +config BOOTCOUNT_RAM + bool "Boot counter in RAM" + help + Store the bootcount in DRAM protected against against bit errors + due to short power loss or holding a system in RESET. + endchoice config SYS_BOOTCOUNT_SINGLEWORD
include/configs/km/km_arm.h +0 -2
@@ -276,8 +276,6 @@ int get_scl(void);#define CONFIG_KM_RESERVED_PRAM 0x801000/* address for the bootcount (taken from end of RAM) */ #define BOOTCOUNT_ADDR (CONFIG_KM_RESERVED_PRAM) -/* Use generic bootcount RAM driver */ -#define CONFIG_BOOTCOUNT_RAM /* enable POST tests */ #define CONFIG_POST (CONFIG_SYS_POST_MEM_REGIONS)
include/configs/theadorable.h +0 -1
@@ -82,7 +82,6 @@/* * Bootcounter */ -#define CONFIG_BOOTCOUNT_RAM /* Max size of RAM minus BOOTCOUNT_ADDR is the bootcounter address */ #define BOOTCOUNT_ADDR 0x1000
scripts/config_whitelist.txt +0 -1
@@ -149,7 +149,6 @@ CONFIG_BOOM CONFIG_BOOTBLOCK CONFIG_BOOTCOUNT_ALEN CONFIG_BOOTCOUNT_I2C -CONFIG_BOOTCOUNT_RAM CONFIG_BOOTFILE CONFIG_BOOTMAPSZ CONFIG_BOOTMODE
Signature · 1 line
2.7.4
PATCH v2 6/13 Convert CONFIG_BOOTCOUNT_I2C to Kconfig
In reply to Alex KiernanThis converts the following to Kconfig:
CONFIG_BOOTCOUNT_I2C
---
Changes in v2: None
README | 6 ------ configs/ids8313_defconfig | 1 + drivers/bootcount/Kconfig | 9 +++++++++ include/configs/ids8313.h | 1 - scripts/config_whitelist.txt | 1 - 5 files changed, 10 insertions(+), 8 deletions(-)
README +0 -6
@@ -2309,12 +2309,6 @@ The following options need to be configured: - bootcount support: CONFIG_AT91SAM9XE enable special bootcounter support on at91sam9xe based boards. - CONFIG_BOOTCOUNT_I2C - enable support for the bootcounter on an i2c (like RTC) device. - CONFIG_SYS_I2C_RTC_ADDR = i2c chip address - CONFIG_SYS_BOOTCOUNT_ADDR = i2c addr which is used for - the bootcounter. - CONFIG_BOOTCOUNT_ALEN = address len CONFIG_BOOTCOUNT_EXT enable support for the bootcounter in EXT filesystem CONFIG_SYS_BOOTCOUNT_ADDR = RAM address used for read
configs/ids8313_defconfig +1 -0
@@ -30,6 +30,7 @@ CONFIG_MTDIDS_DEFAULT="nor0=ff800000.flash,nand0=e1000000.flash" CONFIG_MTDPARTS_DEFAULT="mtdparts=ff800000.flash:7m(dum),768k(BOOT-BIN),128k(BOOT-ENV),128k(BOOT-REDENV);e1000000.flash:-(ubi)" CONFIG_CMD_UBI=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_I2C=y # CONFIG_MMC is not set CONFIG_MTD_NOR_FLASH=y CONFIG_PHYLIB=y
drivers/bootcount/Kconfig +9 -0
@@ -46,6 +46,15 @@ config BOOTCOUNT_RAM Store the bootcount in DRAM protected against against bit errors due to short power loss or holding a system in RESET. +config BOOTCOUNT_I2C + bool "Boot counter on I2C device" + help + Enable support for the bootcounter on an i2c (like RTC) device. + CONFIG_SYS_I2C_RTC_ADDR = i2c chip address + CONFIG_SYS_BOOTCOUNT_ADDR = i2c addr which is used for + the bootcounter. + CONFIG_BOOTCOUNT_ALEN = address len + endchoice config SYS_BOOTCOUNT_SINGLEWORD
include/configs/ids8313.h +0 -1
@@ -515,7 +515,6 @@#define CONFIG_MTD_PARTITIONS /* bootcount support */ -#define CONFIG_BOOTCOUNT_I2C #define CONFIG_BOOTCOUNT_ALEN 1#define CONFIG_SYS_BOOTCOUNT_ADDR 0x9
scripts/config_whitelist.txt +0 -1
@@ -148,7 +148,6 @@ CONFIG_BOOGER CONFIG_BOOM CONFIG_BOOTBLOCK CONFIG_BOOTCOUNT_ALEN -CONFIG_BOOTCOUNT_I2C CONFIG_BOOTFILE CONFIG_BOOTMAPSZ CONFIG_BOOTMODE
Signature · 1 line
2.7.4
PATCH v2 7/13 Convert CONFIG_BOOTCOUNT_EXT to Kconfig
In reply to Alex KiernanThis converts the following to Kconfig:
CONFIG_BOOTCOUNT_EXT
---
Changes in v2: None
README | 7 ------- configs/ge_b450v3_defconfig | 2 ++ configs/ge_b650v3_defconfig | 2 ++ configs/ge_b850v3_defconfig | 2 ++ include/configs/ge_bx50v3.h | 4 ---- 5 files changed, 6 insertions(+), 11 deletions(-)
README +0 -7
@@ -2309,13 +2309,6 @@ The following options need to be configured: - bootcount support: CONFIG_AT91SAM9XE enable special bootcounter support on at91sam9xe based boards. - CONFIG_BOOTCOUNT_EXT - enable support for the bootcounter in EXT filesystem - CONFIG_SYS_BOOTCOUNT_ADDR = RAM address used for read - and write. - CONFIG_SYS_BOOTCOUNT_EXT_INTERFACE = interface - CONFIG_SYS_BOOTCOUNT_EXT_DEVPART = device and part - CONFIG_SYS_BOOTCOUNT_EXT_NAME = filename - Show boot progress: CONFIG_SHOW_BOOT_PROGRESS
configs/ge_b450v3_defconfig +2 -0
@@ -26,6 +26,8 @@ CONFIG_CMD_FS_GENERIC=y CONFIG_DOS_PARTITION=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_EXT=y +CONFIG_SYS_BOOTCOUNT_EXT_DEVPART="1:5" CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_NETDEVICES=y
configs/ge_b650v3_defconfig +2 -0
@@ -26,6 +26,8 @@ CONFIG_CMD_FS_GENERIC=y CONFIG_DOS_PARTITION=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_EXT=y +CONFIG_SYS_BOOTCOUNT_EXT_DEVPART="1:5" CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_NETDEVICES=y
configs/ge_b850v3_defconfig +2 -0
@@ -26,6 +26,8 @@ CONFIG_CMD_FS_GENERIC=y CONFIG_DOS_PARTITION=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_BOOTCOUNT_EXT=y +CONFIG_SYS_BOOTCOUNT_EXT_DEVPART="1:5" CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_NETDEVICES=y
include/configs/ge_bx50v3.h +0 -4
@@ -267,10 +267,6 @@#define CONFIG_BCH -#define CONFIG_BOOTCOUNT_EXT -#define CONFIG_SYS_BOOTCOUNT_EXT_INTERFACE "mmc" -#define CONFIG_SYS_BOOTCOUNT_EXT_DEVPART "1:5" -#define CONFIG_SYS_BOOTCOUNT_EXT_NAME "/boot/failures"#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000#endif /* __GE_BX50V3_CONFIG_H */
Signature · 1 line
2.7.4
PATCH v2 8/13 Integrate AT91 bootcount driver
In reply to Alex KiernanIntegrate Boot counter for Atmel AT91SAM9XE into Kconfig
---
Changes in v2: None
README | 4 ---- drivers/bootcount/Kconfig | 5 +++++ drivers/bootcount/Makefile | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-)
README +0 -4
@@ -2306,10 +2306,6 @@ The following options need to be configured: A better solution is to properly configure the firewall, but sometimes that is not allowed. -- bootcount support: - CONFIG_AT91SAM9XE - enable special bootcounter support on at91sam9xe based boards. - - Show boot progress: CONFIG_SHOW_BOOT_PROGRESS
drivers/bootcount/Kconfig +5 -0
@@ -13,6 +13,7 @@ if BOOTCOUNT_LIMIT choice prompt "Boot count device" default BOOTCOUNT_AM33XX if AM33XX || SOC_DA8XX + default BOOTCOUNT_AT91 if AT91SAM9XE config BOOTCOUNT_EXT bool "Boot counter on EXT filesystem"
@@ -55,6 +56,10 @@ config BOOTCOUNT_I2C the bootcounter. CONFIG_BOOTCOUNT_ALEN = address len +config BOOTCOUNT_AT91 + bool "Boot counter for Atmel AT91SAM9XE" + depends on AT91SAM9XE + endchoice config SYS_BOOTCOUNT_SINGLEWORD
drivers/bootcount/Makefile +1 -1
@@ -3,7 +3,7 @@ # obj-y += bootcount.o -obj-$(CONFIG_AT91SAM9XE) += bootcount_at91.o +obj-$(CONFIG_BOOTCOUNT_AT91) += bootcount_at91.o obj-$(CONFIG_BOOTCOUNT_AM33XX) += bootcount_davinci.o obj-$(CONFIG_BOOTCOUNT_RAM) += bootcount_ram.o obj-$(CONFIG_BOOTCOUNT_ENV) += bootcount_env.o
Signature · 1 line
2.7.4
PATCH v2 9/13 Migrate generic bootcount to Kconfig
In reply to Alex KiernanMake generate boot counter selected in the same way as other boot count drivers
---
Changes in v2: None
drivers/bootcount/Kconfig | 11 +++++++++++ drivers/bootcount/Makefile | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-)
drivers/bootcount/Kconfig +11 -0
@@ -14,6 +14,16 @@ choice prompt "Boot count device" default BOOTCOUNT_AM33XX if AM33XX || SOC_DA8XX default BOOTCOUNT_AT91 if AT91SAM9XE + default BOOTCOUNT_GENERIC + +config BOOTCOUNT_GENERIC + bool "Generic default boot counter" + help + Generic bootcount stored at SYS_BOOTCOUNT_ADDR. + + SYS_BOOTCOUNT_ADDR: + Set to the address where the bootcount and bootcount magic + will be stored. config BOOTCOUNT_EXT bool "Boot counter on EXT filesystem"
@@ -64,6 +74,7 @@ endchoice config SYS_BOOTCOUNT_SINGLEWORD bool "Use single word to pack boot count and magic value" + depends on BOOTCOUNT_GENERIC help This option enables packing boot count magic value and boot count into single word (32 bits).
drivers/bootcount/Makefile +1 -1
@@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0+ # -obj-y += bootcount.o +obj-$(CONFIG_BOOTCOUNT_GENERIC) += bootcount.o obj-$(CONFIG_BOOTCOUNT_AT91) += bootcount_at91.o obj-$(CONFIG_BOOTCOUNT_AM33XX) += bootcount_davinci.o obj-$(CONFIG_BOOTCOUNT_RAM) += bootcount_ram.o
Signature · 1 line
2.7.4
PATCH v2 10/13 Remove SYS_BOOTCOUNT_ADDR from Kconfig
In reply to Alex KiernanThe only user of SYS_BOOTCOUNT_ADDR is mx53ppd; remove it from Kconfig in preparation for renaming SYS_BOOTCOUNT_ADDR.
---
Changes in v2: None
drivers/bootcount/Kconfig | 7 ------- include/configs/mx53ppd.h | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-)
drivers/bootcount/Kconfig +0 -7
@@ -102,11 +102,4 @@ config SYS_BOOTCOUNT_EXT_NAME help Set the filename and path of the file used to store the boot counter. -config SYS_BOOTCOUNT_ADDR - hex "RAM address used for reading and writing the boot counter" - default 0x7000A000 - depends on BOOTCOUNT_EXT - help - Set the address used for reading and writing the boot counter. - endif
include/configs/mx53ppd.h +2 -0
@@ -241,4 +241,6 @@#define CONFIG_VIDEO_IPUV3 #endif +#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000 +#endif /* __CONFIG_H */
Signature · 1 line
2.7.4
PATCH v2 10/13 Remove SYS_BOOTCOUNT_ADDR from Kconfig
Quoted 34 lines · On Thu, 15 Feb 2018 13:55:23 +0000 Alex Kiernan <[email protected]> wrote:
The only user of
SYS_BOOTCOUNT_ADDRis mx53ppd; remove it fromKconfigin preparation for renamingSYS_BOOTCOUNT_ADDR.Signed-off-by Alex Kiernan <[email protected]>---
Changes in v2: None
drivers/bootcount/Kconfig | 7 ------- include/configs/mx53ppd.h | 2 ++ 2 files changed, 2 insertions(+), 7 deletions(-)drivers/bootcount/Kconfig +0
-0@@ -102,11 +102,4 @@ config SYS_BOOTCOUNT_EXT_NAME help Set the filename and path of the file used to store theboot counter.
drivers/bootcount/Kconfig +0
-2-config SYS_BOOTCOUNT_ADDR - hex "RAM address used for reading and writing the bootcounter"
drivers/bootcount/Kconfig +0
-4- default 0x7000A000 - depends on BOOTCOUNT_EXT - help - Set the address used for reading and writing the bootcounter. -
endifinclude/configs/mx53ppd.h +0
-0
include/configs/mx53ppd.h line 246
Quoted 6 lines
include/configs/mx53ppd.h +2
-0@@ -241,4 +241,6 @@#define CONFIG_VIDEO_IPUV3 #endif +#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000 +#endif /* __CONFIG_H */
Best regards,
Lukasz Majewski
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de -------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180216/0b9f7ee6/attachment.sig>
PATCH v2 11/13 Rename CONFIG_SYS_BOOTCOUNT_ADDR to BOOTCOUNT_ADDR
In reply to Alex KiernanRemove CONFIG_SYS_BOOTCOUNT_ADDR from Kconfig.
---
Changes in v2: None
drivers/bootcount/Kconfig | 10 ++++++---- drivers/bootcount/bootcount.c | 16 ++++++++-------- drivers/bootcount/bootcount_davinci.c | 4 ++-- drivers/bootcount/bootcount_ext.c | 8 ++++---- drivers/bootcount/bootcount_i2c.c | 6 +++--- include/configs/brppt1.h | 2 +- include/configs/calimain.h | 2 +- include/configs/dh_imx6.h | 2 +- include/configs/ge_bx50v3.h | 2 +- include/configs/highbank.h | 2 +- include/configs/ids8313.h | 2 +- include/configs/km/kmp204x-common.h | 2 +- include/configs/mx53ppd.h | 2 +- include/configs/socfpga_is1.h | 2 +- include/configs/socfpga_sr1500.h | 2 +- include/configs/ti_am335x_common.h | 2 +- include/configs/tqma6_wru4.h | 2 +- include/configs/x600.h | 2 +- 18 files changed, 36 insertions(+), 34 deletions(-)
drivers/bootcount/Kconfig +6 -4
@@ -19,9 +19,9 @@ choice config BOOTCOUNT_GENERIC bool "Generic default boot counter" help - Generic bootcount stored at SYS_BOOTCOUNT_ADDR. + Generic bootcount stored at BOOTCOUNT_ADDR. - SYS_BOOTCOUNT_ADDR: + BOOTCOUNT_ADDR: Set to the address where the bootcount and bootcount magic will be stored.
@@ -31,6 +31,9 @@ config BOOTCOUNT_EXT Add support for maintaining boot count in a file on an EXT filesystem. + BOOTCOUNT_ADDR + Set to the RAM address used for read and write. + config BOOTCOUNT_AM33XX bool "Boot counter in AM33XX RTC IP block" depends on AM33XX || SOC_DA8XX
@@ -62,8 +65,7 @@ config BOOTCOUNT_I2C help Enable support for the bootcounter on an i2c (like RTC) device. CONFIG_SYS_I2C_RTC_ADDR = i2c chip address - CONFIG_SYS_BOOTCOUNT_ADDR = i2c addr which is used for - the bootcounter. + BOOTCOUNT_ADDR = i2c addr which is used for the bootcounter. CONFIG_BOOTCOUNT_ALEN = address len config BOOTCOUNT_AT91
drivers/bootcount/bootcount.c +8 -8
@@ -9,24 +9,24 @@#include <linux/compiler.h> /* -* Only override CONFIG_SYS_BOOTCOUNT_ADDR if not already defined. This +* Only override BOOTCOUNT_ADDR if not already defined. This * way, some boards can define it directly in their config header. */ -#if !defined(CONFIG_SYS_BOOTCOUNT_ADDR ) +#if !defined(BOOTCOUNT_ADDR )#if defined(CONFIG_QE )#include <linux/immap_qe.h> -#define CONFIG_SYS_BOOTCOUNT_ADDR (CONFIG_SYS_IMMR + 0x110000 + \ +#define BOOTCOUNT_ADDR (CONFIG_SYS_IMMR + 0x110000 + \ QE_MURAM_SIZE - 2 * sizeof(u32))#endif /* defined(CONFIG_QE) */ -#endif /* !defined(CONFIG_SYS_BOOTCOUNT_ADDR) */ +#endif /* !defined(BOOTCOUNT_ADDR) */ /* Now implement the generic default functions */ -#if defined(CONFIG_SYS_BOOTCOUNT_ADDR ) +#if defined(BOOTCOUNT_ADDR )__weak void bootcount_store (ulong a) { -void *reg = (void *)CONFIG_SYS_BOOTCOUNT_ADDR ; +void *reg = (void *)BOOTCOUNT_ADDR ;#if defined(CONFIG_SYS_BOOTCOUNT_SINGLEWORD )raw_bootcount_store (reg, (BOOTCOUNT_MAGIC &0xffff0000 ) | a);
@@ -38,7 +38,7 @@ __weak void bootcount_store(ulong a)__weak ulong bootcount_load (void ) { -void *reg = (void *)CONFIG_SYS_BOOTCOUNT_ADDR ; +void *reg = (void *)BOOTCOUNT_ADDR ;#if defined(CONFIG_SYS_BOOTCOUNT_SINGLEWORD )u32 tmp =raw_bootcount_load (reg);
@@ -54,4 +54,4 @@ __weak ulong bootcount_load(void)return raw_bootcount_load (reg); #endif /* defined(CONFIG_SYS_BOOTCOUNT_SINGLEWORD) */ } -#endif /* defined(CONFIG_SYS_BOOTCOUNT_ADDR) */ +#endif /* defined(BOOTCOUNT_ADDR) */
drivers/bootcount/bootcount_davinci.c +2 -2
@@ -15,7 +15,7 @@void bootcount_store (ulong a) {struct davinci_rtc *reg = - (struct davinci_rtc *)CONFIG_SYS_BOOTCOUNT_ADDR ; + (struct davinci_rtc *)BOOTCOUNT_ADDR ;/* * write RTC kick registers to enable write
@@ -32,7 +32,7 @@ ulong bootcount_load(void) {unsigned long val;struct davinci_rtc *reg = - (struct davinci_rtc *)CONFIG_SYS_BOOTCOUNT_ADDR ; + (struct davinci_rtc *)BOOTCOUNT_ADDR ; val =raw_bootcount_load (®->scratch2);if ((val &0xffff0000 ) != (BOOTCOUNT_MAGIC &0xffff0000 ))
drivers/bootcount/bootcount_ext.c +4 -4
@@ -22,13 +22,13 @@ void bootcount_store(ulong a)return ; } - buf =map_sysmem (CONFIG_SYS_BOOTCOUNT_ADDR ,2 ); + buf =map_sysmem (BOOTCOUNT_ADDR ,2 ); buf[0 ] =BC_MAGIC ; buf[1 ] = (a &0xff );unmap_sysmem (buf); ret =fs_write (CONFIG_SYS_BOOTCOUNT_EXT_NAME , -CONFIG_SYS_BOOTCOUNT_ADDR ,0 ,2 , &len); +BOOTCOUNT_ADDR ,0 ,2 , &len);if (ret !=0 )puts ("Error storing bootcount\n" ); }
@@ -45,14 +45,14 @@ ulong bootcount_load(void)return 0 ; } - ret =fs_read (CONFIG_SYS_BOOTCOUNT_EXT_NAME ,CONFIG_SYS_BOOTCOUNT_ADDR , + ret =fs_read (CONFIG_SYS_BOOTCOUNT_EXT_NAME ,BOOTCOUNT_ADDR ,0 ,2 , &len_read);if (ret !=0 || len_read !=2 ) {puts ("Error loading bootcount\n" );return 0 ; } - buf =map_sysmem (CONFIG_SYS_BOOTCOUNT_ADDR ,2 ); + buf =map_sysmem (BOOTCOUNT_ADDR ,2 );if (buf[0 ] ==BC_MAGIC ) ret = buf[1 ];
drivers/bootcount/bootcount_i2c.c +3 -3
@@ -18,8 +18,8 @@ void bootcount_store(ulong a) buf[0 ] =BC_MAGIC ; buf[1 ] = (a &0xff ); - ret =i2c_write (CONFIG_SYS_I2C_RTC_ADDR ,CONFIG_SYS_BOOTCOUNT_ADDR , -CONFIG_BOOTCOUNT_ALEN , buf,2 ); + ret =i2c_write (CONFIG_SYS_I2C_RTC_ADDR ,BOOTCOUNT_ADDR , +CONFIG_BOOTCOUNT_ALEN , buf,2 );if (ret !=0 )puts ("Error writing bootcount\n" ); }
@@ -29,7 +29,7 @@ ulong bootcount_load(void)unsigned char buf[3 ];int ret; - ret =i2c_read (CONFIG_SYS_I2C_RTC_ADDR ,CONFIG_SYS_BOOTCOUNT_ADDR , + ret =i2c_read (CONFIG_SYS_I2C_RTC_ADDR ,BOOTCOUNT_ADDR ,CONFIG_BOOTCOUNT_ALEN , buf,2 );if (ret !=0 ) {puts ("Error loading bootcount\n" );
include/configs/brppt1.h +1 -1
@@ -21,7 +21,7 @@#define LCD_BPP LCD_COLOR32/* Bootcount using the RTC block */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x44E3E000 +#define BOOTCOUNT_ADDR 0x44E3E000/* memory */ #define CONFIG_SYS_MALLOC_LEN (5 * 1024 * 1024)
include/configs/calimain.h +1 -1
@@ -278,7 +278,7 @@#define CONFIG_SYS_INIT_SP_ADDR (0x8001ff00)#define CONFIG_SYS_BOOTCOUNT_LE /* Use little-endian accessors */ -#define CONFIG_SYS_BOOTCOUNT_ADDR DAVINCI_RTC_BASE +#define BOOTCOUNT_ADDR DAVINCI_RTC_BASE#ifndef __ASSEMBLY__int calimain_get_osc_freq (void );
include/configs/dh_imx6.h +1 -1
@@ -47,7 +47,7 @@#define CONFIG_SYS_MALLOC_LEN (4 * SZ_1M)/* Bootcounter */ -#define CONFIG_SYS_BOOTCOUNT_ADDR IRAM_BASE_ADDR +#define BOOTCOUNT_ADDR IRAM_BASE_ADDR#define CONFIG_SYS_BOOTCOUNT_BE /* FEC ethernet */
include/configs/ge_bx50v3.h +1 -1
@@ -267,6 +267,6 @@#define CONFIG_BCH -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000 +#define BOOTCOUNT_ADDR 0x7000A000#endif /* __GE_BX50V3_CONFIG_H */
include/configs/highbank.h +1 -1
@@ -27,7 +27,7 @@#define CONFIG_CONS_INDEX 0#define CONFIG_SYS_BOOTCOUNT_LE /* Use little-endian accessors */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0xfff3cf0c +#define BOOTCOUNT_ADDR 0xfff3cf0c#define CONFIG_MISC_INIT_R #define CONFIG_SCSI_AHCI_PLAT
include/configs/ids8313.h +1 -1
@@ -516,7 +516,7 @@/* bootcount support */ #define CONFIG_BOOTCOUNT_ALEN 1 -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x9 +#define BOOTCOUNT_ADDR 0x9#define CONFIG_IMAGE_FORMAT_LEGACY
include/configs/km/kmp204x-common.h +1 -1
@@ -189,7 +189,7 @@ unsigned long get_board_sys_clk(unsigned long dummy);#define CONFIG_SYS_OR1_PRELIM CONFIG_SYS_QRIO_OR_PRELIM/* QRIO Options */ /* bootcounter in QRIO */ -#define CONFIG_SYS_BOOTCOUNT_ADDR (CONFIG_SYS_QRIO_BASE + 0x20) +#define BOOTCOUNT_ADDR (CONFIG_SYS_QRIO_BASE + 0x20)#define CONFIG_BOARD_EARLY_INIT_R /* call board_early_init_r function */ #define CONFIG_MISC_INIT_F
include/configs/mx53ppd.h +1 -1
@@ -241,6 +241,6 @@#define CONFIG_VIDEO_IPUV3 #endif -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000 +#define BOOTCOUNT_ADDR 0x7000A000#endif /* __CONFIG_H */
include/configs/socfpga_is1.h +1 -1
@@ -33,7 +33,7 @@* Bootcounter */ /* last 2 lwords in OCRAM */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0xfffffff8 +#define BOOTCOUNT_ADDR 0xfffffff8#define CONFIG_SYS_BOOTCOUNT_BE #endif /* __CONFIG_SOCFPGA_IS1_H__ */
include/configs/socfpga_sr1500.h +1 -1
@@ -32,7 +32,7 @@* Bootcounter */ /* last 2 lwords in OCRAM */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0xfffffff8 +#define BOOTCOUNT_ADDR 0xfffffff8#define CONFIG_SYS_BOOTCOUNT_BE /* Environment setting for SPI flash */
include/configs/ti_am335x_common.h +1 -1
@@ -45,7 +45,7 @@* environment to a non-zero value and enable CONFIG_BOOTCOUNT_LIMIT * in the board config. */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x44E3E000 +#define BOOTCOUNT_ADDR 0x44E3E000/* * SPL related defines. The Public RAM memory map the ROM defines the
include/configs/tqma6_wru4.h +1 -1
@@ -34,7 +34,7 @@/* LED */ /* Bootcounter */ -#define CONFIG_SYS_BOOTCOUNT_ADDR IRAM_BASE_ADDR +#define BOOTCOUNT_ADDR IRAM_BASE_ADDR#define CONFIG_SYS_BOOTCOUNT_BE #endif /* __CONFIG_TQMA6_WRU4_H */
include/configs/x600.h +1 -1
@@ -120,7 +120,7 @@#define CONFIG_SYS_LOAD_ADDR 0x00800000/* Use last 2 lwords in internal SRAM for bootcounter */ -#define CONFIG_SYS_BOOTCOUNT_ADDR (CONFIG_SRAM_BASE + \ +#define BOOTCOUNT_ADDR (CONFIG_SRAM_BASE + \ CONFIG_SRAM_SIZE)#define CONFIG_HOSTNAME x600
Signature · 1 line
2.7.4
PATCH v2 11/13 Rename CONFIG_SYS_BOOTCOUNT_ADDR to BOOTCOUNT_ADDR
Hi Alex,
Please extend the commit message, as for example presented below:
Quoted 1 line
Remove
CONFIG_SYS_BOOTCOUNT_ADDRfromKconfig.
and also introduce BOOTCOUNT_ADDR as a replacement.
After this change the CONFIG_SYS_BOOTCOUNT_ADDR is completely removed from the u-boot code base.
It has been replaced with BOOTCOUNT_ADDR to preserve current behaviour. This variable is not (yet) introduced to Kconfig.
Quoted 358 lines
Signed-off-by Alex Kiernan <[email protected]>---
Changes in v2: None
drivers/bootcount/Kconfig | 10 ++++++---- drivers/bootcount/bootcount.c | 16 ++++++++-------- drivers/bootcount/bootcount_davinci.c | 4 ++-- drivers/bootcount/bootcount_ext.c | 8 ++++---- drivers/bootcount/bootcount_i2c.c | 6 +++--- include/configs/brppt1.h | 2 +- include/configs/calimain.h | 2 +- include/configs/dh_imx6.h | 2 +- include/configs/ge_bx50v3.h | 2 +- include/configs/highbank.h | 2 +- include/configs/ids8313.h | 2 +- include/configs/km/kmp204x-common.h | 2 +- include/configs/mx53ppd.h | 2 +- include/configs/socfpga_is1.h | 2 +- include/configs/socfpga_sr1500.h | 2 +- include/configs/ti_am335x_common.h | 2 +- include/configs/tqma6_wru4.h | 2 +- include/configs/x600.h | 2 +- 18 files changed, 36 insertions(+), 34 deletions(-)drivers/bootcount/Kconfig +2
-2@@ -19,9 +19,9 @@ choice config BOOTCOUNT_GENERIC bool "Generic default boot counter" help - Generic bootcount stored at SYS_BOOTCOUNT_ADDR. + Generic bootcount stored at BOOTCOUNT_ADDR. - SYS_BOOTCOUNT_ADDR: + BOOTCOUNT_ADDR: Set to the address where the bootcount and bootcountmagic will be stored.
drivers/bootcount/Kconfig +3
-0@@ -31,6 +31,9 @@ config BOOTCOUNT_EXT Add support for maintaining boot count in a file on an EXT filesystem. + BOOTCOUNT_ADDR + Set to the RAM address used for read and write. + config BOOTCOUNT_AM33XX bool "Boot counter in AM33XX RTC IP block" depends on AM33XX || SOC_DA8XX@@ -62,8 +65,7 @@ config BOOTCOUNT_I2C help Enable support for the bootcounter on an i2c (like RTC)device.
CONFIG_SYS_I2C_RTC_ADDR= i2c chip addressdrivers/bootcount/Kconfig +1
-2- CONFIG_SYS_BOOTCOUNT_ADDR = i2c addr which is used for - the bootcounter. + BOOTCOUNT_ADDR = i2c addr which is used for thebootcounter.
CONFIG_BOOTCOUNT_ALEN= address lenconfig
BOOTCOUNT_AT91(quoted diff) +0
-0
b/drivers/bootcount/bootcount.cindex 8b499fe..82ef426 100644drivers/bootcount/bootcount.c +0
-1@@ -9,24 +9,24 @@#include <linux/compiler.h> /* -* Only override CONFIG_SYS_BOOTCOUNT_ADDR if not already defined. This
+ * Only overrideBOOTCOUNT_ADDRif not already defined. This
* way, some boards can define it directly in their config header. */drivers/bootcount/bootcount.c +2
-2-#if !defined(CONFIG_SYS_BOOTCOUNT_ADDR ) +#if !defined(BOOTCOUNT_ADDR )#if defined(CONFIG_QE )#include <linux/immap_qe.h> -#define CONFIG_SYS_BOOTCOUNT_ADDR (CONFIG_SYS_IMMR + 0x110000 + \ +#define BOOTCOUNT_ADDR (CONFIG_SYS_IMMR + 0x110000 + \ QE_MURAM_SIZE - 2 *sizeof(u32)) #endif /*
defined(CONFIG_QE)*/drivers/bootcount/bootcount.c +5
-5-#endif /* !defined(CONFIG_SYS_BOOTCOUNT_ADDR) */ +#endif /* !defined(BOOTCOUNT_ADDR) */ /* Now implement the generic default functions */ -#if defined(CONFIG_SYS_BOOTCOUNT_ADDR ) +#if defined(BOOTCOUNT_ADDR )__weak void bootcount_store (ulong a) { -void *reg = (void *)CONFIG_SYS_BOOTCOUNT_ADDR ; +void *reg = (void *)BOOTCOUNT_ADDR ;#if defined(CONFIG_SYS_BOOTCOUNT_SINGLEWORD )raw_bootcount_store (reg, (BOOTCOUNT_MAGIC &0xffff0000 ) | a);@@ -38,7 +38,7 @@ __weak void bootcount_store(ulong a)__weak ulong bootcount_load (void ) { -void *reg = (void *)CONFIG_SYS_BOOTCOUNT_ADDR ; +void *reg = (void *)BOOTCOUNT_ADDR ;#if defined(CONFIG_SYS_BOOTCOUNT_SINGLEWORD )u32 tmp =raw_bootcount_load (reg);@@ -54,4 +54,4 @@ __weak ulong bootcount_load(void)return raw_bootcount_load (reg); #endif /* defined(CONFIG_SYS_BOOTCOUNT_SINGLEWORD) */ } -#endif /* defined(CONFIG_SYS_BOOTCOUNT_ADDR) */ +#endif /* defined(BOOTCOUNT_ADDR) */ (quoted diff) +0
-0
b/drivers/bootcount/bootcount_davinci.cindex 17829be..d00fd7a 100644drivers/bootcount/bootcount_davinci.c +2
-2@@ -15,7 +15,7 @@void bootcount_store (ulong a) {struct davinci_rtc *reg = - (struct davinci_rtc *)CONFIG_SYS_BOOTCOUNT_ADDR ; + (struct davinci_rtc *)BOOTCOUNT_ADDR ;/* * write RTC kick registers to enable write @@ -32,7 +32,7 @@ ulong bootcount_load(void) {unsigned long val;struct davinci_rtc *reg = - (struct davinci_rtc *)CONFIG_SYS_BOOTCOUNT_ADDR ; + (struct davinci_rtc *)BOOTCOUNT_ADDR ; val =raw_bootcount_load (®->scratch2);if ((val &0xffff0000 ) != (BOOTCOUNT_MAGIC &0xffff0000 ))(quoted diff) +0
-0
b/drivers/bootcount/bootcount_ext.cindex e0dd21b..e176ec1 100644drivers/bootcount/bootcount_ext.c +4
-4@@ -22,13 +22,13 @@ void bootcount_store(ulong a)return ; } - buf =map_sysmem (CONFIG_SYS_BOOTCOUNT_ADDR ,2 ); + buf =map_sysmem (BOOTCOUNT_ADDR ,2 ); buf[0 ] =BC_MAGIC ; buf[1 ] = (a &0xff );unmap_sysmem (buf); ret =fs_write (CONFIG_SYS_BOOTCOUNT_EXT_NAME , -CONFIG_SYS_BOOTCOUNT_ADDR ,0 ,2 , &len); +BOOTCOUNT_ADDR ,0 ,2 , &len);if (ret !=0 )puts ("Error storing bootcount\n" ); }@@ -45,14 +45,14 @@ ulong bootcount_load(void)return 0 ; } - ret =fs_read (CONFIG_SYS_BOOTCOUNT_EXT_NAME ,CONFIG_SYS_BOOTCOUNT_ADDR , + ret =fs_read (CONFIG_SYS_BOOTCOUNT_EXT_NAME ,BOOTCOUNT_ADDR ,0 ,2 , &len_read);if (ret !=0 || len_read !=2 ) {puts ("Error loading bootcount\n" );return 0 ; } - buf =map_sysmem (CONFIG_SYS_BOOTCOUNT_ADDR ,2 ); + buf =map_sysmem (BOOTCOUNT_ADDR ,2 );if (buf[0 ] ==BC_MAGIC ) ret = buf[1 ];(quoted diff) +0
-0
b/drivers/bootcount/bootcount_i2c.cindex e27b168..1dba141 100644drivers/bootcount/bootcount_i2c.c +2
-2@@ -18,8 +18,8 @@ void bootcount_store(ulong a) buf[0 ] =BC_MAGIC ; buf[1 ] = (a &0xff ); - ret =i2c_write (CONFIG_SYS_I2C_RTC_ADDR ,CONFIG_SYS_BOOTCOUNT_ADDR , -CONFIG_BOOTCOUNT_ALEN , buf,2 ); + ret =i2c_write (CONFIG_SYS_I2C_RTC_ADDR ,BOOTCOUNT_ADDR , +CONFIG_BOOTCOUNT_ALEN , buf,2 );if (ret !=0 )puts ("Error writing bootcount\n" );}
drivers/bootcount/bootcount_i2c.c +1
-1@@ -29,7 +29,7 @@ ulong bootcount_load(void)unsigned char buf[3 ];int ret; - ret =i2c_read (CONFIG_SYS_I2C_RTC_ADDR ,CONFIG_SYS_BOOTCOUNT_ADDR , + ret =i2c_read (CONFIG_SYS_I2C_RTC_ADDR ,BOOTCOUNT_ADDR ,CONFIG_BOOTCOUNT_ALEN , buf,2 );if (ret !=0 ) {drivers/bootcount/bootcount_i2c.c +0
-0puts ("Error loading bootcount\n" );include/configs/brppt1.h +1
-1@@ -21,7 +21,7 @@#define LCD_BPP LCD_COLOR32/* Bootcount using the RTC block */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x44E3E000 +#define BOOTCOUNT_ADDR 0x44E3E000/* memory */ #define CONFIG_SYS_MALLOC_LEN (5 * 1024 * 1024)include/configs/calimain.h +0
-0@@ -278,7 +278,7 @@#define CONFIG_SYS_INIT_SP_ADDR (0x8001ff00)#define CONFIG_SYS_BOOTCOUNT_LE /* Use little-endian accessors */ -#define
CONFIG_SYS_BOOTCOUNT_ADDRDAVINCI_RTC_BASE+#defineBOOTCOUNT_ADDRDAVINCI_RTC_BASE#ifndef
__ASSEMBLY__
intcalimain_get_osc_freq(void);include/configs/dh_imx6.h +1
-1@@ -47,7 +47,7 @@#define CONFIG_SYS_MALLOC_LEN (4 * SZ_1M)/* Bootcounter */ -#define CONFIG_SYS_BOOTCOUNT_ADDR IRAM_BASE_ADDR +#define BOOTCOUNT_ADDR IRAM_BASE_ADDR#define CONFIG_SYS_BOOTCOUNT_BE /* FEC ethernet */ include/configs/ge_bx50v3.h +1
-1@@ -267,6 +267,6 @@#define CONFIG_BCH -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000 +#define BOOTCOUNT_ADDR 0x7000A000#endif /* __GE_BX50V3_CONFIG_H */ include/configs/highbank.h +0
-0@@ -27,7 +27,7 @@#define CONFIG_CONS_INDEX 0#define CONFIG_SYS_BOOTCOUNT_LE /* Use little-endian accessors */ -#define
CONFIG_SYS_BOOTCOUNT_ADDR0xfff3cf0cinclude/configs/highbank.h +1
-0+#define BOOTCOUNT_ADDR 0xfff3cf0c#define CONFIG_MISC_INIT_R #define CONFIG_SCSI_AHCI_PLAT include/configs/ids8313.h +1
-1@@ -516,7 +516,7 @@/* bootcount support */ #define CONFIG_BOOTCOUNT_ALEN 1 -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x9 +#define BOOTCOUNT_ADDR 0x9#define CONFIG_IMAGE_FORMAT_LEGACY (quoted diff) +0
-0
b/include/configs/km/kmp204x-common.hindex 7f735e0..19627ff 100644include/configs/km/kmp204x-common.h +0
-0@@ -189,7 +189,7 @@ unsigned long get_board_sys_clk(unsigned longdummy); #define
CONFIG_SYS_OR1_PRELIMCONFIG_SYS_QRIO_OR_PRELIM/* QRIO Options */
/* bootcounter in QRIO */
-#defineCONFIG_SYS_BOOTCOUNT_ADDR(CONFIG_SYS_QRIO_BASE+0x20) +#defineBOOTCOUNT_ADDR(CONFIG_SYS_QRIO_BASE+0x20)#define
CONFIG_BOARD_EARLY_INIT_R/* callboard_early_init_r
function */ #defineCONFIG_MISC_INIT_Finclude/configs/mx53ppd.h +1
-1@@ -241,6 +241,6 @@#define CONFIG_VIDEO_IPUV3 #endif -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x7000A000 +#define BOOTCOUNT_ADDR 0x7000A000#endif /* __CONFIG_H */ (quoted diff) +0
-0
b/include/configs/socfpga_is1.hindex 883ffb7..70ff295 100644include/configs/socfpga_is1.h +1
-1@@ -33,7 +33,7 @@* Bootcounter */ /* last 2 lwords in OCRAM */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0xfffffff8 +#define BOOTCOUNT_ADDR 0xfffffff8#define CONFIG_SYS_BOOTCOUNT_BE #endif /* __CONFIG_SOCFPGA_IS1_H__ */ (quoted diff) +0
-0
b/include/configs/socfpga_sr1500.hindex 8c9069c..1fe1d60 100644include/configs/socfpga_sr1500.h +1
-1@@ -32,7 +32,7 @@* Bootcounter */ /* last 2 lwords in OCRAM */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0xfffffff8 +#define BOOTCOUNT_ADDR 0xfffffff8#define CONFIG_SYS_BOOTCOUNT_BE /* Environment setting for SPI flash */ (quoted diff) +0
-0
b/include/configs/ti_am335x_common.hindex 66cacdf..d204809 100644include/configs/ti_am335x_common.h +1
-1@@ -45,7 +45,7 @@* environment to a non-zero value and enable CONFIG_BOOTCOUNT_LIMIT * in the board config. */ -#define CONFIG_SYS_BOOTCOUNT_ADDR 0x44E3E000 +#define BOOTCOUNT_ADDR 0x44E3E000/* * SPL related defines. The Public RAM memory map the ROM defines the diff --git
a/include/configs/tqma6_wru4.hb/include/configs/tqma6_wru4.hindex d94f790..00a2dea 100644include/configs/tqma6_wru4.h +1
-1@@ -34,7 +34,7 @@/* LED */ /* Bootcounter */ -#define CONFIG_SYS_BOOTCOUNT_ADDR IRAM_BASE_ADDR +#define BOOTCOUNT_ADDR IRAM_BASE_ADDR#define CONFIG_SYS_BOOTCOUNT_BE #endif /* __CONFIG_TQMA6_WRU4_H */ include/configs/x600.h +0
-0
include/configs/x600.h line 126
Quoted 8 lines
include/configs/x600.h +0
-1@@ -120,7 +120,7 @@#define CONFIG_SYS_LOAD_ADDR 0x00800000/* Use last 2 lwords in internal SRAM for bootcounter */ -#define CONFIG_SYS_BOOTCOUNT_ADDR (CONFIG_SRAM_BASE + \ +#define BOOTCOUNT_ADDR (CONFIG_SRAM_BASE + \ CONFIG_SRAM_SIZE)#define CONFIG_HOSTNAME x600
Best regards,
Lukasz Majewski
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de -------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180216/29102c82/attachment.sig>
PATCH v2 11/13 Rename CONFIG_SYS_BOOTCOUNT_ADDR to BOOTCOUNT_ADDR
Quoted 4 lines · Lukasz Majewski
Hi Alex,
Please extend the commit message, as for example presented below:
Quoted 9 lines
Quoted 1 line
Remove
CONFIG_SYS_BOOTCOUNT_ADDRfromKconfig.and also introduce
BOOTCOUNT_ADDRas a replacement.
After this change theCONFIG_SYS_BOOTCOUNT_ADDRis completely removed from the u-boot code base.It has been replaced with
BOOTCOUNT_ADDRto preserve current behaviour. This variable is not (yet) introduced toKconfig.
Thanks for the words... I think I was getting a bit tired of the fight with it by that point!
Signature · 1 line
Alex Kiernan
PATCH v2 12/13 Migrate CONFIG_BOOTCOUNT_ALEN to Kconfig
In reply to Alex Kiernan---
Changes in v2: None
drivers/bootcount/Kconfig | 9 ++++++++- include/configs/ids8313.h | 1 - scripts/config_whitelist.txt | 1 - 3 files changed, 8 insertions(+), 3 deletions(-)
drivers/bootcount/Kconfig +8 -1
@@ -66,7 +66,14 @@ config BOOTCOUNT_I2C Enable support for the bootcounter on an i2c (like RTC) device. CONFIG_SYS_I2C_RTC_ADDR = i2c chip address BOOTCOUNT_ADDR = i2c addr which is used for the bootcounter. - CONFIG_BOOTCOUNT_ALEN = address len + +config BOOTCOUNT_ALEN + int "I2C address length" + default 1 + depends on BOOTCOUNT_I2C + help + Length of the the I2C address at BOOTCOUNT_ADDR for storing + the boot counter. config BOOTCOUNT_AT91 bool "Boot counter for Atmel AT91SAM9XE"
include/configs/ids8313.h +0 -1
@@ -515,7 +515,6 @@#define CONFIG_MTD_PARTITIONS /* bootcount support */ -#define CONFIG_BOOTCOUNT_ALEN 1#define BOOTCOUNT_ADDR 0x9#define CONFIG_IMAGE_FORMAT_LEGACY
scripts/config_whitelist.txt +0 -1
@@ -147,7 +147,6 @@ CONFIG_BOARD_TYPES CONFIG_BOOGER CONFIG_BOOM CONFIG_BOOTBLOCK -CONFIG_BOOTCOUNT_ALEN CONFIG_BOOTFILE CONFIG_BOOTMAPSZ CONFIG_BOOTMODE
Signature · 1 line
2.7.4
PATCH v2 12/13 Migrate CONFIG_BOOTCOUNT_ALEN to Kconfig
Hi Alex,
Please add at least one sentence to the commit message (not only the topic).
A side note - I did not received patch 13/13,
It can be found here:
http://patchwork.ozlabs.org/patch/873845/
It is also Ok (as I forgotten to remove SINGLEWORD from whitelist)..
Above patches seems to be eligible to current mailing (rc2+).
The BOOTCOUNT_ADDR conversion would need to wait for merge window, IMHO.
Thanks for your effort,
Best regards,
Łukasz
Quoted 48 lines
Signed-off-by Alex Kiernan <[email protected]>---
Changes in v2: None
drivers/bootcount/Kconfig | 9 ++++++++- include/configs/ids8313.h | 1 - scripts/config_whitelist.txt | 1 - 3 files changed, 8 insertions(+), 3 deletions(-)drivers/bootcount/Kconfig +0
-0@@ -66,7 +66,14 @@ config BOOTCOUNT_I2C Enable support for the bootcounter on an i2c (like RTC)device.
CONFIG_SYS_I2C_RTC_ADDR= i2c chip address
BOOTCOUNT_ADDR= i2c addr which is used for the
bootcounter.drivers/bootcount/Kconfig +8
-1- CONFIG_BOOTCOUNT_ALEN = address len + +config BOOTCOUNT_ALEN + int "I2C address length" + default 1 + depends on BOOTCOUNT_I2C + help + Length of the the I2C address at BOOTCOUNT_ADDR for storing + the boot counter. config BOOTCOUNT_AT91 bool "Boot counter for Atmel AT91SAM9XE"include/configs/ids8313.h +0
-1@@ -515,7 +515,6 @@#define CONFIG_MTD_PARTITIONS /* bootcount support */ -#define CONFIG_BOOTCOUNT_ALEN 1#define BOOTCOUNT_ADDR 0x9#define CONFIG_IMAGE_FORMAT_LEGACY (quoted diff) +0
-0
b/scripts/config_whitelist.txtindex a8380c6..e16085b 100644
scripts/config_whitelist.txt CONFIG_BOARD_TYPES · line 152
Quoted 7 lines
scripts/config_whitelist.txt +0
-1@@ -147,7 +147,6 @@ CONFIG_BOARD_TYPES CONFIG_BOOGER CONFIG_BOOM CONFIG_BOOTBLOCK -CONFIG_BOOTCOUNT_ALEN CONFIG_BOOTFILE CONFIG_BOOTMAPSZ CONFIG_BOOTMODE
Best regards,
Lukasz Majewski
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de -------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180216/3bd3a918/attachment.sig>
PATCH v2 12/13 Migrate CONFIG_BOOTCOUNT_ALEN to Kconfig
Quoted 5 lines · Lukasz Majewski
Hi Alex,
Please add at least one sentence to the commit message (not only the topic).
Sure.
Quoted 11 lines
A side note - I did not received patch 13/13,
It can be found here:
http://patchwork.ozlabs.org/patch/873845/It is also Ok (as I forgotten to remove SINGLEWORD from whitelist)..
Above patches seems to be eligible to current mailing (rc2+).
The
BOOTCOUNT_ADDRconversion would need to wait for merge window, IMHO.
I'll split the pieces apart and get the non-BOOTCOUNT_ADDR part out.
Signature · 1 line
Alex Kiernan
PATCH v2 13/13 Remove CONFIG_SYS_BOOTCOUNT_SINGLEWORD
In reply to Alex KiernanTidy up CONFIG_SYS_BOOTCOUNT_SINGLEWORD from the whitelist as there's no remaining uses of it left.
---
Changes in v2: None
scripts/config_whitelist.txt | 1 - 1 file changed, 1 deletion(-)
scripts/config_whitelist.txt +0 -1
@@ -2222,7 +2222,6 @@ CONFIG_SYS_BOARD_VERSION CONFIG_SYS_BOOK3E_HV CONFIG_SYS_BOOTCOUNT_BE CONFIG_SYS_BOOTCOUNT_LE -CONFIG_SYS_BOOTCOUNT_SINGLEWORD CONFIG_SYS_BOOTFILE_PREFIX CONFIG_SYS_BOOTMAPSZ CONFIG_SYS_BOOTM_LEN
Signature · 1 line
2.7.4