[U-Boot] [PATCH v2 0/4] Convert Watchdog related defines to Kconfig

This patch series converts watchdog related configs: CONFIG_HW_WATCHDOG, CONFIG_IMX_WATCHDOG and CONFIG_WATCHDOG_TIMEOUT_MSECS to Kconfig.
This is the first step to move iMX Watchdog driver to DM.
Comments and tests are welcome.
"Green" travis CI build: https://travis-ci.org/lmajewski/u-boot-dfu/builds/338077474
This patch has been applied on top of u-boot/master: SHA1: a43aebee89acf57b4e22018f401cffc9fef4fd85
Changes in v2: - None - Correct "mili" to "milli" seconds - None - None
Lukasz Majewski (4): Convert CONFIG_IMX_WATCHDOG to Kconfig and remove HW_WATCHDOG Convert CONFIG_WATCHDOG_TIMEOUT_MSECS to Kconfig Convert socfpga: select CONFIG_HW_WATCHDOG support for ARCH_SOCFPGA Convert CONFIG_HW_WATCHDOG to Kconfig
arch/arm/Kconfig | 1 + configs/aristainetos2_defconfig | 1 + configs/aristainetos2b_defconfig | 1 + configs/aristainetos_defconfig | 1 + configs/axm_defconfig | 1 + configs/calimain_defconfig | 1 + configs/dh_imx6_defconfig | 2 ++ configs/microblaze-generic_defconfig | 1 + configs/mx53ppd_defconfig | 2 ++ configs/nokia_rx51_defconfig | 1 + configs/picosam9g45_defconfig | 1 + configs/smartweb_defconfig | 1 + configs/taurus_defconfig | 1 + configs/tqma6s_wru4_mmc_defconfig | 2 ++ configs/ts4800_defconfig | 1 + configs/warp_defconfig | 2 ++ drivers/watchdog/Kconfig | 14 ++++++++++++++ include/configs/M5475EVB.h | 1 - include/configs/M5485EVB.h | 1 - include/configs/aristainetos-common.h | 3 --- include/configs/calimain.h | 1 - include/configs/controlcenterd.h | 1 - include/configs/dh_imx6.h | 5 ----- include/configs/eb_cpu5282.h | 2 -- include/configs/microblaze-generic.h | 1 - include/configs/mx53ppd.h | 4 ---- include/configs/nokia_rx51.h | 1 - include/configs/picosam9g45.h | 1 - include/configs/smartweb.h | 3 --- include/configs/socfpga_arria10_socdk.h | 2 -- include/configs/socfpga_arria5_socdk.h | 2 -- include/configs/socfpga_common.h | 1 - include/configs/socfpga_cyclone5_socdk.h | 2 -- include/configs/socfpga_de0_nano_soc.h | 2 -- include/configs/socfpga_de10_nano.h | 2 -- include/configs/socfpga_de1_soc.h | 2 -- include/configs/socfpga_is1.h | 2 -- include/configs/socfpga_mcvevk.h | 2 -- include/configs/socfpga_sockit.h | 2 -- include/configs/socfpga_socrates.h | 2 -- include/configs/socfpga_sr1500.h | 2 -- include/configs/socfpga_vining_fpga.h | 2 -- include/configs/taurus.h | 1 - include/configs/tqma6_wru4.h | 5 ----- include/configs/ts4800.h | 2 -- include/configs/warp.h | 5 ----- 46 files changed, 34 insertions(+), 62 deletions(-)

