diff mbox series

[v3,7/9] arm64: defconfig: Enable FSL_MC_BUS and FSL_MC_DPIO

Message ID beb32683-fbd0-fc17-8e71-4f4f51163223@free.fr (mailing list archive)
State New, archived
Headers show
Series Regenerate arm64 defconfig for current kernel | expand

Commit Message

Marc Gonzalez Nov. 9, 2018, 1:07 a.m. UTC
Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2 SoCs")
enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on FSL_MC_DPIO,
which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
CRYPTO_DEV_FSL_DPAA2_CAAM as modules.

Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
---
 arch/arm64/configs/defconfig | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Horia Geanta Nov. 9, 2018, 6:05 a.m. UTC | #1
On 11/9/2018 3:11 AM, Marc Gonzalez wrote:
> Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2 SoCs")
> enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on FSL_MC_DPIO,
> which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
> CRYPTO_DEV_FSL_DPAA2_CAAM as modules.
> 
> Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
Reviewed-by: Horia Geantă <horia.geanta@nxp.com>

Thanks,
Horia
Olof Johansson Dec. 13, 2018, 6:48 a.m. UTC | #2
On Fri, Nov 09, 2018 at 06:05:24AM +0000, Horia Geanta wrote:
> On 11/9/2018 3:11 AM, Marc Gonzalez wrote:
> > Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2 SoCs")
> > enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on FSL_MC_DPIO,
> > which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
> > CRYPTO_DEV_FSL_DPAA2_CAAM as modules.
> > 
> > Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
> Reviewed-by: Horia Geantă <horia.geanta@nxp.com>

I had to redo this one, and when I did I noticed that there's also an ethernet
driver. Should that be enabled as well?


-Olof
Ioana Ciocoi Radulescu Dec. 13, 2018, 9:18 a.m. UTC | #3
> -----Original Message-----
> From: linux-kernel-owner@vger.kernel.org <linux-kernel-
> owner@vger.kernel.org> On Behalf Of Olof Johansson
> Sent: Thursday, December 13, 2018 8:48 AM
> To: Horia Geanta <horia.geanta@nxp.com>
> Cc: Marc Gonzalez <marc.w.gonzalez@free.fr>; arm-soc <arm@kernel.org>;
> Linux ARM <linux-arm-kernel@lists.infradead.org>; LKML <linux-
> kernel@vger.kernel.org>
> Subject: Re: [PATCH v3 7/9] arm64: defconfig: Enable FSL_MC_BUS and
> FSL_MC_DPIO
> 
> On Fri, Nov 09, 2018 at 06:05:24AM +0000, Horia Geanta wrote:
> > On 11/9/2018 3:11 AM, Marc Gonzalez wrote:
> > > Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2
> SoCs")
> > > enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on
> FSL_MC_DPIO,
> > > which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
> > > CRYPTO_DEV_FSL_DPAA2_CAAM as modules.
> > >
> > > Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
> > Reviewed-by: Horia Geantă <horia.geanta@nxp.com>
> 
> I had to redo this one, and when I did I noticed that there's also an ethernet
> driver. Should that be enabled as well?

Yes, it would be best to have the ethernet driver enabled too.

Thanks,
Ioana
Stefan Wahren Dec. 15, 2018, 9:44 p.m. UTC | #4
Hi,

> Olof Johansson <olof@lixom.net> hat am 13. Dezember 2018 um 07:48 geschrieben:
> 
> 
> On Fri, Nov 09, 2018 at 06:05:24AM +0000, Horia Geanta wrote:
> > On 11/9/2018 3:11 AM, Marc Gonzalez wrote:
> > > Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2 SoCs")
> > > enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on FSL_MC_DPIO,
> > > which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
> > > CRYPTO_DEV_FSL_DPAA2_CAAM as modules.
> > > 
> > > Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
> > Reviewed-by: Horia Geantă <horia.geanta@nxp.com>
> 
> I had to redo this one, and when I did I noticed that there's also an ethernet
> driver. Should that be enabled as well?
> 

