Home
last modified time | relevance | path

Searched refs:alignmask (Results 1 - 25 of 29) sorted by relevance

12

/kernel/linux/linux-5.10/crypto/
H A Dcipher.c23 unsigned long alignmask = crypto_cipher_alignmask(tfm); in setkey_unaligned() local
28 absize = keylen + alignmask; in setkey_unaligned()
33 alignbuffer = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in setkey_unaligned()
45 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_cipher_setkey() local
50 if ((unsigned long)key & alignmask) in crypto_cipher_setkey()
60 unsigned long alignmask = crypto_cipher_alignmask(tfm); in cipher_crypt_one() local
65 if (unlikely(((unsigned long)dst | (unsigned long)src) & alignmask)) { in cipher_crypt_one()
68 u8 *tmp = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in cipher_crypt_one()
H A Dcmac.c52 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_cmac_digest_setkey() local
56 (alignmask | (__alignof__(__be64) - 1)) + 1); in crypto_cmac_digest_setkey()
106 unsigned long alignmask = crypto_shash_alignmask(pdesc->tfm); in crypto_cmac_digest_init() local
109 u8 *prev = PTR_ALIGN((void *)ctx->ctx, alignmask + 1) + bs; in crypto_cmac_digest_init()
121 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_cmac_digest_update() local
126 u8 *odds = PTR_ALIGN((void *)ctx->ctx, alignmask + 1); in crypto_cmac_digest_update()
167 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_cmac_digest_final() local
173 (alignmask | (__alignof__(__be64) - 1)) + 1); in crypto_cmac_digest_final()
174 u8 *odds = PTR_ALIGN((void *)ctx->ctx, alignmask + 1); in crypto_cmac_digest_final()
227 unsigned long alignmask; in cmac_create() local
[all...]
H A Dxcbc.c53 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_xcbc_digest_setkey() local
55 u8 *consts = PTR_ALIGN(&ctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_setkey()
73 unsigned long alignmask = crypto_shash_alignmask(pdesc->tfm); in crypto_xcbc_digest_init() local
76 u8 *prev = PTR_ALIGN(&ctx->ctx[0], alignmask + 1) + bs; in crypto_xcbc_digest_init()
88 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_xcbc_digest_update() local
93 u8 *odds = PTR_ALIGN(&ctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_update()
134 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_xcbc_digest_final() local
139 u8 *consts = PTR_ALIGN(&tctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_final()
140 u8 *odds = PTR_ALIGN(&ctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_final()
193 unsigned long alignmask; in xcbc_create() local
[all...]
H A Dahash.c43 unsigned int alignmask = walk->alignmask; in hash_walk_next() local
51 if (offset & alignmask) { in hash_walk_next()
52 unsigned int unaligned = alignmask + 1 - (offset & alignmask); in hash_walk_next()
81 unsigned int alignmask = walk->alignmask; in crypto_hash_walk_done() local
85 if (walk->entrylen && (walk->offset & alignmask) && !err) { in crypto_hash_walk_done()
88 walk->offset = ALIGN(walk->offset, alignmask + 1); in crypto_hash_walk_done()
129 walk->alignmask in crypto_hash_walk_first()
140 unsigned long alignmask = crypto_ahash_alignmask(tfm); ahash_setkey_unaligned() local
175 unsigned long alignmask = crypto_ahash_alignmask(tfm); crypto_ahash_setkey() local
202 unsigned long alignmask = crypto_ahash_alignmask(tfm); ahash_save_req() local
332 unsigned long alignmask = crypto_ahash_alignmask(tfm); crypto_ahash_op() local
[all...]
H A Dshash.c46 unsigned long alignmask = crypto_shash_alignmask(tfm); in shash_setkey_unaligned() local
51 absize = keylen + (alignmask & ~(crypto_tfm_ctx_alignment() - 1)); in shash_setkey_unaligned()
56 alignbuffer = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in shash_setkey_unaligned()
73 unsigned long alignmask = crypto_shash_alignmask(tfm); in crypto_shash_setkey() local
76 if ((unsigned long)key & alignmask) in crypto_shash_setkey()
96 unsigned long alignmask = crypto_shash_alignmask(tfm); in shash_update_unaligned() local
97 unsigned int unaligned_len = alignmask + 1 - in shash_update_unaligned()
98 ((unsigned long)data & alignmask); in shash_update_unaligned()
104 u8 *buf = PTR_ALIGN(&ubuf[0], alignmask + 1); in shash_update_unaligned()
126 unsigned long alignmask in crypto_shash_update() local
138 unsigned long alignmask = crypto_shash_alignmask(tfm); shash_final_unaligned() local
167 unsigned long alignmask = crypto_shash_alignmask(tfm); crypto_shash_final() local
188 unsigned long alignmask = crypto_shash_alignmask(tfm); crypto_shash_finup() local
209 unsigned long alignmask = crypto_shash_alignmask(tfm); crypto_shash_digest() local
[all...]
H A Dskcipher.c97 addr = (u8 *)ALIGN((unsigned long)walk->buffer, walk->alignmask + 1); in skcipher_done_slow()
193 data = PTR_ALIGN(&p->buffer[0], walk->alignmask + 1); in skcipher_walk_complete()
227 unsigned alignmask = walk->alignmask; in skcipher_next_slow() local
252 /* Minimum size to align p->buffer by alignmask. */ in skcipher_next_slow()
253 n += alignmask & ~a; in skcipher_next_slow()
256 n += (bsize - 1) & ~(alignmask | a); in skcipher_next_slow()
273 walk->dst.virt.addr = PTR_ALIGN(buffer, alignmask + 1); in skcipher_next_slow()
366 if (unlikely((walk->in.offset | walk->out.offset) & walk->alignmask)) { in skcipher_walk_next()
399 unsigned alignmask in skcipher_copy_iv() local
581 unsigned long alignmask = crypto_skcipher_alignmask(tfm); skcipher_setkey_unaligned() local
603 unsigned long alignmask = crypto_skcipher_alignmask(tfm); crypto_skcipher_setkey() local
[all...]
H A Daead.c25 unsigned long alignmask = crypto_aead_alignmask(tfm); in setkey_unaligned() local
30 absize = keylen + alignmask; in setkey_unaligned()
35 alignbuffer = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in setkey_unaligned()
45 unsigned long alignmask = crypto_aead_alignmask(tfm); in crypto_aead_setkey() local
48 if ((unsigned long)key & alignmask) in crypto_aead_setkey()
H A Dctr.c31 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_ctr_crypt_final() local
34 u8 *keystream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_ctr_crypt_final()
77 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_ctr_crypt_inplace() local
82 u8 *keystream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_ctr_crypt_inplace()
H A Dcfb.c45 const unsigned long alignmask = crypto_skcipher_alignmask(tfm); in crypto_cfb_final() local
47 u8 *stream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_cfb_final()
H A Dtestmgr.c247 * @offset_relative_to_alignmask: if true, add the algorithm's alignmask to the
275 * @iv_offset_relative_to_alignmask: if true, add the algorithm's alignmask to
278 * @key_offset_relative_to_alignmask: if true, add the algorithm's alignmask to
322 .name = "buffer aligned only to alignmask",
384 .name = "digest buffer aligned only to alignmask",
542 * @alignmask: the algorithm's alignmask
556 const unsigned int alignmask, in build_test_sglist()
602 offset += alignmask; in build_test_sglist()
741 unsigned int alignmask, in build_cipher_test_sglists()
554 build_test_sglist(struct test_sglist *tsgl, const struct test_sg_division *divs, const unsigned int alignmask, const unsigned int total_len, struct iov_iter *data, const struct test_sg_division *out_divs[XBUFSIZE]) build_test_sglist() argument
739 build_cipher_test_sglists(struct cipher_test_sglists *tsgls, const struct testvec_config *cfg, unsigned int alignmask, unsigned int src_total_len, unsigned int dst_total_len, const struct kvec *inputs, unsigned int nr_inputs) build_cipher_test_sglists() argument
776 prepare_keybuf(const u8 *key, unsigned int ksize, const struct testvec_config *cfg, unsigned int alignmask, const u8 **keybuf_ret, const u8 **keyptr_ret) prepare_keybuf() argument
1122 build_hash_sglist(struct test_sglist *tsgl, const struct hash_testvec *vec, const struct testvec_config *cfg, unsigned int alignmask, const struct test_sg_division *divs[XBUFSIZE]) build_hash_sglist() argument
1183 const unsigned int alignmask = crypto_shash_alignmask(tfm); test_shash_vec_cfg() local
1367 const unsigned int alignmask = crypto_ahash_alignmask(tfm); test_ahash_vec_cfg() local
1934 const unsigned int alignmask = crypto_aead_alignmask(tfm); test_aead_vec_cfg() local
2706 const unsigned int alignmask = crypto_skcipher_alignmask(tfm); test_skcipher_vec_cfg() local
[all...]
/kernel/linux/linux-6.6/crypto/
H A Dcipher.c24 unsigned long alignmask = crypto_cipher_alignmask(tfm); in setkey_unaligned() local
29 absize = keylen + alignmask; in setkey_unaligned()
34 alignbuffer = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in setkey_unaligned()
47 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_cipher_setkey() local
52 if ((unsigned long)key & alignmask) in crypto_cipher_setkey()
62 unsigned long alignmask = crypto_cipher_alignmask(tfm); in cipher_crypt_one() local
67 if (unlikely(((unsigned long)dst | (unsigned long)src) & alignmask)) { in cipher_crypt_one()
70 u8 *tmp = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in cipher_crypt_one()
H A Dcmac.c53 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_cmac_digest_setkey() local
57 (alignmask | (__alignof__(__be64) - 1)) + 1); in crypto_cmac_digest_setkey()
107 unsigned long alignmask = crypto_shash_alignmask(pdesc->tfm); in crypto_cmac_digest_init() local
110 u8 *prev = PTR_ALIGN((void *)ctx->ctx, alignmask + 1) + bs; in crypto_cmac_digest_init()
122 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_cmac_digest_update() local
127 u8 *odds = PTR_ALIGN((void *)ctx->ctx, alignmask + 1); in crypto_cmac_digest_update()
168 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_cmac_digest_final() local
174 (alignmask | (__alignof__(__be64) - 1)) + 1); in crypto_cmac_digest_final()
175 u8 *odds = PTR_ALIGN((void *)ctx->ctx, alignmask + 1); in crypto_cmac_digest_final()
244 unsigned long alignmask; in cmac_create() local
[all...]
H A Dxcbc.c54 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_xcbc_digest_setkey() local
56 u8 *consts = PTR_ALIGN(&ctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_setkey()
74 unsigned long alignmask = crypto_shash_alignmask(pdesc->tfm); in crypto_xcbc_digest_init() local
77 u8 *prev = PTR_ALIGN(&ctx->ctx[0], alignmask + 1) + bs; in crypto_xcbc_digest_init()
89 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_xcbc_digest_update() local
94 u8 *odds = PTR_ALIGN(&ctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_update()
135 unsigned long alignmask = crypto_shash_alignmask(parent); in crypto_xcbc_digest_final() local
140 u8 *consts = PTR_ALIGN(&tctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_final()
141 u8 *odds = PTR_ALIGN(&ctx->ctx[0], alignmask + 1); in crypto_xcbc_digest_final()
194 unsigned long alignmask; in xcbc_create() local
[all...]
H A Dahash.c36 unsigned int alignmask = walk->alignmask; in hash_walk_next() local
44 if (offset & alignmask) { in hash_walk_next()
45 unsigned int unaligned = alignmask + 1 - (offset & alignmask); in hash_walk_next()
74 unsigned int alignmask = walk->alignmask; in crypto_hash_walk_done() local
78 if (walk->entrylen && (walk->offset & alignmask) && !err) { in crypto_hash_walk_done()
81 walk->offset = ALIGN(walk->offset, alignmask + 1); in crypto_hash_walk_done()
122 walk->alignmask in crypto_hash_walk_first()
133 unsigned long alignmask = crypto_ahash_alignmask(tfm); ahash_setkey_unaligned() local
168 unsigned long alignmask = crypto_ahash_alignmask(tfm); crypto_ahash_setkey() local
190 unsigned long alignmask = crypto_ahash_alignmask(tfm); ahash_save_req() local
291 unsigned long alignmask = crypto_ahash_alignmask(tfm); crypto_ahash_op() local
[all...]
H A Dshash.c45 unsigned long alignmask = crypto_shash_alignmask(tfm); in shash_setkey_unaligned() local
50 absize = keylen + (alignmask & ~(crypto_tfm_ctx_alignment() - 1)); in shash_setkey_unaligned()
55 alignbuffer = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in shash_setkey_unaligned()
72 unsigned long alignmask = crypto_shash_alignmask(tfm); in crypto_shash_setkey() local
75 if ((unsigned long)key & alignmask) in crypto_shash_setkey()
95 unsigned long alignmask = crypto_shash_alignmask(tfm); in shash_update_unaligned() local
96 unsigned int unaligned_len = alignmask + 1 - in shash_update_unaligned()
97 ((unsigned long)data & alignmask); in shash_update_unaligned()
103 u8 *buf = PTR_ALIGN(&ubuf[0], alignmask + 1); in shash_update_unaligned()
125 unsigned long alignmask in crypto_shash_update() local
143 unsigned long alignmask = crypto_shash_alignmask(tfm); shash_final_unaligned() local
172 unsigned long alignmask = crypto_shash_alignmask(tfm); crypto_shash_final() local
199 unsigned long alignmask = crypto_shash_alignmask(tfm); crypto_shash_finup() local
232 unsigned long alignmask = crypto_shash_alignmask(tfm); crypto_shash_digest() local
[all...]
H A Dskcipher.c116 addr = (u8 *)ALIGN((unsigned long)walk->buffer, walk->alignmask + 1); in skcipher_done_slow()
212 data = PTR_ALIGN(&p->buffer[0], walk->alignmask + 1); in skcipher_walk_complete()
246 unsigned alignmask = walk->alignmask; in skcipher_next_slow() local
271 /* Minimum size to align p->buffer by alignmask. */ in skcipher_next_slow()
272 n += alignmask & ~a; in skcipher_next_slow()
275 n += (bsize - 1) & ~(alignmask | a); in skcipher_next_slow()
292 walk->dst.virt.addr = PTR_ALIGN(buffer, alignmask + 1); in skcipher_next_slow()
385 if (unlikely((walk->in.offset | walk->out.offset) & walk->alignmask)) { in skcipher_walk_next()
418 unsigned alignmask in skcipher_copy_iv() local
594 unsigned long alignmask = crypto_skcipher_alignmask(tfm); skcipher_setkey_unaligned() local
616 unsigned long alignmask = crypto_skcipher_alignmask(tfm); crypto_skcipher_setkey() local
[all...]
H A Daead.c35 unsigned long alignmask = crypto_aead_alignmask(tfm); in setkey_unaligned() local
40 absize = keylen + alignmask; in setkey_unaligned()
45 alignbuffer = (u8 *)ALIGN((unsigned long)buffer, alignmask + 1); in setkey_unaligned()
56 unsigned long alignmask = crypto_aead_alignmask(tfm); in crypto_aead_setkey() local
59 if ((unsigned long)key & alignmask) in crypto_aead_setkey()
H A Dctr.c32 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_ctr_crypt_final() local
35 u8 *keystream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_ctr_crypt_final()
78 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_ctr_crypt_inplace() local
83 u8 *keystream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_ctr_crypt_inplace()
H A Dcfb.c46 const unsigned long alignmask = crypto_skcipher_alignmask(tfm); in crypto_cfb_final() local
48 u8 *stream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_cfb_final()
H A Dxctr.c79 unsigned long alignmask = crypto_cipher_alignmask(tfm); in crypto_xctr_crypt_inplace() local
83 u8 *keystream = PTR_ALIGN(tmp + 0, alignmask + 1); in crypto_xctr_crypt_inplace()
H A Dtestmgr.c261 * @offset_relative_to_alignmask: if true, add the algorithm's alignmask to the
289 * @iv_offset_relative_to_alignmask: if true, add the algorithm's alignmask to
292 * @key_offset_relative_to_alignmask: if true, add the algorithm's alignmask to
341 .name = "buffer aligned only to alignmask",
411 .name = "digest buffer aligned only to alignmask",
569 * @alignmask: the algorithm's alignmask
583 const unsigned int alignmask, in build_test_sglist()
629 offset += alignmask; in build_test_sglist()
768 unsigned int alignmask, in build_cipher_test_sglists()
581 build_test_sglist(struct test_sglist *tsgl, const struct test_sg_division *divs, const unsigned int alignmask, const unsigned int total_len, struct iov_iter *data, const struct test_sg_division *out_divs[XBUFSIZE]) build_test_sglist() argument
766 build_cipher_test_sglists(struct cipher_test_sglists *tsgls, const struct testvec_config *cfg, unsigned int alignmask, unsigned int src_total_len, unsigned int dst_total_len, const struct kvec *inputs, unsigned int nr_inputs) build_cipher_test_sglists() argument
824 prepare_keybuf(const u8 *key, unsigned int ksize, const struct testvec_config *cfg, unsigned int alignmask, const u8 **keybuf_ret, const u8 **keyptr_ret) prepare_keybuf() argument
1223 build_hash_sglist(struct test_sglist *tsgl, const struct hash_testvec *vec, const struct testvec_config *cfg, unsigned int alignmask, const struct test_sg_division *divs[XBUFSIZE]) build_hash_sglist() argument
1278 const unsigned int alignmask = crypto_shash_alignmask(tfm); test_shash_vec_cfg() local
1462 const unsigned int alignmask = crypto_ahash_alignmask(tfm); test_ahash_vec_cfg() local
2036 const unsigned int alignmask = crypto_aead_alignmask(tfm); test_aead_vec_cfg() local
2815 const unsigned int alignmask = crypto_skcipher_alignmask(tfm); test_skcipher_vec_cfg() local
[all...]
/kernel/linux/linux-5.10/include/crypto/
H A Dscatterwalk.h49 unsigned int alignmask) in scatterwalk_aligned()
51 return !(walk->offset & alignmask); in scatterwalk_aligned()
48 scatterwalk_aligned(struct scatter_walk *walk, unsigned int alignmask) scatterwalk_aligned() argument
/kernel/linux/linux-5.10/include/crypto/internal/
H A Dskcipher.h65 unsigned int alignmask; member
H A Dhash.h21 unsigned int alignmask; member
/kernel/linux/linux-6.6/include/crypto/internal/
H A Dskcipher.h74 unsigned int alignmask; member

Completed in 19 milliseconds

12