Lines Matching refs:walk
220 struct blkcipher_walk walk; in ecb_encrypt() local
223 blkcipher_walk_init(&walk, dst, src, nbytes); in ecb_encrypt()
224 err = blkcipher_walk_virt(desc, &walk); in ecb_encrypt()
228 while ((nbytes = walk.nbytes)) { in ecb_encrypt()
233 (const u64 *)walk.src.virt.addr, in ecb_encrypt()
234 (u64 *) walk.dst.virt.addr, in ecb_encrypt()
238 err = blkcipher_walk_done(desc, &walk, nbytes); in ecb_encrypt()
249 struct blkcipher_walk walk; in ecb_decrypt() local
253 blkcipher_walk_init(&walk, dst, src, nbytes); in ecb_decrypt()
254 err = blkcipher_walk_virt(desc, &walk); in ecb_decrypt()
259 while ((nbytes = walk.nbytes)) { in ecb_decrypt()
264 (const u64 *) walk.src.virt.addr, in ecb_decrypt()
265 (u64 *) walk.dst.virt.addr, block_len); in ecb_decrypt()
268 err = blkcipher_walk_done(desc, &walk, nbytes); in ecb_decrypt()
280 struct blkcipher_walk walk; in cbc_encrypt() local
283 blkcipher_walk_init(&walk, dst, src, nbytes); in cbc_encrypt()
284 err = blkcipher_walk_virt(desc, &walk); in cbc_encrypt()
288 while ((nbytes = walk.nbytes)) { in cbc_encrypt()
293 (const u64 *)walk.src.virt.addr, in cbc_encrypt()
294 (u64 *) walk.dst.virt.addr, in cbc_encrypt()
295 block_len, (u64 *) walk.iv); in cbc_encrypt()
298 err = blkcipher_walk_done(desc, &walk, nbytes); in cbc_encrypt()
309 struct blkcipher_walk walk; in cbc_decrypt() local
313 blkcipher_walk_init(&walk, dst, src, nbytes); in cbc_decrypt()
314 err = blkcipher_walk_virt(desc, &walk); in cbc_decrypt()
319 while ((nbytes = walk.nbytes)) { in cbc_decrypt()
324 (const u64 *) walk.src.virt.addr, in cbc_decrypt()
325 (u64 *) walk.dst.virt.addr, in cbc_decrypt()
326 block_len, (u64 *) walk.iv); in cbc_decrypt()
329 err = blkcipher_walk_done(desc, &walk, nbytes); in cbc_decrypt()
337 struct blkcipher_walk *walk) in ctr_crypt_final() argument
339 u8 *ctrblk = walk->iv; in ctr_crypt_final()
341 u8 *src = walk->src.virt.addr; in ctr_crypt_final()
342 u8 *dst = walk->dst.virt.addr; in ctr_crypt_final()
343 unsigned int nbytes = walk->nbytes; in ctr_crypt_final()
357 struct blkcipher_walk walk; in ctr_crypt() local
360 blkcipher_walk_init(&walk, dst, src, nbytes); in ctr_crypt()
361 err = blkcipher_walk_virt_block(desc, &walk, AES_BLOCK_SIZE); in ctr_crypt()
365 while ((nbytes = walk.nbytes) >= AES_BLOCK_SIZE) { in ctr_crypt()
370 (const u64 *)walk.src.virt.addr, in ctr_crypt()
371 (u64 *) walk.dst.virt.addr, in ctr_crypt()
372 block_len, (u64 *) walk.iv); in ctr_crypt()
375 err = blkcipher_walk_done(desc, &walk, nbytes); in ctr_crypt()
377 if (walk.nbytes) { in ctr_crypt()
378 ctr_crypt_final(ctx, &walk); in ctr_crypt()
379 err = blkcipher_walk_done(desc, &walk, 0); in ctr_crypt()