Re: [PATCH 1/4] arch: m68k: Use existing CONFIG_MCFTMR instead of CFG_MCFTMR

2023-03-19 Thread Angelo Dureghello

Hi Marek,

On 19/03/23 4:14 AM, Marek Vasut wrote:

There is an existing CONFIG_MCFTMR Kconfig symbol,
use it and drop all other instances of CFG_MCFTMR.
This duality is likely a result of bogus conversion
to Kconfig.



Thanks, my fault here, introduced in commit
7ff7b46e6ce44b2ee09647a928ce1021c3c8a66e

i mainly misunderstood the CI error, moving this to
CFG namespace. Thanks for fixing it.


Signed-off-by: Marek Vasut 
---
Cc: Angelo Dureghello 
Cc: Huan Wang 
Cc: Marek Vasut 
Cc: Simon Glass 
Cc: Stefan Roese 
Cc: Tom Rini 
---
  arch/m68k/Kconfig   |  1 +
  arch/m68k/cpu/mcf523x/interrupts.c  |  2 +-
  arch/m68k/cpu/mcf52x2/interrupts.c  | 12 ++--
  arch/m68k/cpu/mcf532x/interrupts.c  |  2 +-
  arch/m68k/cpu/mcf5445x/interrupts.c |  2 +-
  arch/m68k/include/asm/immap.h   | 24 
  arch/m68k/lib/time.c|  4 ++--
  board/freescale/m53017evb/README|  2 +-
  board/freescale/m5373evb/README |  2 +-
  include/configs/M5208EVBE.h |  1 -
  include/configs/M5235EVB.h  |  1 -
  include/configs/M5249EVB.h  |  1 -
  include/configs/M5253DEMO.h |  1 -
  include/configs/M5272C3.h   |  1 -
  include/configs/M5275EVB.h  |  1 -
  include/configs/M5282EVB.h  |  1 -
  include/configs/M53017EVB.h |  1 -
  include/configs/M5329EVB.h  |  1 -
  include/configs/M5373EVB.h  |  1 -
  include/configs/amcore.h|  1 -
  include/configs/astro_mcf5373l.h|  1 -
  include/configs/cobra5272.h |  1 -
  include/configs/eb_cpu5282.h|  1 -
  include/configs/stmark2.h   |  1 -
  24 files changed, 26 insertions(+), 40 deletions(-)

diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
index 76233ef563f..32759cde47d 100644
--- a/arch/m68k/Kconfig
+++ b/arch/m68k/Kconfig
@@ -200,5 +200,6 @@ source "board/sysam/stmark2/Kconfig"
  
  config MCFTMR

bool "Use DMA timer"
+   default y
  
  endmenu

diff --git a/arch/m68k/cpu/mcf523x/interrupts.c 
b/arch/m68k/cpu/mcf523x/interrupts.c
index b02ea29f635..09c7f9e67cc 100644
--- a/arch/m68k/cpu/mcf523x/interrupts.c
+++ b/arch/m68k/cpu/mcf523x/interrupts.c
@@ -22,7 +22,7 @@ int interrupt_init(void)
return 0;
  }
  
-#if defined(CFG_MCFTMR)

+#if CONFIG_IS_ENABLED(MCFTMR)
  void dtimer_intr_setup(void)
  {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
diff --git a/arch/m68k/cpu/mcf52x2/interrupts.c 
b/arch/m68k/cpu/mcf52x2/interrupts.c
index e787c7605f8..c5ed0600736 100644
--- a/arch/m68k/cpu/mcf52x2/interrupts.c
+++ b/arch/m68k/cpu/mcf52x2/interrupts.c
@@ -34,7 +34,7 @@ int interrupt_init(void)
return 0;
  }
  
-#if defined(CFG_MCFTMR)

+#if CONFIG_IS_ENABLED(MCFTMR)
  void dtimer_intr_setup(void)
  {
intctrl_t *intp = (intctrl_t *) (CFG_SYS_INTR_BASE);
@@ -42,7 +42,7 @@ void dtimer_intr_setup(void)
clrbits_be32(>int_icr1, INT_ICR1_TMR3MASK);
setbits_be32(>int_icr1, CFG_SYS_TMRINTR_PRI);
  }
-#endif /* CFG_MCFTMR */
+#endif /* CONFIG_MCFTMR */
  #endif/* CONFIG_M5272 */
  
  #if defined(CONFIG_M5208) || defined(CONFIG_M5282) || \

@@ -63,7 +63,7 @@ int interrupt_init(void)
return 0;
  }
  
-#if defined(CFG_MCFTMR)

