aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2008-01-08 01:16:44 -0500
committerHerbert Xu <herbert@gondor.apana.org.au>2008-01-10 16:17:01 -0500
commit6eb7228421c01ba48a6a88a7a5b3e71cfb70d4a9 (patch)
tree15ec08e0ede5ca43e348a30176cd7c96ffb7985d /include
parent38ed9ab23b8614c9c1553b2961ef2627f3088fd9 (diff)
[CRYPTO] api: Set default CRYPTO_MINALIGN to unsigned long long
Thanks to David Miller for pointing out that the SLAB (or SLOB/SLUB) cache uses the alignment of unsigned long long if the architecture kmalloc/slab alignment macros are not defined. This patch changes the CRYPTO_MINALIGN so that it uses the same default value. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'include')
-rw-r--r--include/linux/crypto.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/include/linux/crypto.h b/include/linux/crypto.h
index 0aba10460201..5e02d1b46370 100644
--- a/include/linux/crypto.h
+++ b/include/linux/crypto.h
@@ -90,13 +90,11 @@
90#define CRYPTO_MINALIGN ARCH_KMALLOC_MINALIGN 90#define CRYPTO_MINALIGN ARCH_KMALLOC_MINALIGN
91#elif defined(ARCH_SLAB_MINALIGN) 91#elif defined(ARCH_SLAB_MINALIGN)
92#define CRYPTO_MINALIGN ARCH_SLAB_MINALIGN 92#define CRYPTO_MINALIGN ARCH_SLAB_MINALIGN
93#else
94#define CRYPTO_MINALIGN __alignof__(unsigned long long)
93#endif 95#endif
94 96
95#ifdef CRYPTO_MINALIGN
96#define CRYPTO_MINALIGN_ATTR __attribute__ ((__aligned__(CRYPTO_MINALIGN))) 97#define CRYPTO_MINALIGN_ATTR __attribute__ ((__aligned__(CRYPTO_MINALIGN)))
97#else
98#define CRYPTO_MINALIGN_ATTR
99#endif
100 98
101struct scatterlist; 99struct scatterlist;
102struct crypto_ablkcipher; 100struct crypto_ablkcipher;