This converts the following to Kconfig: CONFIG_IMX_WATCHDOG
It also removes the CONFIG_HW_WATCHDOG, which is selected by IMX_WATCHDOG.
Signed-off-by: Lukasz Majewski lukma@denx.de ---
Changes in v2: - None
configs/aristainetos2_defconfig | 1 + configs/aristainetos2b_defconfig | 1 + configs/aristainetos_defconfig | 1 + configs/dh_imx6_defconfig | 1 + configs/mx53ppd_defconfig | 1 + configs/tqma6s_wru4_mmc_defconfig | 1 + configs/warp_defconfig | 1 + drivers/watchdog/Kconfig | 6 ++++++ include/configs/aristainetos-common.h | 3 --- include/configs/dh_imx6.h | 2 -- include/configs/mx53ppd.h | 2 -- include/configs/tqma6_wru4.h | 2 -- include/configs/warp.h | 2 -- 13 files changed, 13 insertions(+), 11 deletions(-)
diff --git a/configs/aristainetos2_defconfig b/configs/aristainetos2_defconfig index c0daed6b22..f9ce68cbb2 100644 --- a/configs/aristainetos2_defconfig +++ b/configs/aristainetos2_defconfig @@ -44,4 +44,5 @@ CONFIG_USB=y CONFIG_USB_STORAGE=y CONFIG_VIDEO=y # CONFIG_VIDEO_SW_CURSOR is not set +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/configs/aristainetos2b_defconfig b/configs/aristainetos2b_defconfig index fbb2c1c38d..6eb9eb030f 100644 --- a/configs/aristainetos2b_defconfig +++ b/configs/aristainetos2b_defconfig @@ -44,4 +44,5 @@ CONFIG_USB=y CONFIG_USB_STORAGE=y CONFIG_VIDEO=y # CONFIG_VIDEO_SW_CURSOR is not set +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/configs/aristainetos_defconfig b/configs/aristainetos_defconfig index 13f4d6eb52..c7f1779763 100644 --- a/configs/aristainetos_defconfig +++ b/configs/aristainetos_defconfig @@ -42,4 +42,5 @@ CONFIG_USB=y CONFIG_USB_STORAGE=y CONFIG_VIDEO=y # CONFIG_VIDEO_SW_CURSOR is not set +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/configs/dh_imx6_defconfig b/configs/dh_imx6_defconfig index 1fd7c50e31..48c5c7027a 100644 --- a/configs/dh_imx6_defconfig +++ b/configs/dh_imx6_defconfig @@ -56,4 +56,5 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0525 CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5 CONFIG_CI_UDC=y CONFIG_USB_GADGET_DOWNLOAD=y +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/configs/mx53ppd_defconfig b/configs/mx53ppd_defconfig index 3fbca2a08c..1458b93144 100644 --- a/configs/mx53ppd_defconfig +++ b/configs/mx53ppd_defconfig @@ -29,4 +29,5 @@ CONFIG_USB=y CONFIG_USB_STORAGE=y CONFIG_VIDEO=y # CONFIG_VIDEO_SW_CURSOR is not set +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/configs/tqma6s_wru4_mmc_defconfig b/configs/tqma6s_wru4_mmc_defconfig index 4cf6693f5c..e30b7c5970 100644 --- a/configs/tqma6s_wru4_mmc_defconfig +++ b/configs/tqma6s_wru4_mmc_defconfig @@ -57,4 +57,5 @@ CONFIG_USB=y CONFIG_USB_STORAGE=y CONFIG_USB_HOST_ETHER=y CONFIG_USB_ETHER_SMSC95XX=y +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/configs/warp_defconfig b/configs/warp_defconfig index 2ac1c6cef7..0aa7aeb57d 100644 --- a/configs/warp_defconfig +++ b/configs/warp_defconfig @@ -34,4 +34,5 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0525 CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5 CONFIG_CI_UDC=y CONFIG_USB_GADGET_DOWNLOAD=y +CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig index fc46b6774d..067d3915ae 100644 --- a/drivers/watchdog/Kconfig +++ b/drivers/watchdog/Kconfig @@ -12,6 +12,12 @@ config BCM2835_WDT This provides basic infrastructure to support BCM2835/2836 watchdog hardware, with a max timeout of ~15secs.
+config IMX_WATCHDOG + bool "IMX watchdog driver" + select HW_WATCHDOG + help + Say Y here to enable the IMX watchdog driver. + config OMAP_WATCHDOG bool "TI OMAP watchdog driver" depends on ARCH_OMAP2PLUS diff --git a/include/configs/aristainetos-common.h b/include/configs/aristainetos-common.h index 69de44a1df..cf60eebd5f 100644 --- a/include/configs/aristainetos-common.h +++ b/include/configs/aristainetos-common.h @@ -198,9 +198,6 @@ #define CONFIG_MTD_PARTITIONS #define CONFIG_MTD_DEVICE
-#define CONFIG_HW_WATCHDOG -#define CONFIG_IMX_WATCHDOG - /* Framebuffer */ #define CONFIG_VIDEO_IPUV3 /* check this console not needed, after test remove it */ diff --git a/include/configs/dh_imx6.h b/include/configs/dh_imx6.h index 7cda878ac7..45cb030c50 100644 --- a/include/configs/dh_imx6.h +++ b/include/configs/dh_imx6.h @@ -123,8 +123,6 @@ #endif
/* Watchdog */ -#define CONFIG_HW_WATCHDOG -#define CONFIG_IMX_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT_MSECS 60000
/* allow to overwrite serial and ethaddr */ diff --git a/include/configs/mx53ppd.h b/include/configs/mx53ppd.h index 05c3d529af..034c92b373 100644 --- a/include/configs/mx53ppd.h +++ b/include/configs/mx53ppd.h @@ -23,8 +23,6 @@ /* Size of malloc() pool */ #define CONFIG_SYS_MALLOC_LEN (10 * 1024 * 1024)
-#define CONFIG_HW_WATCHDOG -#define CONFIG_IMX_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT_MSECS 8000
#define CONFIG_MISC_INIT_R diff --git a/include/configs/tqma6_wru4.h b/include/configs/tqma6_wru4.h index 4e99cdbb59..f35a048209 100644 --- a/include/configs/tqma6_wru4.h +++ b/include/configs/tqma6_wru4.h @@ -20,8 +20,6 @@ #define CONFIG_MISC_INIT_R
/* Watchdog */ -#define CONFIG_HW_WATCHDOG -#define CONFIG_IMX_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT_MSECS 60000
/* Config on-board RTC */ diff --git a/include/configs/warp.h b/include/configs/warp.h index 77af0d46e7..e5421d1930 100644 --- a/include/configs/warp.h +++ b/include/configs/warp.h @@ -27,8 +27,6 @@ #define CONFIG_SUPPORT_EMMC_BOOT
/* Watchdog */ -#define CONFIG_HW_WATCHDOG -#define CONFIG_IMX_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT_MSECS 30000 /* 30s */
#define CONFIG_SYS_MEMTEST_START 0x80000000

Hello Lukasz,
Am 09.02.2018 um 23:14 schrieb Lukasz Majewski:
This converts the following to Kconfig: CONFIG_IMX_WATCHDOG
It also removes the CONFIG_HW_WATCHDOG, which is selected by IMX_WATCHDOG.
Signed-off-by: Lukasz Majewski lukma@denx.de
Changes in v2:
None
configs/aristainetos2_defconfig | 1 + configs/aristainetos2b_defconfig | 1 + configs/aristainetos_defconfig | 1 + configs/dh_imx6_defconfig | 1 + configs/mx53ppd_defconfig | 1 + configs/tqma6s_wru4_mmc_defconfig | 1 + configs/warp_defconfig | 1 + drivers/watchdog/Kconfig | 6 ++++++ include/configs/aristainetos-common.h | 3 --- include/configs/dh_imx6.h | 2 -- include/configs/mx53ppd.h | 2 -- include/configs/tqma6_wru4.h | 2 -- include/configs/warp.h | 2 -- 13 files changed, 13 insertions(+), 11 deletions(-)
Thanks!
Reviewed-by: Heiko Schocherhs@denx.de
bye, Heiko

