Lines Matching refs:desc
80 static int ecb_crypt(struct blkcipher_desc *desc, struct blkcipher_walk *walk, in ecb_crypt() argument
84 struct bf_ctx *ctx = crypto_blkcipher_ctx(desc->tfm); in ecb_crypt()
89 err = blkcipher_walk_virt(desc, walk); in ecb_crypt()
119 err = blkcipher_walk_done(desc, walk, nbytes); in ecb_crypt()
125 static int ecb_encrypt(struct blkcipher_desc *desc, struct scatterlist *dst, in ecb_encrypt() argument
131 return ecb_crypt(desc, &walk, blowfish_enc_blk, blowfish_enc_blk_4way); in ecb_encrypt()
134 static int ecb_decrypt(struct blkcipher_desc *desc, struct scatterlist *dst, in ecb_decrypt() argument
140 return ecb_crypt(desc, &walk, blowfish_dec_blk, blowfish_dec_blk_4way); in ecb_decrypt()
143 static unsigned int __cbc_encrypt(struct blkcipher_desc *desc, in __cbc_encrypt() argument
146 struct bf_ctx *ctx = crypto_blkcipher_ctx(desc->tfm); in __cbc_encrypt()
167 static int cbc_encrypt(struct blkcipher_desc *desc, struct scatterlist *dst, in cbc_encrypt() argument
174 err = blkcipher_walk_virt(desc, &walk); in cbc_encrypt()
177 nbytes = __cbc_encrypt(desc, &walk); in cbc_encrypt()
178 err = blkcipher_walk_done(desc, &walk, nbytes); in cbc_encrypt()
184 static unsigned int __cbc_decrypt(struct blkcipher_desc *desc, in __cbc_decrypt() argument
187 struct bf_ctx *ctx = crypto_blkcipher_ctx(desc->tfm); in __cbc_decrypt()
248 static int cbc_decrypt(struct blkcipher_desc *desc, struct scatterlist *dst, in cbc_decrypt() argument
255 err = blkcipher_walk_virt(desc, &walk); in cbc_decrypt()
258 nbytes = __cbc_decrypt(desc, &walk); in cbc_decrypt()
259 err = blkcipher_walk_done(desc, &walk, nbytes); in cbc_decrypt()
280 static unsigned int __ctr_crypt(struct blkcipher_desc *desc, in __ctr_crypt() argument
283 struct bf_ctx *ctx = crypto_blkcipher_ctx(desc->tfm); in __ctr_crypt()
336 static int ctr_crypt(struct blkcipher_desc *desc, struct scatterlist *dst, in ctr_crypt() argument
343 err = blkcipher_walk_virt_block(desc, &walk, BF_BLOCK_SIZE); in ctr_crypt()
346 nbytes = __ctr_crypt(desc, &walk); in ctr_crypt()
347 err = blkcipher_walk_done(desc, &walk, nbytes); in ctr_crypt()
351 ctr_crypt_final(crypto_blkcipher_ctx(desc->tfm), &walk); in ctr_crypt()
352 err = blkcipher_walk_done(desc, &walk, 0); in ctr_crypt()