From b4b5674df40e281483702c1795cd2912fd437670 Mon Sep 17 00:00:00 2001 From: Ranjani Vaidyanathan Date: Fri, 22 Nov 2019 12:21:30 -0600 Subject: plat:imx8qm/imx8qxp: Update SCFW API Sync SCFW API to commit b3c575a62b0e2 SCFW API version 16 Signed-off-by: Ranjani Vaidyanathan --- plat/imx/common/include/imx8qm_pads.h | 3 +-- plat/imx/common/include/sci/sci_rpc.h | 2 +- plat/imx/common/sci/svc/timer/sci_timer_rpc.h | 1 + plat/imx/common/sci/svc/timer/timer_rpc_clnt.c | 19 +++++++++++++++++++ 4 files changed, 22 insertions(+), 3 deletions(-) diff --git a/plat/imx/common/include/imx8qm_pads.h b/plat/imx/common/include/imx8qm_pads.h index 10028095..7267f5d9 100644 --- a/plat/imx/common/include/imx8qm_pads.h +++ b/plat/imx/common/include/imx8qm_pads.h @@ -291,5 +291,4 @@ #define SC_P_COMP_CTL_GPIO_1V8_3V3_ENET_ENETA 268 /* */ /*@}*/ -#endif /* SC_PADS_H */ - +#endif /* SC_PADS_H */ diff --git a/plat/imx/common/include/sci/sci_rpc.h b/plat/imx/common/include/sci/sci_rpc.h index 046ef979..b742a8bc 100755 --- a/plat/imx/common/include/sci/sci_rpc.h +++ b/plat/imx/common/include/sci/sci_rpc.h @@ -21,7 +21,7 @@ /* Defines */ #define SCFW_API_VERSION_MAJOR 1U -#define SCFW_API_VERSION_MINOR 15U +#define SCFW_API_VERSION_MINOR 16U #define SC_RPC_VERSION 1U diff --git a/plat/imx/common/sci/svc/timer/sci_timer_rpc.h b/plat/imx/common/sci/svc/timer/sci_timer_rpc.h index 7858ecdc..3211ba22 100644 --- a/plat/imx/common/sci/svc/timer/sci_timer_rpc.h +++ b/plat/imx/common/sci/svc/timer/sci_timer_rpc.h @@ -26,6 +26,7 @@ #define TIMER_FUNC_UNKNOWN 0 /* Unknown function */ #define TIMER_FUNC_SET_WDOG_TIMEOUT 1U /* Index for sc_timer_set_wdog_timeout() RPC call */ #define TIMER_FUNC_SET_WDOG_PRE_TIMEOUT 12U /* Index for sc_timer_set_wdog_pre_timeout() RPC call */ +#define TIMER_FUNC_SET_WDOG_WINDOW 19U /* Index for sc_timer_set_wdog_window() RPC call */ #define TIMER_FUNC_START_WDOG 2U /* Index for sc_timer_start_wdog() RPC call */ #define TIMER_FUNC_STOP_WDOG 3U /* Index for sc_timer_stop_wdog() RPC call */ #define TIMER_FUNC_PING_WDOG 4U /* Index for sc_timer_ping_wdog() RPC call */ diff --git a/plat/imx/common/sci/svc/timer/timer_rpc_clnt.c b/plat/imx/common/sci/svc/timer/timer_rpc_clnt.c index 231a8a79..5572abf9 100644 --- a/plat/imx/common/sci/svc/timer/timer_rpc_clnt.c +++ b/plat/imx/common/sci/svc/timer/timer_rpc_clnt.c @@ -67,6 +67,25 @@ sc_err_t sc_timer_set_wdog_pre_timeout(sc_ipc_t ipc, return err; } +sc_err_t sc_timer_set_wdog_window(sc_ipc_t ipc, sc_timer_wdog_time_t window) +{ + sc_rpc_msg_t msg; + sc_err_t err; + + RPC_VER(&msg) = SC_RPC_VERSION; + RPC_SIZE(&msg) = 2U; + RPC_SVC(&msg) = U8(SC_RPC_SVC_TIMER); + RPC_FUNC(&msg) = U8(TIMER_FUNC_SET_WDOG_WINDOW); + + RPC_U32(&msg, 0U) = U32(window); + + sc_call_rpc(ipc, &msg, SC_FALSE); + + err = (sc_err_t)RPC_R8(&msg); + + return err; +} + sc_err_t sc_timer_start_wdog(sc_ipc_t ipc, sc_bool_t lock) { sc_rpc_msg_t msg; -- cgit v1.2.3