summaryrefslogtreecommitdiff
path: root/payloads/libpayload
diff options
context:
space:
mode:
authorRex-BC Chen <rex-bc.chen@mediatek.corp-partner.google.com>2021-08-05 23:51:28 +0800
committerHung-Te Lin <hungte@chromium.org>2021-08-09 01:53:20 +0000
commit5889f02032bd353a6ca69ff65918128392aeead9 (patch)
tree33bb401e0ddfe35b39b262eb84a91eb8ec96be21 /payloads/libpayload
parent257eb1354e5fedb01b63ff327f64554a44547c22 (diff)
payloads/libpayload: add MTK_TIMER_V2 config
The timer structure (in particular, the offset to memory addresses) on recent MTK SoCs for example MT8195 has been changed. BUG=b:195274787 Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com> Change-Id: Ifd6ff65a825c4309c47f3b115b80a8ecd42fedac Reviewed-on: https://review.coreboot.org/c/coreboot/+/56845 Reviewed-by: Hung-Te Lin <hungte@chromium.org> Reviewed-by: Rex-BC Chen <rex-bc.chen@mediatek.corp-partner.google.com> Reviewed-by: Yu-Ping Wu <yupingso@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'payloads/libpayload')
-rw-r--r--payloads/libpayload/drivers/timer/Kconfig6
1 files changed, 6 insertions, 0 deletions
diff --git a/payloads/libpayload/drivers/timer/Kconfig b/payloads/libpayload/drivers/timer/Kconfig
index 175e4bb377..406457af8e 100644
--- a/payloads/libpayload/drivers/timer/Kconfig
+++ b/payloads/libpayload/drivers/timer/Kconfig
@@ -45,6 +45,9 @@ config TIMER_RK3399
config TIMER_MTK
bool "Timer for MediaTek"
+config TIMER_MTK_V2
+ bool "Timer for MediaTek V2"
+
endchoice
config TIMER_GENERIC_HZ
@@ -53,6 +56,7 @@ config TIMER_GENERIC_HZ
default 6250000 if TIMER_IPQ806X
default 24000000 if TIMER_MCT
default 13000000 if TIMER_MTK
+ default 13000000 if TIMER_MTK_V2
default 24000000 if TIMER_RK3288
default 24000000 if TIMER_RK3399
default 1000000 if TIMER_TEGRA_1US
@@ -67,6 +71,7 @@ config TIMER_GENERIC_REG
default 0x0200A028 if TIMER_IPQ806X
default 0x101C0100 if TIMER_MCT
default 0x10008068 if TIMER_MTK
+ default 0x100080A8 if TIMER_MTK_V2
default 0xff810028 if TIMER_RK3288
default 0xff850008 if TIMER_RK3399
default 0x60005010 if TIMER_TEGRA_1US
@@ -79,6 +84,7 @@ config TIMER_GENERIC_HIGH_REG
default 0x004A2004 if TIMER_IPQ40XX
default 0x101C0104 if TIMER_MCT
default 0x10008078 if TIMER_MTK
+ default 0x100080B0 if TIMER_MTK_V2
default 0xff81002C if TIMER_RK3288
default 0xff85000C if TIMER_RK3399
default 0x0