[PATCH 07/24] imx: update is_imx6ull to include i.MX6ULZ

Michael Heimpold mhei at heimpold.de
Wed Apr 22 22:00:51 CEST 2020


Am Mittwoch, 22. April 2020, 15:52:18 CEST schrieb Peng Fan:
> Update is_imx6ull helper to include i.MX6ULZ SoC. i.MX6ULZ could
> share same macro, then we no need to add is_imx6ulz in various drivers.
> 
> Signed-off-by: Peng Fan <peng.fan at nxp.com>
> ---
>  arch/arm/include/asm/mach-imx/sys_proto.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm/include/asm/mach-imx/sys_proto.h b/arch/arm/include/asm/mach-imx/sys_proto.h
> index a02cd40c7d..2a997f280d 100644
> --- a/arch/arm/include/asm/mach-imx/sys_proto.h
> +++ b/arch/arm/include/asm/mach-imx/sys_proto.h
> @@ -37,7 +37,7 @@
>  #define is_mx6sl() (is_cpu_type(MXC_CPU_MX6SL))
>  #define is_mx6solo() (is_cpu_type(MXC_CPU_MX6SOLO))
>  #define is_mx6ul() (is_cpu_type(MXC_CPU_MX6UL))
> -#define is_mx6ull() (is_cpu_type(MXC_CPU_MX6ULL))
> +#define is_mx6ull() (is_cpu_type(MXC_CPU_MX6ULL) || is_cpu_type(MXC_CPU_MX6ULZ))

While I probably understand your intentions, I fear that it will lead to confusion 
when the helper's name does not reflect that more than
one cpu type can match.
What about introducing is_mx6ulX() to signal that the last letter is "don't care"?

Best regards,
Michael

>  #define is_mx6ulz() (is_cpu_type(MXC_CPU_MX6ULZ))
>  #define is_mx6sll() (is_cpu_type(MXC_CPU_MX6SLL))
>  
> 






More information about the U-Boot mailing list