Skip to content

Commit 4578932

Browse files
herbertxDavid S. Miller
authored and
David S. Miller
committed
[BLOCK] dm-crypt: Align IV to u64 for essiv
This patch makes the IV u64-aligned since essiv does a u64 store to it. Signed-off-by: Herbert Xu <[email protected]>
1 parent 48527fa commit 4578932

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/md/dm-crypt.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ crypt_convert_scatterlist(struct crypt_config *cc, struct scatterlist *out,
272272
struct scatterlist *in, unsigned int length,
273273
int write, sector_t sector)
274274
{
275-
u8 iv[cc->iv_size];
275+
u8 iv[cc->iv_size] __attribute__ ((aligned(__alignof__(u64))));
276276
struct blkcipher_desc desc = {
277277
.tfm = cc->tfm,
278278
.info = iv,

0 commit comments

Comments
 (0)