Lines Matching refs:walk
43 struct blkcipher_walk *walk, in crypto_cbc_encrypt_segment() argument
49 unsigned int nbytes = walk->nbytes; in crypto_cbc_encrypt_segment()
50 u8 *src = walk->src.virt.addr; in crypto_cbc_encrypt_segment()
51 u8 *dst = walk->dst.virt.addr; in crypto_cbc_encrypt_segment()
52 u8 *iv = walk->iv; in crypto_cbc_encrypt_segment()
67 struct blkcipher_walk *walk, in crypto_cbc_encrypt_inplace() argument
73 unsigned int nbytes = walk->nbytes; in crypto_cbc_encrypt_inplace()
74 u8 *src = walk->src.virt.addr; in crypto_cbc_encrypt_inplace()
75 u8 *iv = walk->iv; in crypto_cbc_encrypt_inplace()
85 memcpy(walk->iv, iv, bsize); in crypto_cbc_encrypt_inplace()
94 struct blkcipher_walk walk; in crypto_cbc_encrypt() local
100 blkcipher_walk_init(&walk, dst, src, nbytes); in crypto_cbc_encrypt()
101 err = blkcipher_walk_virt(desc, &walk); in crypto_cbc_encrypt()
103 while ((nbytes = walk.nbytes)) { in crypto_cbc_encrypt()
104 if (walk.src.virt.addr == walk.dst.virt.addr) in crypto_cbc_encrypt()
105 nbytes = crypto_cbc_encrypt_inplace(desc, &walk, child); in crypto_cbc_encrypt()
107 nbytes = crypto_cbc_encrypt_segment(desc, &walk, child); in crypto_cbc_encrypt()
108 err = blkcipher_walk_done(desc, &walk, nbytes); in crypto_cbc_encrypt()
115 struct blkcipher_walk *walk, in crypto_cbc_decrypt_segment() argument
121 unsigned int nbytes = walk->nbytes; in crypto_cbc_decrypt_segment()
122 u8 *src = walk->src.virt.addr; in crypto_cbc_decrypt_segment()
123 u8 *dst = walk->dst.virt.addr; in crypto_cbc_decrypt_segment()
124 u8 *iv = walk->iv; in crypto_cbc_decrypt_segment()
135 memcpy(walk->iv, iv, bsize); in crypto_cbc_decrypt_segment()
141 struct blkcipher_walk *walk, in crypto_cbc_decrypt_inplace() argument
147 unsigned int nbytes = walk->nbytes; in crypto_cbc_decrypt_inplace()
148 u8 *src = walk->src.virt.addr; in crypto_cbc_decrypt_inplace()
163 crypto_xor(src, walk->iv, bsize); in crypto_cbc_decrypt_inplace()
164 memcpy(walk->iv, last_iv, bsize); in crypto_cbc_decrypt_inplace()
173 struct blkcipher_walk walk; in crypto_cbc_decrypt() local
179 blkcipher_walk_init(&walk, dst, src, nbytes); in crypto_cbc_decrypt()
180 err = blkcipher_walk_virt(desc, &walk); in crypto_cbc_decrypt()
182 while ((nbytes = walk.nbytes)) { in crypto_cbc_decrypt()
183 if (walk.src.virt.addr == walk.dst.virt.addr) in crypto_cbc_decrypt()
184 nbytes = crypto_cbc_decrypt_inplace(desc, &walk, child); in crypto_cbc_decrypt()
186 nbytes = crypto_cbc_decrypt_segment(desc, &walk, child); in crypto_cbc_decrypt()
187 err = blkcipher_walk_done(desc, &walk, nbytes); in crypto_cbc_decrypt()