This converts the following to Kconfig: CONFIG_WATCHDOG_TIMEOUT_MSECS
The CONFIG_WATCHDOG_TIMEOUT_MSECS default value has been set to 10s.
Signed-off-by: Lukasz Majewski lukma@denx.de ---
Changes in v2: - Correct "mili" to "milli" seconds
configs/dh_imx6_defconfig | 1 + configs/mx53ppd_defconfig | 1 + configs/tqma6s_wru4_mmc_defconfig | 1 + configs/warp_defconfig | 1 + drivers/watchdog/Kconfig | 8 ++++++++ include/configs/dh_imx6.h | 3 --- include/configs/mx53ppd.h | 2 -- include/configs/socfpga_common.h | 1 - include/configs/tqma6_wru4.h | 3 --- include/configs/warp.h | 3 --- 10 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/configs/dh_imx6_defconfig b/configs/dh_imx6_defconfig index 48c5c7027a..0e7df6b10a 100644 --- a/configs/dh_imx6_defconfig +++ b/configs/dh_imx6_defconfig @@ -58,3 +58,4 @@ CONFIG_CI_UDC=y CONFIG_USB_GADGET_DOWNLOAD=y CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y +CONFIG_WATCHDOG_TIMEOUT_MSECS=60000 diff --git a/configs/mx53ppd_defconfig b/configs/mx53ppd_defconfig index 1458b93144..64dee33045 100644 --- a/configs/mx53ppd_defconfig +++ b/configs/mx53ppd_defconfig @@ -31,3 +31,4 @@ CONFIG_VIDEO=y # CONFIG_VIDEO_SW_CURSOR is not set CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y +CONFIG_WATCHDOG_TIMEOUT_MSECS=8000 diff --git a/configs/tqma6s_wru4_mmc_defconfig b/configs/tqma6s_wru4_mmc_defconfig index e30b7c5970..4e1be700e8 100644 --- a/configs/tqma6s_wru4_mmc_defconfig +++ b/configs/tqma6s_wru4_mmc_defconfig @@ -59,3 +59,4 @@ CONFIG_USB_HOST_ETHER=y CONFIG_USB_ETHER_SMSC95XX=y CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y +CONFIG_WATCHDOG_TIMEOUT_MSECS=60000 diff --git a/configs/warp_defconfig b/configs/warp_defconfig index 0aa7aeb57d..891d00e7e3 100644 --- a/configs/warp_defconfig +++ b/configs/warp_defconfig @@ -36,3 +36,4 @@ CONFIG_CI_UDC=y CONFIG_USB_GADGET_DOWNLOAD=y CONFIG_IMX_WATCHDOG=y CONFIG_OF_LIBFDT=y +CONFIG_WATCHDOG_TIMEOUT_MSECS=30000 diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig index 067d3915ae..b223bef29c 100644 --- a/drivers/watchdog/Kconfig +++ b/drivers/watchdog/Kconfig @@ -40,6 +40,14 @@ config ULP_WATCHDOG help Say Y here to enable i.MX7ULP watchdog driver.
+config WATCHDOG_TIMEOUT_MSECS + int "Specify watchdog timeout in milli seconds" + default 30000 if ARCH_SOCFPGA + default 10000 + depends on HW_WATCHDOG + help + Set watchdog trigger timeout (in [ms]). + config WDT bool "Enable driver model for watchdog timer drivers" depends on DM diff --git a/include/configs/dh_imx6.h b/include/configs/dh_imx6.h index 45cb030c50..00d83384da 100644 --- a/include/configs/dh_imx6.h +++ b/include/configs/dh_imx6.h @@ -122,9 +122,6 @@ #endif #endif
-/* Watchdog */ -#define CONFIG_WATCHDOG_TIMEOUT_MSECS 60000 - /* allow to overwrite serial and ethaddr */ #define CONFIG_ENV_OVERWRITE
diff --git a/include/configs/mx53ppd.h b/include/configs/mx53ppd.h index 034c92b373..1fc9e15cf0 100644 --- a/include/configs/mx53ppd.h +++ b/include/configs/mx53ppd.h @@ -23,8 +23,6 @@ /* Size of malloc() pool */ #define CONFIG_SYS_MALLOC_LEN (10 * 1024 * 1024)
-#define CONFIG_WATCHDOG_TIMEOUT_MSECS 8000 - #define CONFIG_MISC_INIT_R #define CONFIG_BOARD_LATE_INIT #define CONFIG_REVISION_TAG diff --git a/include/configs/socfpga_common.h b/include/configs/socfpga_common.h index bbc1f3de9b..7cde63e4ad 100644 --- a/include/configs/socfpga_common.h +++ b/include/configs/socfpga_common.h @@ -120,7 +120,6 @@ #define CONFIG_DESIGNWARE_WATCHDOG #define CONFIG_DW_WDT_BASE SOCFPGA_L4WD0_ADDRESS #define CONFIG_DW_WDT_CLOCK_KHZ 25000 -#define CONFIG_WATCHDOG_TIMEOUT_MSECS 30000 #endif
/* diff --git a/include/configs/tqma6_wru4.h b/include/configs/tqma6_wru4.h index f35a048209..41dd192e5d 100644 --- a/include/configs/tqma6_wru4.h +++ b/include/configs/tqma6_wru4.h @@ -19,9 +19,6 @@
#define CONFIG_MISC_INIT_R
-/* Watchdog */ -#define CONFIG_WATCHDOG_TIMEOUT_MSECS 60000 - /* Config on-board RTC */ #define CONFIG_RTC_DS1337 #define CONFIG_SYS_RTC_BUS_NUM 2 diff --git a/include/configs/warp.h b/include/configs/warp.h index e5421d1930..dc0ee391bf 100644 --- a/include/configs/warp.h +++ b/include/configs/warp.h @@ -26,9 +26,6 @@ #define CONFIG_SYS_FSL_ESDHC_HAS_DDR_MODE #define CONFIG_SUPPORT_EMMC_BOOT
-/* Watchdog */ -#define CONFIG_WATCHDOG_TIMEOUT_MSECS 30000 /* 30s */ - #define CONFIG_SYS_MEMTEST_START 0x80000000 #define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + SZ_256M)

Hello Lukasz,
Am 09.02.2018 um 23:14 schrieb Lukasz Majewski:
This converts the following to Kconfig: CONFIG_WATCHDOG_TIMEOUT_MSECS
The CONFIG_WATCHDOG_TIMEOUT_MSECS default value has been set to 10s.
Signed-off-by: Lukasz Majewski lukma@denx.de
Changes in v2:
Correct "mili" to "milli" seconds
configs/dh_imx6_defconfig | 1 + configs/mx53ppd_defconfig | 1 + configs/tqma6s_wru4_mmc_defconfig | 1 + configs/warp_defconfig | 1 + drivers/watchdog/Kconfig | 8 ++++++++ include/configs/dh_imx6.h | 3 --- include/configs/mx53ppd.h | 2 -- include/configs/socfpga_common.h | 1 - include/configs/tqma6_wru4.h | 3 --- include/configs/warp.h | 3 --- 10 files changed, 12 insertions(+), 12 deletions(-)
Thanks!
Reviewed-by: Heiko Schocherhs@denx.de
bye, Heiko

