[U-Boot] [PATCH v3 01/11] ARM: PSCI: change PSCI function IDs base and offsets

Mark Rutland mark.rutland at arm.com
Mon May 23 17:54:19 CEST 2016


On Wed, May 18, 2016 at 05:10:24PM +0800, macro.wave.z at gmail.com wrote:
> From: Wang Dongsheng <dongsheng.wang at nxp.com>
> 
> According to PSCI specification v1.0, the PSCI functions should start from
> 0x84000000 for SMC32, this patch changes this base value as well as other
> function offset values.

I agree that these are the correct valeus for PSCI 0.2, and we must use
those IDs for PSCI 0.2+.

However, this code is also used on platforms using PSCI 0.1, which did
not have well-defined IDs, and relied on them being described in the DT.
I fear that this may have the unintended sonequence of breaking those.

Does U-Boot patch the DT with the correct IDs per the PSCI 0.1 binding?
If so, then things are fine.

Thanks,
Mark.

> Signed-off-by: Wang Dongsheng <dongsheng.wang at nxp.com>
> Signed-off-by: Hongbo Zhang <hongbo.zhang at nxp.com>
> ---
>  arch/arm/include/asm/psci.h | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/arch/arm/include/asm/psci.h b/arch/arm/include/asm/psci.h
> index 128a606..a4a19e3 100644
> --- a/arch/arm/include/asm/psci.h
> +++ b/arch/arm/include/asm/psci.h
> @@ -19,13 +19,13 @@
>  #define __ARM_PSCI_H__
>  
>  /* PSCI interface */
> -#define ARM_PSCI_FN_BASE		0x95c1ba5e
> +#define ARM_PSCI_FN_BASE		0x84000000
>  #define ARM_PSCI_FN(n)			(ARM_PSCI_FN_BASE + (n))
>  
> -#define ARM_PSCI_FN_CPU_SUSPEND		ARM_PSCI_FN(0)
> -#define ARM_PSCI_FN_CPU_OFF		ARM_PSCI_FN(1)
> -#define ARM_PSCI_FN_CPU_ON		ARM_PSCI_FN(2)
> -#define ARM_PSCI_FN_MIGRATE		ARM_PSCI_FN(3)
> +#define ARM_PSCI_FN_CPU_SUSPEND		ARM_PSCI_FN(1)
> +#define ARM_PSCI_FN_CPU_OFF		ARM_PSCI_FN(2)
> +#define ARM_PSCI_FN_CPU_ON		ARM_PSCI_FN(3)
> +#define ARM_PSCI_FN_MIGRATE		ARM_PSCI_FN(5)
>  
>  #define ARM_PSCI_RET_SUCCESS		0
>  #define ARM_PSCI_RET_NI			(-1)
> -- 
> 2.1.4
> 


More information about the U-Boot mailing list