Lines Matching refs:req
85 int (*encrypt)(struct akcipher_request *req);
86 int (*decrypt)(struct akcipher_request *req);
150 static inline void akcipher_request_set_tfm(struct akcipher_request *req, in akcipher_request_set_tfm() argument
153 req->base.tfm = crypto_akcipher_tfm(tfm); in akcipher_request_set_tfm()
157 struct akcipher_request *req) in crypto_akcipher_reqtfm() argument
159 return __crypto_akcipher_tfm(req->base.tfm); in crypto_akcipher_reqtfm()
185 struct akcipher_request *req; in akcipher_request_alloc() local
187 req = kmalloc(sizeof(*req) + crypto_akcipher_reqsize(tfm), gfp); in akcipher_request_alloc()
188 if (likely(req)) in akcipher_request_alloc()
189 akcipher_request_set_tfm(req, tfm); in akcipher_request_alloc()
191 return req; in akcipher_request_alloc()
199 static inline void akcipher_request_free(struct akcipher_request *req) in akcipher_request_free() argument
201 kfree_sensitive(req); in akcipher_request_free()
215 static inline void akcipher_request_set_callback(struct akcipher_request *req, in akcipher_request_set_callback() argument
220 req->base.complete = cmpl; in akcipher_request_set_callback()
221 req->base.data = data; in akcipher_request_set_callback()
222 req->base.flags = flgs; in akcipher_request_set_callback()
236 static inline void akcipher_request_set_crypt(struct akcipher_request *req, in akcipher_request_set_crypt() argument
242 req->src = src; in akcipher_request_set_crypt()
243 req->dst = dst; in akcipher_request_set_crypt()
244 req->src_len = src_len; in akcipher_request_set_crypt()
245 req->dst_len = dst_len; in akcipher_request_set_crypt()
275 static inline int crypto_akcipher_encrypt(struct akcipher_request *req) in crypto_akcipher_encrypt() argument
277 struct crypto_akcipher *tfm = crypto_akcipher_reqtfm(req); in crypto_akcipher_encrypt()
279 return crypto_akcipher_alg(tfm)->encrypt(req); in crypto_akcipher_encrypt()
292 static inline int crypto_akcipher_decrypt(struct akcipher_request *req) in crypto_akcipher_decrypt() argument
294 struct crypto_akcipher *tfm = crypto_akcipher_reqtfm(req); in crypto_akcipher_decrypt()
296 return crypto_akcipher_alg(tfm)->decrypt(req); in crypto_akcipher_decrypt()