All Socfpga boards from ./include/configs/socfpga_* define CONFIG_HW_WATCHDOG. To ease CONFIG_HW_WATCHDOG conversion to Kconfig select it in config ARCH_SOCFPGA (arch/arm/Kconfig) section.
Signed-off-by: Lukasz Majewski lukma@denx.de ---
Changes in v2: - None
arch/arm/Kconfig | 1 + include/configs/socfpga_arria10_socdk.h | 2 -- include/configs/socfpga_arria5_socdk.h | 2 -- include/configs/socfpga_cyclone5_socdk.h | 2 -- include/configs/socfpga_de0_nano_soc.h | 2 -- include/configs/socfpga_de10_nano.h | 2 -- include/configs/socfpga_de1_soc.h | 2 -- include/configs/socfpga_is1.h | 2 -- include/configs/socfpga_mcvevk.h | 2 -- include/configs/socfpga_sockit.h | 2 -- include/configs/socfpga_socrates.h | 2 -- include/configs/socfpga_sr1500.h | 2 -- include/configs/socfpga_vining_fpga.h | 2 -- 13 files changed, 1 insertion(+), 24 deletions(-)
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 225f57e847..b4c79d6499 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -702,6 +702,7 @@ config ARCH_SOCFPGA select DM_SPI_FLASH select DM_SPI select ENABLE_ARM_SOC_BOOT0_HOOK + select HW_WATCHDOG select ARCH_EARLY_INIT_R select ARCH_MISC_INIT select SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION diff --git a/include/configs/socfpga_arria10_socdk.h b/include/configs/socfpga_arria10_socdk.h index 83718dd2c9..82bb48b277 100644 --- a/include/configs/socfpga_arria10_socdk.h +++ b/include/configs/socfpga_arria10_socdk.h @@ -9,8 +9,6 @@
#include <asm/arch/base_addr_a10.h>
-#define CONFIG_HW_WATCHDOG - /* Booting Linux */ #define CONFIG_LOADADDR 0x01000000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR diff --git a/include/configs/socfpga_arria5_socdk.h b/include/configs/socfpga_arria5_socdk.h index 6b6d54b97b..cd5aac65e9 100644 --- a/include/configs/socfpga_arria5_socdk.h +++ b/include/configs/socfpga_arria5_socdk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCDK */
diff --git a/include/configs/socfpga_cyclone5_socdk.h b/include/configs/socfpga_cyclone5_socdk.h index 018a0c3bb4..9c5bd648e3 100644 --- a/include/configs/socfpga_cyclone5_socdk.h +++ b/include/configs/socfpga_cyclone5_socdk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCDK */
diff --git a/include/configs/socfpga_de0_nano_soc.h b/include/configs/socfpga_de0_nano_soc.h index 275ed7ffeb..e5db00e366 100644 --- a/include/configs/socfpga_de0_nano_soc.h +++ b/include/configs/socfpga_de0_nano_soc.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB */
diff --git a/include/configs/socfpga_de10_nano.h b/include/configs/socfpga_de10_nano.h index bb50fcf1ff..656af1104d 100644 --- a/include/configs/socfpga_de10_nano.h +++ b/include/configs/socfpga_de10_nano.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB */
diff --git a/include/configs/socfpga_de1_soc.h b/include/configs/socfpga_de1_soc.h index 05975c9bde..f57b950425 100644 --- a/include/configs/socfpga_de1_soc.h +++ b/include/configs/socfpga_de1_soc.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB */
diff --git a/include/configs/socfpga_is1.h b/include/configs/socfpga_is1.h index 46f5f135dd..dc318e50dc 100644 --- a/include/configs/socfpga_is1.h +++ b/include/configs/socfpga_is1.h @@ -9,8 +9,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x10000000
diff --git a/include/configs/socfpga_mcvevk.h b/include/configs/socfpga_mcvevk.h index 404f064e94..f13463b8b0 100644 --- a/include/configs/socfpga_mcvevk.h +++ b/include/configs/socfpga_mcvevk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on MCV */
diff --git a/include/configs/socfpga_sockit.h b/include/configs/socfpga_sockit.h index b4f31c42c5..0bbc7e0105 100644 --- a/include/configs/socfpga_sockit.h +++ b/include/configs/socfpga_sockit.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCDK */
diff --git a/include/configs/socfpga_socrates.h b/include/configs/socfpga_socrates.h index ebb9ac588d..b66108d0cc 100644 --- a/include/configs/socfpga_socrates.h +++ b/include/configs/socfpga_socrates.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCrates */
diff --git a/include/configs/socfpga_sr1500.h b/include/configs/socfpga_sr1500.h index 39bf612291..871f587d45 100644 --- a/include/configs/socfpga_sr1500.h +++ b/include/configs/socfpga_sr1500.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SR1500 */
diff --git a/include/configs/socfpga_vining_fpga.h b/include/configs/socfpga_vining_fpga.h index 0c76a77525..1197b40b58 100644 --- a/include/configs/socfpga_vining_fpga.h +++ b/include/configs/socfpga_vining_fpga.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG - /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on VINING_FPGA */