this patch in next-20181214 breaks "make modules_install" for arm64/defconfig on my Ubuntu machine:

DEPMOD  4.20.0-rc6-next-20181214
depmod: ERROR: Found 6 modules in dependency cycles!
depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> authenc
depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> fsl_mc_dpio
depmod: ERROR: Cycle detected: dpaa2_caam -> caamhash_desc -> dpaa2_caam
depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> caamhash_desc -> error
depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> caamhash_desc -> caamalg_desc

After reverting of this patch the issue disappeared.

Stefan
Horia Geanta Dec. 17, 2018, 3:33 p.m. UTC | #5
On 12/15/2018 11:44 PM, Stefan Wahren wrote:
> Hi,
> 
>> Olof Johansson <olof@lixom.net> hat am 13. Dezember 2018 um 07:48 geschrieben:
>>
>>
>> On Fri, Nov 09, 2018 at 06:05:24AM +0000, Horia Geanta wrote:
>>> On 11/9/2018 3:11 AM, Marc Gonzalez wrote:
>>>> Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2 SoCs")
>>>> enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on FSL_MC_DPIO,
>>>> which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
>>>> CRYPTO_DEV_FSL_DPAA2_CAAM as modules.
>>>>
>>>> Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
>>> Reviewed-by: Horia Geantă <horia.geanta@nxp.com>
>>
>> I had to redo this one, and when I did I noticed that there's also an ethernet
>> driver. Should that be enabled as well?
>>
> 
> this patch in next-20181214 breaks "make modules_install" for arm64/defconfig on my Ubuntu machine:
> 
> DEPMOD  4.20.0-rc6-next-20181214
> depmod: ERROR: Found 6 modules in dependency cycles!
> depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> authenc
> depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> fsl_mc_dpio
> depmod: ERROR: Cycle detected: dpaa2_caam -> caamhash_desc -> dpaa2_caam
> depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> caamhash_desc -> error
> depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> caamhash_desc -> caamalg_desc
> 
> After reverting of this patch the issue disappeared.
> 
Seems there's a dependency cycle b/w dpaa2_caam and caam{alg,hash}_desc, as follows:

A->B
---
dpaa2_caam needs cnstr_* exported by caam{alg,hash}_desc

B->A
---
caam{alg,hash}_desc need caam_imx, caam_little_end:
caam{hash,alg}_desc.c
	--> desc_constr.h (included for descriptors generation functions)
		--> regs.h (included for endianness helpers)
			--> extern bool caam_imx, caam_little_end
caam_imx, caam_little_end are exported by dpaa2_caam - caamalg_qi2.c (when
CONFIG_CRYPTO_DEV_FSL_CAAM=n)

Could we drop this patch, until CAAM driver gets a proper fix (which is not
straightforward)?

Thanks,
Horia
Stefan Wahren Dec. 18, 2018, 8:10 p.m. UTC | #6
Hi Horia,

