Re: [U-Boot] [PATCH v2 4/4] Convert CONFIG_HW_WATCHDOG to Kconfig

2018-02-12 Thread Heiko Schocher

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 

---

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_kconfig.py


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_TIMEOUT15


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_TIMEOUT15
  #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
--
DENX Software Engineering GmbH,  Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52   Fax: +49-8142-66989-80   Email: h...@denx.de
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v2 4/4] Convert CONFIG_HW_WATCHDOG to Kconfig

2018-02-09 Thread Lukasz Majewski
The CONFIG_HW_WATCHDOG declaration has been converted to Kconfig

Signed-off-by: Lukasz Majewski 

---

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_TIMEOUT5000/* 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_TIMEOUT5000/* 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   0x6000
 #define CONFIG_ARCH_CPU_INIT
 #define CONFIG_DA8XX_GPIO
-#define CONFIG_HW_WATCHDOG
 #define CONFIG_SYS_WDTTIMERBASEDAVINCI_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/con