On 09.02.2018 23:14, Lukasz Majewski wrote:
All Socfpga boards from ./include/configs/socfpga_* define CONFIG_HW_WATCHDOG. To ease CONFIG_HW_WATCHDOG conversion to Kconfig select it in config ARCH_SOCFPGA (arch/arm/Kconfig) section.
I do have board configs where the internal watchdog is not used and should be disabled (because there's an external one). Also, given that this is an FPGA, I suppose having non-upstreamed boards is not uncommon.
I'm not too familiar with these settings though: can I leave the watchdog disabled when CONFIG_HW_WATCHDOG is off? Before, I just haven't enabled this in my own board config...
Simon
Signed-off-by: Lukasz Majewski lukma@denx.de
Changes in v2:
None
arch/arm/Kconfig | 1 + include/configs/socfpga_arria10_socdk.h | 2 -- include/configs/socfpga_arria5_socdk.h | 2 -- include/configs/socfpga_cyclone5_socdk.h | 2 -- include/configs/socfpga_de0_nano_soc.h | 2 -- include/configs/socfpga_de10_nano.h | 2 -- include/configs/socfpga_de1_soc.h | 2 -- include/configs/socfpga_is1.h | 2 -- include/configs/socfpga_mcvevk.h | 2 -- include/configs/socfpga_sockit.h | 2 -- include/configs/socfpga_socrates.h | 2 -- include/configs/socfpga_sr1500.h | 2 -- include/configs/socfpga_vining_fpga.h | 2 -- 13 files changed, 1 insertion(+), 24 deletions(-)
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 225f57e847..b4c79d6499 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -702,6 +702,7 @@ config ARCH_SOCFPGA select DM_SPI_FLASH select DM_SPI select ENABLE_ARM_SOC_BOOT0_HOOK
- select HW_WATCHDOG select ARCH_EARLY_INIT_R select ARCH_MISC_INIT select SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
diff --git a/include/configs/socfpga_arria10_socdk.h b/include/configs/socfpga_arria10_socdk.h index 83718dd2c9..82bb48b277 100644 --- a/include/configs/socfpga_arria10_socdk.h +++ b/include/configs/socfpga_arria10_socdk.h @@ -9,8 +9,6 @@
#include <asm/arch/base_addr_a10.h>
-#define CONFIG_HW_WATCHDOG
- /* Booting Linux */ #define CONFIG_LOADADDR 0x01000000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
diff --git a/include/configs/socfpga_arria5_socdk.h b/include/configs/socfpga_arria5_socdk.h index 6b6d54b97b..cd5aac65e9 100644 --- a/include/configs/socfpga_arria5_socdk.h +++ b/include/configs/socfpga_arria5_socdk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCDK */
diff --git a/include/configs/socfpga_cyclone5_socdk.h b/include/configs/socfpga_cyclone5_socdk.h index 018a0c3bb4..9c5bd648e3 100644 --- a/include/configs/socfpga_cyclone5_socdk.h +++ b/include/configs/socfpga_cyclone5_socdk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCDK */
diff --git a/include/configs/socfpga_de0_nano_soc.h b/include/configs/socfpga_de0_nano_soc.h index 275ed7ffeb..e5db00e366 100644 --- a/include/configs/socfpga_de0_nano_soc.h +++ b/include/configs/socfpga_de0_nano_soc.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB */
diff --git a/include/configs/socfpga_de10_nano.h b/include/configs/socfpga_de10_nano.h index bb50fcf1ff..656af1104d 100644 --- a/include/configs/socfpga_de10_nano.h +++ b/include/configs/socfpga_de10_nano.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB */
diff --git a/include/configs/socfpga_de1_soc.h b/include/configs/socfpga_de1_soc.h index 05975c9bde..f57b950425 100644 --- a/include/configs/socfpga_de1_soc.h +++ b/include/configs/socfpga_de1_soc.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB */
diff --git a/include/configs/socfpga_is1.h b/include/configs/socfpga_is1.h index 46f5f135dd..dc318e50dc 100644 --- a/include/configs/socfpga_is1.h +++ b/include/configs/socfpga_is1.h @@ -9,8 +9,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x10000000
diff --git a/include/configs/socfpga_mcvevk.h b/include/configs/socfpga_mcvevk.h index 404f064e94..f13463b8b0 100644 --- a/include/configs/socfpga_mcvevk.h +++ b/include/configs/socfpga_mcvevk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on MCV */
diff --git a/include/configs/socfpga_sockit.h b/include/configs/socfpga_sockit.h index b4f31c42c5..0bbc7e0105 100644 --- a/include/configs/socfpga_sockit.h +++ b/include/configs/socfpga_sockit.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCDK */
diff --git a/include/configs/socfpga_socrates.h b/include/configs/socfpga_socrates.h index ebb9ac588d..b66108d0cc 100644 --- a/include/configs/socfpga_socrates.h +++ b/include/configs/socfpga_socrates.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SoCrates */
diff --git a/include/configs/socfpga_sr1500.h b/include/configs/socfpga_sr1500.h index 39bf612291..871f587d45 100644 --- a/include/configs/socfpga_sr1500.h +++ b/include/configs/socfpga_sr1500.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on SR1500 */
diff --git a/include/configs/socfpga_vining_fpga.h b/include/configs/socfpga_vining_fpga.h index 0c76a77525..1197b40b58 100644 --- a/include/configs/socfpga_vining_fpga.h +++ b/include/configs/socfpga_vining_fpga.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1GiB on VINING_FPGA */

Hi Simon,
On 09.02.2018 23:14, Lukasz Majewski wrote:
All Socfpga boards from ./include/configs/socfpga_* define CONFIG_HW_WATCHDOG. To ease CONFIG_HW_WATCHDOG conversion to Kconfig select it in config ARCH_SOCFPGA (arch/arm/Kconfig) section.
I do have board configs where the internal watchdog is not used and should be disabled (because there's an external one). Also, given that this is an FPGA, I suppose having non-upstreamed boards is not uncommon.
I must admit that this patch I did after looking on the socfpga pattern in the current upstream.
It seems like all boards there use HW_WATCHDOG.
I'm not too familiar with these settings though: can I leave the watchdog disabled when CONFIG_HW_WATCHDOG is off? Before, I just haven't enabled this in my own board config...
I think that I will prepare next revision of this patch with just simple ./tools/moveconfig.py output (without blindly selecting HW_WATCHDOG on all socfpga devices).
In that way we will preserve the current behaviour.
Best regards, Łukasz Majewski
Simon
Signed-off-by: Lukasz Majewski lukma@denx.de
Changes in v2:
None
arch/arm/Kconfig | 1 + include/configs/socfpga_arria10_socdk.h | 2 -- include/configs/socfpga_arria5_socdk.h | 2 -- include/configs/socfpga_cyclone5_socdk.h | 2 -- include/configs/socfpga_de0_nano_soc.h | 2 -- include/configs/socfpga_de10_nano.h | 2 -- include/configs/socfpga_de1_soc.h | 2 -- include/configs/socfpga_is1.h | 2 -- include/configs/socfpga_mcvevk.h | 2 -- include/configs/socfpga_sockit.h | 2 -- include/configs/socfpga_socrates.h | 2 -- include/configs/socfpga_sr1500.h | 2 -- include/configs/socfpga_vining_fpga.h | 2 -- 13 files changed, 1 insertion(+), 24 deletions(-)
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 225f57e847..b4c79d6499 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -702,6 +702,7 @@ config ARCH_SOCFPGA select DM_SPI_FLASH select DM_SPI select ENABLE_ARM_SOC_BOOT0_HOOK
- select HW_WATCHDOG select ARCH_EARLY_INIT_R select ARCH_MISC_INIT select SYS_MMCSD_RAW_MODE_U_BOOT_USE_PARTITION
diff --git a/include/configs/socfpga_arria10_socdk.h b/include/configs/socfpga_arria10_socdk.h index 83718dd2c9..82bb48b277 100644 --- a/include/configs/socfpga_arria10_socdk.h +++ b/include/configs/socfpga_arria10_socdk.h @@ -9,8 +9,6 @@
#include <asm/arch/base_addr_a10.h>
-#define CONFIG_HW_WATCHDOG
- /* Booting Linux */ #define CONFIG_LOADADDR 0x01000000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
diff --git a/include/configs/socfpga_arria5_socdk.h b/include/configs/socfpga_arria5_socdk.h index 6b6d54b97b..cd5aac65e9 100644 --- a/include/configs/socfpga_arria5_socdk.h +++ b/include/configs/socfpga_arria5_socdk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on SoCDK */ diff --git a/include/configs/socfpga_cyclone5_socdk.h b/include/configs/socfpga_cyclone5_socdk.h index 018a0c3bb4..9c5bd648e3 100644 --- a/include/configs/socfpga_cyclone5_socdk.h +++ b/include/configs/socfpga_cyclone5_socdk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on SoCDK */ diff --git a/include/configs/socfpga_de0_nano_soc.h b/include/configs/socfpga_de0_nano_soc.h index 275ed7ffeb..e5db00e366 100644 --- a/include/configs/socfpga_de0_nano_soc.h +++ b/include/configs/socfpga_de0_nano_soc.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB */ diff --git a/include/configs/socfpga_de10_nano.h b/include/configs/socfpga_de10_nano.h index bb50fcf1ff..656af1104d 100644 --- a/include/configs/socfpga_de10_nano.h +++ b/include/configs/socfpga_de10_nano.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB */ diff --git a/include/configs/socfpga_de1_soc.h b/include/configs/socfpga_de1_soc.h index 05975c9bde..f57b950425 100644 --- a/include/configs/socfpga_de1_soc.h +++ b/include/configs/socfpga_de1_soc.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB */ diff --git a/include/configs/socfpga_is1.h b/include/configs/socfpga_is1.h index 46f5f135dd..dc318e50dc 100644 --- a/include/configs/socfpga_is1.h +++ b/include/configs/socfpga_is1.h @@ -9,8 +9,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x10000000
diff --git a/include/configs/socfpga_mcvevk.h b/include/configs/socfpga_mcvevk.h index 404f064e94..f13463b8b0 100644 --- a/include/configs/socfpga_mcvevk.h +++ b/include/configs/socfpga_mcvevk.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on MCV */ diff --git a/include/configs/socfpga_sockit.h b/include/configs/socfpga_sockit.h index b4f31c42c5..0bbc7e0105 100644 --- a/include/configs/socfpga_sockit.h +++ b/include/configs/socfpga_sockit.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on SoCDK */ diff --git a/include/configs/socfpga_socrates.h b/include/configs/socfpga_socrates.h index ebb9ac588d..b66108d0cc 100644 --- a/include/configs/socfpga_socrates.h +++ b/include/configs/socfpga_socrates.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on SoCrates */ diff --git a/include/configs/socfpga_sr1500.h b/include/configs/socfpga_sr1500.h index 39bf612291..871f587d45 100644 --- a/include/configs/socfpga_sr1500.h +++ b/include/configs/socfpga_sr1500.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on SR1500 */ diff --git a/include/configs/socfpga_vining_fpga.h b/include/configs/socfpga_vining_fpga.h index 0c76a77525..1197b40b58 100644 --- a/include/configs/socfpga_vining_fpga.h +++ b/include/configs/socfpga_vining_fpga.h @@ -8,8 +8,6 @@
#include <asm/arch/base_addr_ac5.h>
-#define CONFIG_HW_WATCHDOG
- /* Memory configurations */ #define PHYS_SDRAM_1_SIZE 0x40000000 /*
1GiB on VINING_FPGA */
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@denx.de

On Mon, Feb 12, 2018 at 12:34:10AM +0100, Lukasz Majewski wrote:
Hi Simon,
On 09.02.2018 23:14, Lukasz Majewski wrote:
All Socfpga boards from ./include/configs/socfpga_* define CONFIG_HW_WATCHDOG. To ease CONFIG_HW_WATCHDOG conversion to Kconfig select it in config ARCH_SOCFPGA (arch/arm/Kconfig) section.
I do have board configs where the internal watchdog is not used and should be disabled (because there's an external one). Also, given that this is an FPGA, I suppose having non-upstreamed boards is not uncommon.
I must admit that this patch I did after looking on the socfpga pattern in the current upstream.
It seems like all boards there use HW_WATCHDOG.
I'm not too familiar with these settings though: can I leave the watchdog disabled when CONFIG_HW_WATCHDOG is off? Before, I just haven't enabled this in my own board config...
I think that I will prepare next revision of this patch with just simple ./tools/moveconfig.py output (without blindly selecting HW_WATCHDOG on all socfpga devices).
In that way we will preserve the current behaviour.
You should probably use imply for features that are common, but optional.

On Sun, 11 Feb 2018 19:06:32 -0500 Tom Rini trini@konsulko.com wrote:
On Mon, Feb 12, 2018 at 12:34:10AM +0100, Lukasz Majewski wrote:
Hi Simon,
On 09.02.2018 23:14, Lukasz Majewski wrote:
All Socfpga boards from ./include/configs/socfpga_* define CONFIG_HW_WATCHDOG. To ease CONFIG_HW_WATCHDOG conversion to Kconfig select it in config ARCH_SOCFPGA (arch/arm/Kconfig) section.
I do have board configs where the internal watchdog is not used and should be disabled (because there's an external one). Also, given that this is an FPGA, I suppose having non-upstreamed boards is not uncommon.
I must admit that this patch I did after looking on the socfpga pattern in the current upstream.
It seems like all boards there use HW_WATCHDOG.
I'm not too familiar with these settings though: can I leave the watchdog disabled when CONFIG_HW_WATCHDOG is off? Before, I just haven't enabled this in my own board config...
I think that I will prepare next revision of this patch with just simple ./tools/moveconfig.py output (without blindly selecting HW_WATCHDOG on all socfpga devices).
In that way we will preserve the current behaviour.
You should probably use imply for features that are common, but optional.
Thanks for the suggestion.
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@denx.de

Hello Lukasz,
Am 09.02.2018 um 23:14 schrieb Lukasz Majewski:
All Socfpga boards from ./include/configs/socfpga_* define CONFIG_HW_WATCHDOG. To ease CONFIG_HW_WATCHDOG conversion to Kconfig select it in config ARCH_SOCFPGA (arch/arm/Kconfig) section.
Signed-off-by: Lukasz Majewski lukma@denx.de
Changes in v2:
None
arch/arm/Kconfig | 1 + include/configs/socfpga_arria10_socdk.h | 2 -- include/configs/socfpga_arria5_socdk.h | 2 -- include/configs/socfpga_cyclone5_socdk.h | 2 -- include/configs/socfpga_de0_nano_soc.h | 2 -- include/configs/socfpga_de10_nano.h | 2 -- include/configs/socfpga_de1_soc.h | 2 -- include/configs/socfpga_is1.h | 2 -- include/configs/socfpga_mcvevk.h | 2 -- include/configs/socfpga_sockit.h | 2 -- include/configs/socfpga_socrates.h | 2 -- include/configs/socfpga_sr1500.h | 2 -- include/configs/socfpga_vining_fpga.h | 2 -- 13 files changed, 1 insertion(+), 24 deletions(-)
Thanks!
Reviewed-by: Heiko Schocherhs@denx.de
bye, Heiko

The CONFIG_HW_WATCHDOG declaration has been converted to Kconfig
Signed-off-by: Lukasz Majewski lukma@denx.de
---
Changes in v2: - None
configs/axm_defconfig | 1 + configs/calimain_defconfig | 1 + configs/microblaze-generic_defconfig | 1 + configs/nokia_rx51_defconfig | 1 + configs/picosam9g45_defconfig | 1 + configs/smartweb_defconfig | 1 + configs/taurus_defconfig | 1 + configs/ts4800_defconfig | 1 + include/configs/M5475EVB.h | 1 - include/configs/M5485EVB.h | 1 - include/configs/calimain.h | 1 - include/configs/controlcenterd.h | 1 - include/configs/eb_cpu5282.h | 2 -- include/configs/microblaze-generic.h | 1 - include/configs/nokia_rx51.h | 1 - include/configs/picosam9g45.h | 1 - include/configs/smartweb.h | 3 --- include/configs/taurus.h | 1 - include/configs/ts4800.h | 2 -- 19 files changed, 8 insertions(+), 15 deletions(-)
diff --git a/configs/axm_defconfig b/configs/axm_defconfig index a08c62ff34..8c01a5c101 100644 --- a/configs/axm_defconfig +++ b/configs/axm_defconfig @@ -39,3 +39,4 @@ CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_PHYLIB=y CONFIG_USE_TINY_PRINTF=y +CONFIG_HW_WATCHDOG=y diff --git a/configs/calimain_defconfig b/configs/calimain_defconfig index d8ab012211..0f9bc9ed32 100644 --- a/configs/calimain_defconfig +++ b/configs/calimain_defconfig @@ -23,3 +23,4 @@ CONFIG_ENV_IS_IN_FLASH=y # CONFIG_MMC is not set CONFIG_MTD_NOR_FLASH=y CONFIG_SYS_NS16550=y +CONFIG_HW_WATCHDOG=y diff --git a/configs/microblaze-generic_defconfig b/configs/microblaze-generic_defconfig index ca68a81a5b..b12bf30785 100644 --- a/configs/microblaze-generic_defconfig +++ b/configs/microblaze-generic_defconfig @@ -58,3 +58,4 @@ CONFIG_XILINX_AXIEMAC=y CONFIG_XILINX_EMACLITE=y CONFIG_SYS_NS16550=y CONFIG_XILINX_UARTLITE=y +CONFIG_HW_WATCHDOG=y diff --git a/configs/nokia_rx51_defconfig b/configs/nokia_rx51_defconfig index 7b6e6ce730..f294e24f1b 100644 --- a/configs/nokia_rx51_defconfig +++ b/configs/nokia_rx51_defconfig @@ -33,3 +33,4 @@ CONFIG_TWL4030_USB=y CONFIG_VIDEO=y CONFIG_CFB_CONSOLE_ANSI=y # CONFIG_VGA_AS_SINGLE_DEVICE is not set +CONFIG_HW_WATCHDOG=y diff --git a/configs/picosam9g45_defconfig b/configs/picosam9g45_defconfig index 873776d1ad..70aed83f81 100644 --- a/configs/picosam9g45_defconfig +++ b/configs/picosam9g45_defconfig @@ -37,3 +37,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_STORAGE=y CONFIG_LCD=y CONFIG_OF_LIBFDT=y +CONFIG_HW_WATCHDOG=y diff --git a/configs/smartweb_defconfig b/configs/smartweb_defconfig index 246003fbfc..28bd3acc45 100644 --- a/configs/smartweb_defconfig +++ b/configs/smartweb_defconfig @@ -54,3 +54,4 @@ CONFIG_USB_HOST_ETHER=y CONFIG_USB_ETHER_ASIX=y CONFIG_USB_ETHER_MCS7830=y # CONFIG_EFI_LOADER is not set +CONFIG_HW_WATCHDOG=y diff --git a/configs/taurus_defconfig b/configs/taurus_defconfig index 1f47241021..e7e26adf9e 100644 --- a/configs/taurus_defconfig +++ b/configs/taurus_defconfig @@ -56,3 +56,4 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0908 CONFIG_USB_GADGET_PRODUCT_NUM=0x02d2 CONFIG_USB_GADGET_DOWNLOAD=y CONFIG_USE_TINY_PRINTF=y +CONFIG_HW_WATCHDOG=y diff --git a/configs/ts4800_defconfig b/configs/ts4800_defconfig index 17497ca52f..8007f9565a 100644 --- a/configs/ts4800_defconfig +++ b/configs/ts4800_defconfig @@ -15,3 +15,4 @@ CONFIG_CMD_FAT=y CONFIG_ENV_IS_IN_MMC=y CONFIG_PHYLIB=y CONFIG_OF_LIBFDT=y +CONFIG_HW_WATCHDOG=y diff --git a/include/configs/M5475EVB.h b/include/configs/M5475EVB.h index 3da7e2a410..e8d2b3aacd 100644 --- a/include/configs/M5475EVB.h +++ b/include/configs/M5475EVB.h @@ -22,7 +22,6 @@ #define CONFIG_MCFUART #define CONFIG_SYS_UART_PORT (0)
-#undef CONFIG_HW_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 5000 /* timeout in milliseconds, max timeout is 6.71sec */
#define CONFIG_SLTTMR diff --git a/include/configs/M5485EVB.h b/include/configs/M5485EVB.h index 2b26f0fe85..f428a20d82 100644 --- a/include/configs/M5485EVB.h +++ b/include/configs/M5485EVB.h @@ -22,7 +22,6 @@ #define CONFIG_MCFUART #define CONFIG_SYS_UART_PORT (0)
-#undef CONFIG_HW_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 5000 /* timeout in milliseconds, max timeout is 6.71sec */
#define CONFIG_SLTTMR diff --git a/include/configs/calimain.h b/include/configs/calimain.h index 4c2f6ba2d5..524d784811 100644 --- a/include/configs/calimain.h +++ b/include/configs/calimain.h @@ -29,7 +29,6 @@ #define CONFIG_SYS_TEXT_BASE 0x60000000 #define CONFIG_ARCH_CPU_INIT #define CONFIG_DA8XX_GPIO -#define CONFIG_HW_WATCHDOG #define CONFIG_SYS_WDTTIMERBASE DAVINCI_TIMER1_BASE #define CONFIG_SYS_WDT_PERIOD_LOW \ (60 * CONFIG_SYS_OSCIN_FREQ) /* 60 s heartbeat */ diff --git a/include/configs/controlcenterd.h b/include/configs/controlcenterd.h index 4312ddd4fc..9eafcd01ab 100644 --- a/include/configs/controlcenterd.h +++ b/include/configs/controlcenterd.h @@ -339,7 +339,6 @@ /* * Miscellaneous configurable options */ -#define CONFIG_HW_WATCHDOG #define CONFIG_LOADS_ECHO #define CONFIG_SYS_LOADS_BAUD_CHANGE
diff --git a/include/configs/eb_cpu5282.h b/include/configs/eb_cpu5282.h index 17c7fa757e..470b2095f8 100644 --- a/include/configs/eb_cpu5282.h +++ b/include/configs/eb_cpu5282.h @@ -32,8 +32,6 @@ #define CONFIG_RESET_TO_RETRY #define CONFIG_SPLASH_SCREEN
-#define CONFIG_HW_WATCHDOG - #define STATUS_LED_ACTIVE 0
/*----------------------------------------------------------------------* diff --git a/include/configs/microblaze-generic.h b/include/configs/microblaze-generic.h index 16481cb7ce..254558045c 100644 --- a/include/configs/microblaze-generic.h +++ b/include/configs/microblaze-generic.h @@ -50,7 +50,6 @@ # define CONFIG_WATCHDOG_BASEADDR XILINX_WATCHDOG_BASEADDR # define CONFIG_WATCHDOG_IRQ XILINX_WATCHDOG_IRQ # ifndef CONFIG_SPL_BUILD -# define CONFIG_HW_WATCHDOG # define CONFIG_XILINX_TB_WATCHDOG # endif #endif diff --git a/include/configs/nokia_rx51.h b/include/configs/nokia_rx51.h index 6312ed737c..1b44ad7451 100644 --- a/include/configs/nokia_rx51.h +++ b/include/configs/nokia_rx51.h @@ -159,7 +159,6 @@ #endif
/* Watchdog support */ -#define CONFIG_HW_WATCHDOG
/* * Framebuffer diff --git a/include/configs/picosam9g45.h b/include/configs/picosam9g45.h index dc7a67d77c..c8807fb754 100644 --- a/include/configs/picosam9g45.h +++ b/include/configs/picosam9g45.h @@ -67,7 +67,6 @@
/* Enable the watchdog */ #define CONFIG_AT91SAM9_WATCHDOG -#define CONFIG_HW_WATCHDOG
/* * Command line configuration. diff --git a/include/configs/smartweb.h b/include/configs/smartweb.h index 49c838bf72..5bbf4c28f6 100644 --- a/include/configs/smartweb.h +++ b/include/configs/smartweb.h @@ -125,9 +125,6 @@
/* Enable the watchdog */ #define CONFIG_AT91SAM9_WATCHDOG -#if !defined(CONFIG_SPL_BUILD) -#define CONFIG_HW_WATCHDOG -#endif #define CONFIG_AT91_HW_WDT_TIMEOUT 15
#if !defined(CONFIG_SPL_BUILD) diff --git a/include/configs/taurus.h b/include/configs/taurus.h index ce06f7bb5f..04d8e8d433 100644 --- a/include/configs/taurus.h +++ b/include/configs/taurus.h @@ -94,7 +94,6 @@ #define CONFIG_AT91_HW_WDT_TIMEOUT 15 #if !defined(CONFIG_SPL_BUILD) /* Enable the watchdog */ -#define CONFIG_HW_WATCHDOG #endif
/* USB */ diff --git a/include/configs/ts4800.h b/include/configs/ts4800.h index 5b8bac841c..2ed514f1df 100644 --- a/include/configs/ts4800.h +++ b/include/configs/ts4800.h @@ -17,8 +17,6 @@
#define CONFIG_SKIP_LOWLEVEL_INIT /* U-Boot is a 2nd stage bootloader */
-#define CONFIG_HW_WATCHDOG - #define CONFIG_MACH_TYPE MACH_TYPE_TS48XX
/* text base address used when linking */

Hello Lukasz,
Am 09.02.2018 um 23:14 schrieb Lukasz Majewski:
The CONFIG_HW_WATCHDOG declaration has been converted to Kconfig
Signed-off-by: Lukasz Majewski lukma@denx.de
Changes in v2:
None
configs/axm_defconfig | 1 + configs/calimain_defconfig | 1 + configs/microblaze-generic_defconfig | 1 + configs/nokia_rx51_defconfig | 1 + configs/picosam9g45_defconfig | 1 + configs/smartweb_defconfig | 1 + configs/taurus_defconfig | 1 + configs/ts4800_defconfig | 1 + include/configs/M5475EVB.h | 1 - include/configs/M5485EVB.h | 1 - include/configs/calimain.h | 1 - include/configs/controlcenterd.h | 1 - include/configs/eb_cpu5282.h | 2 -- include/configs/microblaze-generic.h | 1 - include/configs/nokia_rx51.h | 1 - include/configs/picosam9g45.h | 1 - include/configs/smartweb.h | 3 --- include/configs/taurus.h | 1 - include/configs/ts4800.h | 2 -- 19 files changed, 8 insertions(+), 15 deletions(-)
[...]
diff --git a/include/configs/microblaze-generic.h b/include/configs/microblaze-generic.h index 16481cb7ce..254558045c 100644 --- a/include/configs/microblaze-generic.h +++ b/include/configs/microblaze-generic.h @@ -50,7 +50,6 @@ # define CONFIG_WATCHDOG_BASEADDR XILINX_WATCHDOG_BASEADDR # define CONFIG_WATCHDOG_IRQ XILINX_WATCHDOG_IRQ # ifndef CONFIG_SPL_BUILD -# define CONFIG_HW_WATCHDOG # define CONFIG_XILINX_TB_WATCHDOG # endif #endif
Hmm... does this mean now, that HW_WATCHDOG is also in SPL enabled for microblaze?
Did you checked that the resulting images (if you do a reproducible build with SOURCE_DATE_EPOCH set) are the same?
IIRC, I prepared a tbot testcase to check exatly this ... let me search ... ah, yes:
https://github.com/hsdenx/tbot/blob/master/src/tc/uboot/tc_uboot_check_kconf...
diff --git a/include/configs/smartweb.h b/include/configs/smartweb.h index 49c838bf72..5bbf4c28f6 100644 --- a/include/configs/smartweb.h +++ b/include/configs/smartweb.h @@ -125,9 +125,6 @@
/* Enable the watchdog */ #define CONFIG_AT91SAM9_WATCHDOG -#if !defined(CONFIG_SPL_BUILD) -#define CONFIG_HW_WATCHDOG -#endif #define CONFIG_AT91_HW_WDT_TIMEOUT 15
Huch ... here too ... the smartweb board has extremly low sram, and now we have WDT enabled in SPL ...
#if !defined(CONFIG_SPL_BUILD) diff --git a/include/configs/taurus.h b/include/configs/taurus.h index ce06f7bb5f..04d8e8d433 100644 --- a/include/configs/taurus.h +++ b/include/configs/taurus.h @@ -94,7 +94,6 @@ #define CONFIG_AT91_HW_WDT_TIMEOUT 15 #if !defined(CONFIG_SPL_BUILD) /* Enable the watchdog */ -#define CONFIG_HW_WATCHDOG #endif
and here ...
I tried to apply your patchset to current mainline, I get this error for this patch:
pollux:u-boot-smartweb hs [master] $ git am mbox Wende an: Convert CONFIG_HW_WATCHDOG to Kconfig error: Anwendung des Patches fehlgeschlagen: include/configs/calimain.h:29 error: include/configs/calimain.h: Patch konnte nicht angewendet werden
Please rebase this patch. Nevertheless I fixed it fast locally and tried your patches with tbot on the smartweb board, all worked fine, no size problems!
Uh ... no ... board is now resetting all 15 seconds if no input over console!
reverted this patcheset, and resets are gone ... hmm... I cannot see how your patches produce this behaviour ... May I find time to look here closer, but I have to leave now ...
bye, Heiko
participants (4)
-
Goldschmidt Simon
-
Heiko Schocher
-
Lukasz Majewski
-
Tom Rini