1
0
Fork 0

MLKU-129-1 crypto: caam - add support for i.mx8M Plus

Add support for the crypto engine used in i.mx8mp (i.MX 8M "Plus"),
which is very similar to the one used in i.mx8mq, i.mx8mm, i.mx8mn.

[
NOTE:
Upstream support for i.MX8MN:
https://patchwork.kernel.org/patch/11319997/
partially includes this (imx_soc_table updates).
]

Signed-off-by: Horia Geantă <horia.geanta@nxp.com>
Reviewed-by: Iuliana Prodan <iuliana.prodan@nxp.com>
5.4-rM2-2.2.x-imx-squashed
Horia Geantă 2020-01-10 13:51:59 +02:00
parent add401e6f0
commit 1e39140a8c
1 changed files with 6 additions and 6 deletions

View File

@ -100,12 +100,13 @@ static inline int run_descriptor_deco0(struct device *ctrldev, u32 *desc,
if (ctrlpriv->virt_en == 1 ||
/*
* Apparently on i.MX8MQ, 8MM, 8MN it doesn't matter if virt_en == 1
* Apparently on i.MX8M{Q,M,N,P} it doesn't matter if virt_en == 1
* and the following steps should be performed regardless
*/
of_machine_is_compatible("fsl,imx8mq") ||
of_machine_is_compatible("fsl,imx8mm") ||
of_machine_is_compatible("fsl,imx8mn")) {
of_machine_is_compatible("fsl,imx8mn") ||
of_machine_is_compatible("fsl,imx8mp")) {
clrsetbits_32(&ctrl->deco_rsr, 0, DECORSR_JR0);
while (!(rd_reg32(&ctrl->deco_rsr) & DECORSR_VALID) &&
@ -516,9 +517,7 @@ static const struct soc_device_attribute caam_imx_soc_table[] = {
{ .soc_id = "i.MX6UL", .data = &caam_imx6ul_data },
{ .soc_id = "i.MX6*", .data = &caam_imx6_data },
{ .soc_id = "i.MX7*", .data = &caam_imx7_data },
{ .soc_id = "i.MX8MQ", .data = &caam_imx7_data },
{ .soc_id = "i.MX8MM", .data = &caam_imx7_data },
{ .soc_id = "i.MX8MN", .data = &caam_imx7_data },
{ .soc_id = "i.MX8M*", .data = &caam_imx7_data },
{ .family = "Freescale i.MX" },
{ /* sentinel */ }
};
@ -755,7 +754,8 @@ iomap_ctrl:
return PTR_ERR(ctrlpriv->sm_base);
}
if (!of_machine_is_compatible("fsl,imx8mn") &&
if (!of_machine_is_compatible("fsl,imx8mp") &&
!of_machine_is_compatible("fsl,imx8mn") &&
!of_machine_is_compatible("fsl,imx8mm") &&
!of_machine_is_compatible("fsl,imx8mq") &&
!of_machine_is_compatible("fsl,imx8qm") &&