1. 26 Jul, 2019 1 commit
    • Ard Biesheuvel's avatar
      crypto: aegis - avoid prerotated AES tables · 521cdde7
      Ard Biesheuvel authored
      
      The generic AES code provides four sets of lookup tables, where each
      set consists of four tables containing the same 32-bit values, but
      rotated by 0, 8, 16 and 24 bits, respectively. This makes sense for
      CISC architectures such as x86 which support memory operands, but
      for other architectures, the rotates are quite cheap, and using all
      four tables needlessly thrashes the D-cache, and actually hurts rather
      than helps performance.
      
      Since x86 already has its own implementation of AEGIS based on AES-NI
      instructions, let's tweak the generic implementation towards other
      architectures, and avoid the prerotated tables, and perform the
      rotations inline. On ARM Cortex-A53, this results in a ~8% speedup.
      Acked-by: default avatarOndrej Mosnacek <omosnace@redhat.com>
      Signed-off-by: default avatarArd Biesheuvel <ard.biesheuvel@linaro.org>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      521cdde7
  2. 25 Jan, 2019 1 commit
    • Thomas Gleixner's avatar
      crypto: aegis - Cleanup license mess · ea5d8cfa
      Thomas Gleixner authored
      Precise and non-ambiguous license information is important. The recently
      added aegis header file has a SPDX license identifier, which is nice, but
      at the same time it has a contradictionary license boiler plate text.
      
        SPDX-License-Identifier: GPL-2.0
      
      versus
      
        * This program is free software; you can redistribute it and/or modify it
        * under the terms of the GNU General Public License as published by the Free
        * Software Foundation; either version 2 of the License, or (at your option)
        * any later version
      
      Oh well.
      
      As the other aegis related files are licensed under the GPL v2 or later,
      it's assumed that the boiler plate code is correct, but the SPDX license
      identifier is wrong.
      
      Fix the SPDX identifier and remove the boiler plate as it is redundant.
      
      Fixes: f606a88e
      
       ("crypto: aegis - Add generic AEGIS AEAD implementations")
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      Cc: Ondrej Mosnacek <omosnacek@gmail.com>
      Cc: Herbert Xu <herbert@gondor.apana.org.au>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: linux-crypto@vger.kernel.org
      Acked-by: default avatarOndrej Mosnacek <omosnacek@gmail.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      ea5d8cfa
  3. 08 Oct, 2018 1 commit
  4. 18 May, 2018 1 commit