Re: [PATCH v2 14/20] crypto: Curve25519 - generic C library implementations and selftest

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 4 Oct 2019 at 15:57, Jason A. Donenfeld <Jason@xxxxxxxxx> wrote:
>
> On Wed, Oct 02, 2019 at 04:17:07PM +0200, Ard Biesheuvel wrote:
> >        - replace .c #includes with Kconfig based object selection
>
> Cool!
>
> > +config CRYPTO_ARCH_HAVE_LIB_CURVE25519
> > +     tristate
> > +
> > +config CRYPTO_ARCH_HAVE_LIB_CURVE25519_BASE
> > +     bool
> > +
> > +config CRYPTO_LIB_CURVE25519
> > +     tristate "Curve25519 scalar multiplication library"
> > +     depends on CRYPTO_ARCH_HAVE_LIB_CURVE25519 || !CRYPTO_ARCH_HAVE_LIB_CURVE25519
>
> a || !a ==> true
>
> Did you mean for one of these to be _BASE? Or is this a Kconfig trick of
> a different variety that's intentional?
>

This ensures that the base module is not builtin when the arch one is
configured as a module, since in that case, the arch code never gets
called.

> > +libcurve25519-y                                      := curve25519-fiat32.o
> > +libcurve25519-$(CONFIG_ARCH_SUPPORTS_INT128) := curve25519-hacl64.o
>
> Nice idea.



[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux