crypto: x86 - use local headers for x86 specific shared declarations

The Camellia, Serpent and Twofish related header files only contain
declarations that are shared between different implementations of the
respective algorithms residing under arch/x86/crypto, and none of their
contents should be used elsewhere. So move the header files into the
same location, and use local #includes instead.

Acked-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
Ard Biesheuvel 2021-01-05 17:48:09 +01:00 committed by Herbert Xu
parent 64ca771cd6
commit a04ea6f7ff
12 changed files with 8 additions and 8 deletions

View File

@ -5,7 +5,6 @@
* Copyright © 2013 Jussi Kivilinna <jussi.kivilinna@mbnet.fi> * Copyright © 2013 Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
*/ */
#include <asm/crypto/camellia.h>
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <crypto/internal/simd.h> #include <crypto/internal/simd.h>
#include <linux/crypto.h> #include <linux/crypto.h>
@ -13,6 +12,7 @@
#include <linux/module.h> #include <linux/module.h>
#include <linux/types.h> #include <linux/types.h>
#include "camellia.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
#define CAMELLIA_AESNI_PARALLEL_BLOCKS 16 #define CAMELLIA_AESNI_PARALLEL_BLOCKS 16

View File

@ -5,7 +5,6 @@
* Copyright © 2012-2013 Jussi Kivilinna <jussi.kivilinna@iki.fi> * Copyright © 2012-2013 Jussi Kivilinna <jussi.kivilinna@iki.fi>
*/ */
#include <asm/crypto/camellia.h>
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <crypto/internal/simd.h> #include <crypto/internal/simd.h>
#include <linux/crypto.h> #include <linux/crypto.h>
@ -13,6 +12,7 @@
#include <linux/module.h> #include <linux/module.h>
#include <linux/types.h> #include <linux/types.h>
#include "camellia.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
#define CAMELLIA_AESNI_PARALLEL_BLOCKS 16 #define CAMELLIA_AESNI_PARALLEL_BLOCKS 16

View File

@ -14,8 +14,8 @@
#include <linux/module.h> #include <linux/module.h>
#include <linux/types.h> #include <linux/types.h>
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <asm/crypto/camellia.h>
#include "camellia.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
/* regular block cipher functions */ /* regular block cipher functions */

View File

@ -12,8 +12,8 @@
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <crypto/internal/simd.h> #include <crypto/internal/simd.h>
#include <crypto/serpent.h> #include <crypto/serpent.h>
#include <asm/crypto/serpent-avx.h>
#include "serpent-avx.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
#define SERPENT_AVX2_PARALLEL_BLOCKS 16 #define SERPENT_AVX2_PARALLEL_BLOCKS 16

View File

@ -15,8 +15,8 @@
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <crypto/internal/simd.h> #include <crypto/internal/simd.h>
#include <crypto/serpent.h> #include <crypto/serpent.h>
#include <asm/crypto/serpent-avx.h>
#include "serpent-avx.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
/* 8-way parallel cipher functions */ /* 8-way parallel cipher functions */

View File

@ -20,8 +20,8 @@
#include <crypto/b128ops.h> #include <crypto/b128ops.h>
#include <crypto/internal/simd.h> #include <crypto/internal/simd.h>
#include <crypto/serpent.h> #include <crypto/serpent.h>
#include <asm/crypto/serpent-sse2.h>
#include "serpent-sse2.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
static int serpent_setkey_skcipher(struct crypto_skcipher *tfm, static int serpent_setkey_skcipher(struct crypto_skcipher *tfm,

View File

@ -15,8 +15,8 @@
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <crypto/internal/simd.h> #include <crypto/internal/simd.h>
#include <crypto/twofish.h> #include <crypto/twofish.h>
#include <asm/crypto/twofish.h>
#include "twofish.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
#define TWOFISH_PARALLEL_BLOCKS 8 #define TWOFISH_PARALLEL_BLOCKS 8

View File

@ -5,7 +5,6 @@
* Copyright (c) 2011 Jussi Kivilinna <jussi.kivilinna@mbnet.fi> * Copyright (c) 2011 Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
*/ */
#include <asm/crypto/twofish.h>
#include <crypto/algapi.h> #include <crypto/algapi.h>
#include <crypto/twofish.h> #include <crypto/twofish.h>
#include <linux/crypto.h> #include <linux/crypto.h>
@ -13,6 +12,7 @@
#include <linux/module.h> #include <linux/module.h>
#include <linux/types.h> #include <linux/types.h>
#include "twofish.h"
#include "ecb_cbc_helpers.h" #include "ecb_cbc_helpers.h"
EXPORT_SYMBOL_GPL(__twofish_enc_blk_3way); EXPORT_SYMBOL_GPL(__twofish_enc_blk_3way);