From 9518c5d508a4a49f0e4bc08d838341836900c0a8 Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Wed, 16 Apr 2014 13:24:50 -0700 Subject: [PATCH] coreboot ARM: Get rid of HAVE_INIT_TIMER config option There is redundancy in terms of use of init_timer. We have a Kconfig option to decide whether a board has init_timer as well as we use stub for init_timer in places where we do not have any init_timer defined. Thus, removing the Kconfig option. Henceforth, all boards that do not have init_timer functionality can include include a stub_timer if required. BUG=None BRANCH=None TEST=Compiled successfully for all mainboard/google/ boards as well as all the other boards that were compiling fine before this change using abuild still compile fine. No additional errors introduced because of this change Change-Id: Iaffec9ce92107e55d65cc7c9f317feeeba700242 Reviewed-on: https://chromium-review.googlesource.com/195250 Tested-by: Furquan Shaikh Reviewed-by: Stefan Reinauer Commit-Queue: Furquan Shaikh --- src/Kconfig | 5 ----- src/cpu/amd/agesa/family10/Kconfig | 4 ---- src/cpu/amd/agesa/family12/Kconfig | 4 ---- src/cpu/amd/agesa/family14/Kconfig | 5 ----- src/cpu/amd/agesa/family15/Kconfig | 4 ---- src/cpu/amd/agesa/family15tn/Kconfig | 5 ----- src/drivers/pc80/udelay_io.c | 4 ++++ src/include/delay.h | 4 ---- src/mainboard/google/peach_pit/Kconfig | 1 - 9 files changed, 4 insertions(+), 32 deletions(-) diff --git a/src/Kconfig b/src/Kconfig index c2b3dd7847..cce01fd826 100644 --- a/src/Kconfig +++ b/src/Kconfig @@ -348,11 +348,6 @@ config HAVE_HARD_RESET This variable specifies whether a given board has a hard_reset function, no matter if it's provided by board code or chipset code. -config HAVE_INIT_TIMER - bool - default n if UDELAY_IO - default y - config HAVE_MONOTONIC_TIMER def_bool n help diff --git a/src/cpu/amd/agesa/family10/Kconfig b/src/cpu/amd/agesa/family10/Kconfig index 621ee5813e..97802c7e78 100755 --- a/src/cpu/amd/agesa/family10/Kconfig +++ b/src/cpu/amd/agesa/family10/Kconfig @@ -45,10 +45,6 @@ config XIP_ROM_SIZE hex default 0x80000 -config HAVE_INIT_TIMER - bool - default y - config REDIRECT_IDS_HDT_CONSOLE_TO_SERIAL bool "Redirect AGESA IDS_HDT_CONSOLE to serial console" default n diff --git a/src/cpu/amd/agesa/family12/Kconfig b/src/cpu/amd/agesa/family12/Kconfig index 1adf5eca31..e52d8ee2dd 100755 --- a/src/cpu/amd/agesa/family12/Kconfig +++ b/src/cpu/amd/agesa/family12/Kconfig @@ -63,8 +63,4 @@ config XIP_ROM_SIZE default 0x80000 depends on CPU_AMD_AGESA_FAMILY12 -config HAVE_INIT_TIMER - bool - default y - depends on CPU_AMD_AGESA_FAMILY12 diff --git a/src/cpu/amd/agesa/family14/Kconfig b/src/cpu/amd/agesa/family14/Kconfig index dea839ea51..e45a1229d8 100644 --- a/src/cpu/amd/agesa/family14/Kconfig +++ b/src/cpu/amd/agesa/family14/Kconfig @@ -63,11 +63,6 @@ config XIP_ROM_SIZE default 0x80000 depends on CPU_AMD_AGESA_FAMILY14 -config HAVE_INIT_TIMER - bool - default y - depends on CPU_AMD_AGESA_FAMILY14 - config HIGH_SCRATCH_MEMORY_SIZE hex # Assume the maximum size of stack as (0xA0000 - 0x30000 + 0x1000) diff --git a/src/cpu/amd/agesa/family15/Kconfig b/src/cpu/amd/agesa/family15/Kconfig index e20cce8ab3..a0c1621b9a 100644 --- a/src/cpu/amd/agesa/family15/Kconfig +++ b/src/cpu/amd/agesa/family15/Kconfig @@ -67,10 +67,6 @@ config XIP_ROM_SIZE hex default 0x80000 -config HAVE_INIT_TIMER - bool - default y - config REDIRECT_IDS_HDT_CONSOLE_TO_SERIAL bool "Redirect AGESA IDS_HDT_CONSOLE to serial console" default n diff --git a/src/cpu/amd/agesa/family15tn/Kconfig b/src/cpu/amd/agesa/family15tn/Kconfig index d2f5a8c1b2..afe82403ff 100644 --- a/src/cpu/amd/agesa/family15tn/Kconfig +++ b/src/cpu/amd/agesa/family15tn/Kconfig @@ -68,11 +68,6 @@ config XIP_ROM_SIZE default 0x100000 depends on CPU_AMD_AGESA_FAMILY15_TN -config HAVE_INIT_TIMER - bool - default y - depends on CPU_AMD_AGESA_FAMILY15_TN - config HIGH_SCRATCH_MEMORY_SIZE hex # Assume the maximum size of stack as (0xA0000 - 0x30000 + 0x1000) diff --git a/src/drivers/pc80/udelay_io.c b/src/drivers/pc80/udelay_io.c index 37f3f73186..48ff32c944 100644 --- a/src/drivers/pc80/udelay_io.c +++ b/src/drivers/pc80/udelay_io.c @@ -1,6 +1,10 @@ #include #include +void init_timer(void) +{ +} + void udelay(unsigned usecs) { int i; diff --git a/src/include/delay.h b/src/include/delay.h index 676579b6ae..b3d8ed95da 100644 --- a/src/include/delay.h +++ b/src/include/delay.h @@ -1,11 +1,7 @@ #ifndef DELAY_H #define DELAY_H -#if CONFIG_HAVE_INIT_TIMER void init_timer(void); -#else -#define init_timer() do{} while(0) -#endif void udelay(unsigned usecs); void mdelay(unsigned msecs); diff --git a/src/mainboard/google/peach_pit/Kconfig b/src/mainboard/google/peach_pit/Kconfig index fbb395924e..9cb008fb50 100644 --- a/src/mainboard/google/peach_pit/Kconfig +++ b/src/mainboard/google/peach_pit/Kconfig @@ -30,7 +30,6 @@ config BOARD_SPECIFIC_OPTIONS # dummy select CHROMEOS select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_DO_NATIVE_VGA_INIT - select HAVE_INIT_TIMER select DRIVER_PARADE_PS8625 config MAINBOARD_DIR