Lines Matching refs:walk
111 struct scatter_walk walk; in ccm_calculate_auth_mac() local
127 scatterwalk_start(&walk, req->src); in ccm_calculate_auth_mac()
130 u32 n = scatterwalk_clamp(&walk, len); in ccm_calculate_auth_mac()
134 scatterwalk_start(&walk, sg_next(walk.sg)); in ccm_calculate_auth_mac()
135 n = scatterwalk_clamp(&walk, len); in ccm_calculate_auth_mac()
137 p = scatterwalk_map(&walk); in ccm_calculate_auth_mac()
143 scatterwalk_advance(&walk, n); in ccm_calculate_auth_mac()
144 scatterwalk_done(&walk, 0, len); in ccm_calculate_auth_mac()
153 struct blkcipher_walk walk; in ccm_encrypt() local
180 blkcipher_walk_init(&walk, dst, src, len); in ccm_encrypt()
181 err = blkcipher_aead_walk_virt_block(&desc, &walk, aead, in ccm_encrypt()
184 while (walk.nbytes) { in ccm_encrypt()
185 u32 tail = walk.nbytes % AES_BLOCK_SIZE; in ccm_encrypt()
187 if (walk.nbytes == len) in ccm_encrypt()
190 ce_aes_ccm_encrypt(walk.dst.virt.addr, walk.src.virt.addr, in ccm_encrypt()
191 walk.nbytes - tail, ctx->key_enc, in ccm_encrypt()
192 num_rounds(ctx), mac, walk.iv); in ccm_encrypt()
194 len -= walk.nbytes - tail; in ccm_encrypt()
195 err = blkcipher_walk_done(&desc, &walk, tail); in ccm_encrypt()
218 struct blkcipher_walk walk; in ccm_decrypt() local
245 blkcipher_walk_init(&walk, dst, src, len); in ccm_decrypt()
246 err = blkcipher_aead_walk_virt_block(&desc, &walk, aead, in ccm_decrypt()
249 while (walk.nbytes) { in ccm_decrypt()
250 u32 tail = walk.nbytes % AES_BLOCK_SIZE; in ccm_decrypt()
252 if (walk.nbytes == len) in ccm_decrypt()
255 ce_aes_ccm_decrypt(walk.dst.virt.addr, walk.src.virt.addr, in ccm_decrypt()
256 walk.nbytes - tail, ctx->key_enc, in ccm_decrypt()
257 num_rounds(ctx), mac, walk.iv); in ccm_decrypt()
259 len -= walk.nbytes - tail; in ccm_decrypt()
260 err = blkcipher_walk_done(&desc, &walk, tail); in ccm_decrypt()