[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHCN7xLkV1WC=9ACj1Mi8+uE8kRCEjCEe+Y36pXwkNeNrgrNVg@mail.gmail.com>
Date: Fri, 6 Dec 2019 13:55:43 -0600
From: Adam Ford <aford173@...il.com>
To: Schrempf Frieder <frieder.schrempf@...tron.de>
Cc: "linux-crypto@...r.kernel.org" <linux-crypto@...r.kernel.org>,
Mark Rutland <mark.rutland@....com>,
Aymen Sghaier <aymen.sghaier@....com>,
Fabio Estevam <festevam@...il.com>,
Herbert Xu <herbert@...dor.apana.org.au>,
Horia Geantă <horia.geanta@....com>,
"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
Sascha Hauer <s.hauer@...gutronix.de>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Rob Herring <robh+dt@...nel.org>,
NXP Linux Team <linux-imx@....com>,
Pengutronix Kernel Team <kernel@...gutronix.de>,
Shawn Guo <shawnguo@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH 1/2] crypto: caam: Change the i.MX8MQ check support all
i.MX8M variants
On Wed, Dec 4, 2019 at 5:38 AM Schrempf Frieder
<frieder.schrempf@...tron.de> wrote:
>
> Hi Adam,
>
> On 30.11.19 23:51, Adam Ford wrote:
> > The i.MX8M Mini uses the same crypto engine as the i.MX8MQ, but
> > the driver is restricting the check to just the i.MX8MQ.
> >
> > This patch lets the driver support all i.MX8M Variants if enabled.
> >
> > Signed-off-by: Adam Ford <aford173@...il.com>
>
> What about the following lines in run_descriptor_deco0()? Does this
> condition also apply to i.MX8MM?
I think that's a question for NXP. I am not seeing that in the NXP
Linux Release, and I don't have an 8MQ to compare.
I was able to get the driver working on the i.MXMM with the patch.
NXP Team,
Do you have any opinions on this?
adam
>
> drivers/crypto/caam/ctrl.c:
>
> if (ctrlpriv->virt_en == 1 ||
> /*
> * Apparently on i.MX8MQ it doesn't matter if virt_en == 1
> * and the following steps should be performed regardless
> */
> of_machine_is_compatible("fsl,imx8mq")) {
> clrsetbits_32(&ctrl->deco_rsr, 0, DECORSR_JR0);
>
> while (!(rd_reg32(&ctrl->deco_rsr) & DECORSR_VALID) &&
> --timeout)
> cpu_relax();
>
> timeout = 100000;
> }
>
> Regards,
> Frieder
>
> >
> > diff --git a/drivers/crypto/caam/ctrl.c b/drivers/crypto/caam/ctrl.c
> > index db22777d59b4..1ce03f8961b6 100644
> > --- a/drivers/crypto/caam/ctrl.c
> > +++ b/drivers/crypto/caam/ctrl.c
> > @@ -527,7 +527,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.MX8M*", .data = &caam_imx7_data },
> > { .family = "Freescale i.MX" },
> > { /* sentinel */ }
> > };
> >
Powered by blists - more mailing lists