+#if CONFIG_IS_ENABLED(MCFTMR)
  void dtimer_intr_setup(void)
  {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
@@ -72,7 +72,7 @@ void dtimer_intr_setup(void)
clrbits_be32(>imrl0, 0x0001);
clrbits_be32(>imrl0, CFG_SYS_TMRINTR_MASK);
  }
-#endif /* CFG_MCFTMR */
+#endif /* CONFIG_MCFTMR */
  #endif/* CONFIG_M5282 | CONFIG_M5271 | 
CONFIG_M5275 */
  
  #if defined(CONFIG_M5249) || defined(CONFIG_M5253)

@@ -83,11 +83,11 @@ int interrupt_init(void)
return 0;
  }
  
-#if defined(CFG_MCFTMR)

+#if CONFIG_IS_ENABLED(MCFTMR)
  void dtimer_intr_setup(void)
  {
mbar_writeLong(MCFSIM_IMR, mbar_readLong(MCFSIM_IMR) & ~0x0400);
mbar_writeByte(MCFSIM_TIMER2ICR, CFG_SYS_TMRINTR_PRI);
  }
-#endif /* CFG_MCFTMR */
+#endif /* CONFIG_MCFTMR */
  #endif/* CONFIG_M5249 || CONFIG_M5253 */
diff --git a/arch/m68k/cpu/mcf532x/interrupts.c 
b/arch/m68k/cpu/mcf532x/interrupts.c
index bbe823c0cf7..4f72fa88e58 100644
--- a/arch/m68k/cpu/mcf532x/interrupts.c
+++ b/arch/m68k/cpu/mcf532x/interrupts.c
@@ -23,7 +23,7 @@ int interrupt_init(void)
return 0;
  }
  
-#if defined(CFG_MCFTMR)

+#if CONFIG_IS_ENABLED(MCFTMR)
  void dtimer_intr_setup(void)
  {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
diff --git a/arch/m68k/cpu/mcf5445x/interrupts.c 
b/arch/m68k/cpu/mcf5445x/interrupts.c
index fb80a879c7e..400f3dee879 100644
--- a/arch/m68k/cpu/mcf5445x/interrupts.c
+++ b/arch/m68k/cpu/mcf5445x/interrupts.c
@@ -26,7 +26,7 @@ int interrupt_init(void)
return 

[PATCH 1/4] arch: m68k: Use existing CONFIG_MCFTMR instead of CFG_MCFTMR

2023-03-18 Thread Marek Vasut
There is an existing CONFIG_MCFTMR Kconfig symbol,
use it and drop all other instances of CFG_MCFTMR.
This duality is likely a result of bogus conversion
to Kconfig.

Signed-off-by: Marek Vasut 
---
Cc: Angelo Dureghello 
Cc: Huan Wang 
Cc: Marek Vasut 
Cc: Simon Glass 
Cc: Stefan Roese 
Cc: Tom Rini 
---
 arch/m68k/Kconfig   |  1 +
 arch/m68k/cpu/mcf523x/interrupts.c  |  2 +-
 arch/m68k/cpu/mcf52x2/interrupts.c  | 12 ++--
 arch/m68k/cpu/mcf532x/interrupts.c  |  2 +-
 arch/m68k/cpu/mcf5445x/interrupts.c |  2 +-
 arch/m68k/include/asm/immap.h   | 24 
 arch/m68k/lib/time.c|  4 ++--
 board/freescale/m53017evb/README|  2 +-
 board/freescale/m5373evb/README |  2 +-
 include/configs/M5208EVBE.h |  1 -
 include/configs/M5235EVB.h  |  1 -
 include/configs/M5249EVB.h  |  1 -
 include/configs/M5253DEMO.h |  1 -
 include/configs/M5272C3.h   |  1 -
 include/configs/M5275EVB.h  |  1 -
 include/configs/M5282EVB.h  |  1 -
 include/configs/M53017EVB.h |  1 -
 include/configs/M5329EVB.h  |  1 -
 include/configs/M5373EVB.h  |  1 -
 include/configs/amcore.h|  1 -
 include/configs/astro_mcf5373l.h|  1 -
 include/configs/cobra5272.h |  1 -
 include/configs/eb_cpu5282.h|  1 -
 include/configs/stmark2.h   |  1 -
 24 files changed, 26 insertions(+), 40 deletions(-)

diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
index 76233ef563f..32759cde47d 100644
--- a/arch/m68k/Kconfig
+++ b/arch/m68k/Kconfig
@@ -200,5 +200,6 @@ source "board/sysam/stmark2/Kconfig"
 
 config MCFTMR
bool "Use DMA timer"
+   default y
 
 endmenu
diff --git a/arch/m68k/cpu/mcf523x/interrupts.c 
b/arch/m68k/cpu/mcf523x/interrupts.c
index b02ea29f635..09c7f9e67cc 100644
--- a/arch/m68k/cpu/mcf523x/interrupts.c
+++ b/arch/m68k/cpu/mcf523x/interrupts.c
@@ -22,7 +22,7 @@ int interrupt_init(void)
return 0;
 }
 
