[PATCH] crypto: atmel: remove bogus select
Ludovic Desroches
ludovic.desroches at atmel.com
Mon Feb 9 08:16:12 PST 2015
On Thu, Jan 29, 2015 at 11:24:32PM +0100, Arnd Bergmann wrote:
> On Thursday 29 January 2015 08:33:28 Ludovic Desroches wrote:
> > On Wed, Jan 28, 2015 at 09:09:16PM +0100, Arnd Bergmann wrote:
> > > The Atmel at91 crypto driver unconditionally selects AT_HDMAC,
> > > which results in a Kconfig warning if that driver is not enabled:
> > >
> > > warning: (CRYPTO_DEV_ATMEL_AES) selects AT_HDMAC which has unmet direct dependencies (DMADEVICES && ARCH_AT91)
> > >
> > > The crypty driver itself does not actually have a dependency
> > > on a particular dma engine, other than this being the one that
> > > is used in at91.
> > >
> > > Removing the 'select' gets rid of the warning, with no apparent
> > > downsides.
> >
> > This driver doesn't work without DMA. I think it is the reason why the
> > select AT_HDMAC was used.
> >
>
> I understand the intention, but this what was written in Kconfig is
> not the correct way to express it.
>
Sure.
> A lot of drivers require DMA_ENGINE support, but the linux/dmaengine.h
> header file provides static inline helpers to make sure that things
> still compile if that is disabled, and in the example I mentioned
> above, it does build, but clearly cannot work as the real dmaengine
> interfaces are not provided by the kernel.
>
> What we could do to express the runtime dependency correctly is to add
>
> depends on (ARCH_AT91 && AT_HDMAC) || COMPILE_TEST
>
I am fine with it, only have to add AT_XDMAC or to introduce something
like HAVE_AT91_DMA.
> which would let the driver only be enabled in cases that have a
> reasonable chance of working, but still allow it to be built
> everywhere else.
>
> Arnd
Ludovic
More information about the linux-arm-kernel
mailing list