Commit 0cedca63 authored by Grzegorz Jaszczyk's avatar Grzegorz Jaszczyk Committed by Manish Pandey
Browse files

drivers: marvell: thermal: use dedicated function for thermal SiPs



Since more drivers which uses dfx register set need to be handled with
use of SiP services, use dedicated and more meaningful name for thermal
SiP services.

Change-Id: Ic2ac27535a4902477df8edc4c86df3e34cb2344f
Signed-off-by: default avatarGrzegorz Jaszczyk <jaz@semihalf.com>
Reviewed-on: https://sj1git1.cavium.com/25054

Tested-by: default avatarsa_ip-sw-jenkins <sa_ip-sw-jenkins@marvell.com>
Reviewed-by: default avatarKostya Porotchkin <kostap@marvell.com>
parent ad416958
......@@ -217,8 +217,8 @@ static void armada_is_valid(u_register_t *read)
*read = (mmio_read_32(TSEN_STATUS) & TSEN_STATUS_VALID_MASK);
}
int mvebu_dfx_handle(u_register_t func, u_register_t *read, u_register_t x2,
u_register_t x3)
int mvebu_dfx_thermal_handle(u_register_t func, u_register_t *read,
u_register_t x2, u_register_t x3)
{
debug_enter();
......
......@@ -13,5 +13,5 @@
#define MV_SIP_DFX_THERMAL_THRESH 5
#define MV_SIP_DFX_THERMAL_SEL_CHANNEL 6
int mvebu_dfx_handle(u_register_t func, u_register_t *read, u_register_t x2,
u_register_t x3);
int mvebu_dfx_thermal_handle(u_register_t func, u_register_t *read,
u_register_t x2, u_register_t x3);
......@@ -139,8 +139,12 @@ uintptr_t mrvl_sip_smc_handler(uint32_t smc_fid,
SMC_RET1(handle, 0);
#endif
case MV_SIP_DFX:
ret = mvebu_dfx_handle(x1, &read, x2, x3);
if (x1 >= MV_SIP_DFX_THERMAL_INIT &&
x1 <= MV_SIP_DFX_THERMAL_SEL_CHANNEL) {
ret = mvebu_dfx_thermal_handle(x1, &read, x2, x3);
SMC_RET2(handle, ret, read);
}
SMC_RET1(handle, SMC_UNK);
case MV_SIP_RNG_64:
ret = eip76_rng_get_random((uint8_t *)&w2, 4 * (x1 % 2 + 1));
SMC_RET3(handle, ret, w2[0], w2[1]);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment