Lines Matching refs:req
56 static int skcipher_crypt_blkcipher(struct skcipher_request *req, in skcipher_crypt_blkcipher() argument
62 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(req); in skcipher_crypt_blkcipher()
66 .info = req->iv, in skcipher_crypt_blkcipher()
67 .flags = req->base.flags, in skcipher_crypt_blkcipher()
71 return crypt(&desc, req->dst, req->src, req->cryptlen); in skcipher_crypt_blkcipher()
74 static int skcipher_encrypt_blkcipher(struct skcipher_request *req) in skcipher_encrypt_blkcipher() argument
76 struct crypto_skcipher *skcipher = crypto_skcipher_reqtfm(req); in skcipher_encrypt_blkcipher()
80 return skcipher_crypt_blkcipher(req, alg->encrypt); in skcipher_encrypt_blkcipher()
83 static int skcipher_decrypt_blkcipher(struct skcipher_request *req) in skcipher_decrypt_blkcipher() argument
85 struct crypto_skcipher *skcipher = crypto_skcipher_reqtfm(req); in skcipher_decrypt_blkcipher()
89 return skcipher_crypt_blkcipher(req, alg->decrypt); in skcipher_decrypt_blkcipher()
150 static int skcipher_crypt_ablkcipher(struct skcipher_request *req, in skcipher_crypt_ablkcipher() argument
153 struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(req); in skcipher_crypt_ablkcipher()
155 struct ablkcipher_request *subreq = skcipher_request_ctx(req); in skcipher_crypt_ablkcipher()
158 ablkcipher_request_set_callback(subreq, skcipher_request_flags(req), in skcipher_crypt_ablkcipher()
159 req->base.complete, req->base.data); in skcipher_crypt_ablkcipher()
160 ablkcipher_request_set_crypt(subreq, req->src, req->dst, req->cryptlen, in skcipher_crypt_ablkcipher()
161 req->iv); in skcipher_crypt_ablkcipher()
166 static int skcipher_encrypt_ablkcipher(struct skcipher_request *req) in skcipher_encrypt_ablkcipher() argument
168 struct crypto_skcipher *skcipher = crypto_skcipher_reqtfm(req); in skcipher_encrypt_ablkcipher()
172 return skcipher_crypt_ablkcipher(req, alg->encrypt); in skcipher_encrypt_ablkcipher()
175 static int skcipher_decrypt_ablkcipher(struct skcipher_request *req) in skcipher_decrypt_ablkcipher() argument
177 struct crypto_skcipher *skcipher = crypto_skcipher_reqtfm(req); in skcipher_decrypt_ablkcipher()
181 return skcipher_crypt_ablkcipher(req, alg->decrypt); in skcipher_decrypt_ablkcipher()