soc: imx: check ls1021a

fsl,ls1021a is a mach under arch/arm/mach-imx/, however it could
not use the soc driver which will break caam on ls1021a platform.

So directly return if it is compatible with fsl,ls1021a.

Fixes: 52102a3ba6 ("soc: imx: move cpu code to drivers/soc/imx")
Signed-off-by: Peng Fan <peng.fan@nxp.com>
Tested-by: Horia Geantă <horia.geanta@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
This commit is contained in:
Peng Fan 2020-07-09 16:25:45 +08:00 committed by Shawn Guo
parent f8951dce10
commit 7f6e8dffc3
1 changed files with 3 additions and 0 deletions

View File

@ -33,6 +33,9 @@ static int __init imx_soc_device_init(void)
u32 val;
int ret;
if (of_machine_is_compatible("fsl,ls1021a"))
return 0;
soc_dev_attr = kzalloc(sizeof(*soc_dev_attr), GFP_KERNEL);
if (!soc_dev_attr)
return -ENOMEM;