diff options
author | Atsushi Nemoto <anemo@mba.ocn.ne.jp> | 2006-04-09 18:42:35 -0400 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2006-06-26 03:34:38 -0400 |
commit | e1147d8f47eb8fef93f98a30858192145137d2b2 (patch) | |
tree | 7e1bc0ab3d263e5bd801900195ab310625d9ab59 /crypto/tgr192.c | |
parent | d00e708cef16442cabaf23f653baf924f5d66e83 (diff) |
[CRYPTO] digest: Add alignment handling
Some hash modules load/store data words directly. The digest layer
should pass properly aligned buffer to update()/final() method. This
patch also add cra_alignmask to some hash modules.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto/tgr192.c')
-rw-r--r-- | crypto/tgr192.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crypto/tgr192.c b/crypto/tgr192.c index 2d8e44f6fbe9..1eae1bb7e495 100644 --- a/crypto/tgr192.c +++ b/crypto/tgr192.c | |||
@@ -627,6 +627,7 @@ static struct crypto_alg tgr192 = { | |||
627 | .cra_blocksize = TGR192_BLOCK_SIZE, | 627 | .cra_blocksize = TGR192_BLOCK_SIZE, |
628 | .cra_ctxsize = sizeof(struct tgr192_ctx), | 628 | .cra_ctxsize = sizeof(struct tgr192_ctx), |
629 | .cra_module = THIS_MODULE, | 629 | .cra_module = THIS_MODULE, |
630 | .cra_alignmask = 7, | ||
630 | .cra_list = LIST_HEAD_INIT(tgr192.cra_list), | 631 | .cra_list = LIST_HEAD_INIT(tgr192.cra_list), |
631 | .cra_u = {.digest = { | 632 | .cra_u = {.digest = { |
632 | .dia_digestsize = TGR192_DIGEST_SIZE, | 633 | .dia_digestsize = TGR192_DIGEST_SIZE, |
@@ -641,6 +642,7 @@ static struct crypto_alg tgr160 = { | |||
641 | .cra_blocksize = TGR192_BLOCK_SIZE, | 642 | .cra_blocksize = TGR192_BLOCK_SIZE, |
642 | .cra_ctxsize = sizeof(struct tgr192_ctx), | 643 | .cra_ctxsize = sizeof(struct tgr192_ctx), |
643 | .cra_module = THIS_MODULE, | 644 | .cra_module = THIS_MODULE, |
645 | .cra_alignmask = 7, | ||
644 | .cra_list = LIST_HEAD_INIT(tgr160.cra_list), | 646 | .cra_list = LIST_HEAD_INIT(tgr160.cra_list), |
645 | .cra_u = {.digest = { | 647 | .cra_u = {.digest = { |
646 | .dia_digestsize = TGR160_DIGEST_SIZE, | 648 | .dia_digestsize = TGR160_DIGEST_SIZE, |
@@ -655,6 +657,7 @@ static struct crypto_alg tgr128 = { | |||
655 | .cra_blocksize = TGR192_BLOCK_SIZE, | 657 | .cra_blocksize = TGR192_BLOCK_SIZE, |
656 | .cra_ctxsize = sizeof(struct tgr192_ctx), | 658 | .cra_ctxsize = sizeof(struct tgr192_ctx), |
657 | .cra_module = THIS_MODULE, | 659 | .cra_module = THIS_MODULE, |
660 | .cra_alignmask = 7, | ||
658 | .cra_list = LIST_HEAD_INIT(tgr128.cra_list), | 661 | .cra_list = LIST_HEAD_INIT(tgr128.cra_list), |
659 | .cra_u = {.digest = { | 662 | .cra_u = {.digest = { |
660 | .dia_digestsize = TGR128_DIGEST_SIZE, | 663 | .dia_digestsize = TGR128_DIGEST_SIZE, |