Commit 7d28eee9134a2fed721ff301dc624a941ed267ab

Authored by Ye Li
1 parent 3df4e71c96

MLK-23967 imx8: scu_api: Sync sc_rm_is_pad_owned API change

SCFW has fixed a overflow issue in sc_rm_is_pad_owned API. This
requires u-boot to update API implementation, since it will cause
compatible issue. Otherwise all pad checking will have problem and
cause pad setting not continue.

Due to the compatible issue, the new u-boot only works with new
SCFW (API version: 1.21).

old scfw + old u-boot: API overflow issue
old scfw + new u-boot, or new scfw + old u-boot: API compatible issue
new scfw + new u-boot: Working

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by : Jason Liu <Jason.hui.liu@nxp.com>

(cherry picked from commit e84fb02056fe50146856320b96de909dad4c0058)

Showing 2 changed files with 2 additions and 2 deletions Side-by-side Diff

arch/arm/include/asm/arch-imx8/sci/rpc.h
... ... @@ -11,7 +11,7 @@
11 11 /* Defines */
12 12  
13 13 #define SCFW_API_VERSION_MAJOR 1U
14   -#define SCFW_API_VERSION_MINOR 16U
  14 +#define SCFW_API_VERSION_MINOR 21U
15 15  
16 16 #define SC_RPC_VERSION 1U
17 17  
drivers/misc/imx8/scu_api.c
... ... @@ -764,7 +764,7 @@
764 764 RPC_VER(&msg) = SC_RPC_VERSION;
765 765 RPC_SVC(&msg) = (u8)SC_RPC_SVC_RM;
766 766 RPC_FUNC(&msg) = (u8)RM_FUNC_IS_PAD_OWNED;
767   - RPC_U8(&msg, 0U) = (u8)pad;
  767 + RPC_U16(&msg, 0U) = (u16)pad;
768 768 RPC_SIZE(&msg) = 2U;
769 769  
770 770 ret = misc_call(dev, SC_FALSE, &msg, size, &msg, size);