Blame view

include/crypto/ablk_helper.h 773 Bytes
81f7e3824   Eric Lee   Initial Release, ...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
  /* SPDX-License-Identifier: GPL-2.0 */
  /*
   * Shared async block cipher helpers
   */
  
  #ifndef _CRYPTO_ABLK_HELPER_H
  #define _CRYPTO_ABLK_HELPER_H
  
  #include <linux/crypto.h>
  #include <linux/kernel.h>
  #include <crypto/cryptd.h>
  
  struct async_helper_ctx {
  	struct cryptd_ablkcipher *cryptd_tfm;
  };
  
  extern int ablk_set_key(struct crypto_ablkcipher *tfm, const u8 *key,
  			unsigned int key_len);
  
  extern int __ablk_encrypt(struct ablkcipher_request *req);
  
  extern int ablk_encrypt(struct ablkcipher_request *req);
  
  extern int ablk_decrypt(struct ablkcipher_request *req);
  
  extern void ablk_exit(struct crypto_tfm *tfm);
  
  extern int ablk_init_common(struct crypto_tfm *tfm, const char *drv_name);
  
  extern int ablk_init(struct crypto_tfm *tfm);
  
  #endif /* _CRYPTO_ABLK_HELPER_H */