-#if defined(CFG_MCFTMR)
+#if CONFIG_IS_ENABLED(MCFTMR)
 void dtimer_intr_setup(void)
 {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
diff --git a/arch/m68k/cpu/mcf52x2/interrupts.c 
b/arch/m68k/cpu/mcf52x2/interrupts.c
index e787c7605f8..c5ed0600736 100644
--- a/arch/m68k/cpu/mcf52x2/interrupts.c
+++ b/arch/m68k/cpu/mcf52x2/interrupts.c
@@ -34,7 +34,7 @@ int interrupt_init(void)
return 0;
 }
 
-#if defined(CFG_MCFTMR)
+#if CONFIG_IS_ENABLED(MCFTMR)
 void dtimer_intr_setup(void)
 {
intctrl_t *intp = (intctrl_t *) (CFG_SYS_INTR_BASE);
@@ -42,7 +42,7 @@ void dtimer_intr_setup(void)
clrbits_be32(>int_icr1, INT_ICR1_TMR3MASK);
setbits_be32(>int_icr1, CFG_SYS_TMRINTR_PRI);
 }
-#endif /* CFG_MCFTMR */
+#endif /* CONFIG_MCFTMR */
 #endif /* CONFIG_M5272 */
 
 #if defined(CONFIG_M5208) || defined(CONFIG_M5282) || \
@@ -63,7 +63,7 @@ int interrupt_init(void)
return 0;
 }
 
-#if defined(CFG_MCFTMR)
+#if CONFIG_IS_ENABLED(MCFTMR)
 void dtimer_intr_setup(void)
 {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
@@ -72,7 +72,7 @@ void dtimer_intr_setup(void)
clrbits_be32(>imrl0, 0x0001);
clrbits_be32(>imrl0, CFG_SYS_TMRINTR_MASK);
 }
-#endif /* CFG_MCFTMR */
+#endif /* CONFIG_MCFTMR */
 #endif /* CONFIG_M5282 | CONFIG_M5271 | CONFIG_M5275 */
 
 #if defined(CONFIG_M5249) || defined(CONFIG_M5253)
@@ -83,11 +83,11 @@ int interrupt_init(void)
return 0;
 }
 
-#if defined(CFG_MCFTMR)
+#if CONFIG_IS_ENABLED(MCFTMR)
 void dtimer_intr_setup(void)
 {
mbar_writeLong(MCFSIM_IMR, mbar_readLong(MCFSIM_IMR) & ~0x0400);
mbar_writeByte(MCFSIM_TIMER2ICR, CFG_SYS_TMRINTR_PRI);
 }
-#endif /* CFG_MCFTMR */
+#endif /* CONFIG_MCFTMR */
 #endif /* CONFIG_M5249 || CONFIG_M5253 */
diff --git a/arch/m68k/cpu/mcf532x/interrupts.c 
b/arch/m68k/cpu/mcf532x/interrupts.c
index bbe823c0cf7..4f72fa88e58 100644
--- a/arch/m68k/cpu/mcf532x/interrupts.c
+++ b/arch/m68k/cpu/mcf532x/interrupts.c
@@ -23,7 +23,7 @@ int interrupt_init(void)
return 0;
 }
 
-#if defined(CFG_MCFTMR)
+#if CONFIG_IS_ENABLED(MCFTMR)
 void dtimer_intr_setup(void)
 {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
diff --git a/arch/m68k/cpu/mcf5445x/interrupts.c 
b/arch/m68k/cpu/mcf5445x/interrupts.c
index fb80a879c7e..400f3dee879 100644
--- a/arch/m68k/cpu/mcf5445x/interrupts.c
+++ b/arch/m68k/cpu/mcf5445x/interrupts.c
@@ -26,7 +26,7 @@ int interrupt_init(void)
return 0;
 }
 
-#if defined(CFG_MCFTMR)
+#if CONFIG_IS_ENABLED(MCFTMR)
 void dtimer_intr_setup(void)
 {
int0_t *intp = (int0_t *) (CFG_SYS_INTR_BASE);
diff --git a/arch/m68k/include/asm/immap.h b/arch/m68k/include/asm/immap.h
index 74516cc6219..3b515fe2c65 100644
--- a/arch/m68k/include/asm/immap.h
+++