From c5ebfbf74dde2ee2074317622a5e342bd50b2d15 Mon Sep 17 00:00:00 2001 From: jixj Date: Fri, 23 Oct 2020 11:27:59 +0800 Subject: [PATCH] watchdogtest: add qcom_wdt_trigger_bite for trigger wdog Qcom introduces new watchdog architecture on 4350/8350, so use "qcom_wdt_trigger_bite" to trigger wdog when enable CONFIG_QCOM_WDT_CORE Change-Id: Ide2ccb0e5a498454359fd6544e832f109251df5c Reviewed-on: https://gerrit.mot.com/1782962 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: Ryan Lattrel Reviewed-by: Zhenxin Xi Submit-Approved: Jira Key --- drivers/watchdogtest/watchdogtest.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/watchdogtest/watchdogtest.c b/drivers/watchdogtest/watchdogtest.c index 1bc434a13f58..50fc698e335e 100644 --- a/drivers/watchdogtest/watchdogtest.c +++ b/drivers/watchdogtest/watchdogtest.c @@ -75,14 +75,16 @@ static int watchdog_test_init(void) #if LINUX_VERSION_CODE < KERNEL_VERSION(5,4,0) trigger_wdog_bite = (void *)kallsyms_lookup_name("msm_trigger_wdog_bite"); #else -#ifdef CONFIG_ARCH_QCOM +#if defined(CONFIG_QCOM_WATCHDOG_V2) trigger_wdog_bite = msm_trigger_wdog_bite; +#elif defined(CONFIG_QCOM_WDT_CORE) + trigger_wdog_bite = qcom_wdt_trigger_bite; #else trigger_wdog_bite = NULL; #endif #endif if (!trigger_wdog_bite) - printk(KERN_ERR "Failed to get msm_trigger_wdog_bite address\n"); + printk(KERN_ERR "Failed to get trigger_wdog_bite address\n"); return 0; }