> Horia Geanta <horia.geanta@nxp.com> hat am 17. Dezember 2018 um 16:33 geschrieben:
> 
> 
> On 12/15/2018 11:44 PM, Stefan Wahren wrote:
> > Hi,
> > 
> >> Olof Johansson <olof@lixom.net> hat am 13. Dezember 2018 um 07:48 geschrieben:
> >>
> >>
> >> On Fri, Nov 09, 2018 at 06:05:24AM +0000, Horia Geanta wrote:
> >>> On 11/9/2018 3:11 AM, Marc Gonzalez wrote:
> >>>> Commit e8342cc7954e ("enable CAAM crypto engine on QorIQ DPAA2 SoCs")
> >>>> enabled CRYPTO_DEV_FSL_DPAA2_CAAM, which depends on FSL_MC_DPIO,
> >>>> which is not set. Enable FSL_MC_BUS, and build FSL_MC_DPIO and
> >>>> CRYPTO_DEV_FSL_DPAA2_CAAM as modules.
> >>>>
> >>>> Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
> >>> Reviewed-by: Horia Geantă <horia.geanta@nxp.com>
> >>
> >> I had to redo this one, and when I did I noticed that there's also an ethernet
> >> driver. Should that be enabled as well?
> >>
> > 
> > this patch in next-20181214 breaks "make modules_install" for arm64/defconfig on my Ubuntu machine:
> > 
> > DEPMOD  4.20.0-rc6-next-20181214
> > depmod: ERROR: Found 6 modules in dependency cycles!
> > depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> authenc
> > depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> fsl_mc_dpio
> > depmod: ERROR: Cycle detected: dpaa2_caam -> caamhash_desc -> dpaa2_caam
> > depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> caamhash_desc -> error
> > depmod: ERROR: Cycle detected: caamalg_desc -> dpaa2_caam -> caamhash_desc -> caamalg_desc
> > 
> > After reverting of this patch the issue disappeared.
> > 
> Seems there's a dependency cycle b/w dpaa2_caam and caam{alg,hash}_desc, as follows:
> 
> A->B
> ---
> dpaa2_caam needs cnstr_* exported by caam{alg,hash}_desc
> 
> B->A
> ---
> caam{alg,hash}_desc need caam_imx, caam_little_end:
> caam{hash,alg}_desc.c
> 	--> desc_constr.h (included for descriptors generation functions)
> 		--> regs.h (included for endianness helpers)
> 			--> extern bool caam_imx, caam_little_end
> caam_imx, caam_little_end are exported by dpaa2_caam - caamalg_qi2.c (when
> CONFIG_CRYPTO_DEV_FSL_CAAM=n)
> 
> Could we drop this patch, until CAAM driver gets a proper fix (which is not
> straightforward)?

this issue still persists in 4.20.0-rc7-next-20181218. Could you please send a patch to revert this change?

Thanks Stefan

> 
> Thanks,
> Horia
> 
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
diff mbox series

Patch

diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index 8e181cca0a05..2662f83c481c 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -200,6 +200,7 @@  CONFIG_DMA_CMA=y
 CONFIG_CMA_SIZE_MBYTES=32
 CONFIG_HISILICON_LPC=y
 CONFIG_SIMPLE_PM_BUS=y
+CONFIG_FSL_MC_BUS=y
 CONFIG_MTD=y
 CONFIG_MTD_BLOCK=y
 CONFIG_MTD_M25P80=y
@@ -631,6 +632,7 @@  CONFIG_QCOM_IOMMU=y
 CONFIG_RPMSG_QCOM_GLINK_RPM=y
 CONFIG_RPMSG_QCOM_SMD=y
 CONFIG_RASPBERRYPI_POWER=y
+CONFIG_FSL_MC_DPIO=m
 CONFIG_QCOM_SMEM=y
 CONFIG_QCOM_SMD_RPM=y
 CONFIG_QCOM_SMP2P=y
@@ -718,6 +720,7 @@  CONFIG_NLS_ISO8859_1=y
 CONFIG_SECURITY=y
 CONFIG_CRYPTO_ECHAINIV=y
 CONFIG_CRYPTO_ANSI_CPRNG=y
+CONFIG_CRYPTO_DEV_FSL_DPAA2_CAAM=m
 CONFIG_PRINTK_TIME=y
 CONFIG_DEBUG_INFO=y
 CONFIG_DEBUG_FS=y
@@ -727,4 +730,3 @@  CONFIG_DEBUG_KERNEL=y
 # CONFIG_DEBUG_PREEMPT is not set
 # CONFIG_FTRACE is not set
 CONFIG_MEMTEST=y
-CONFIG_CRYPTO_DEV_FSL_DPAA2_CAAM=y