rsa_caam.h 791 B

123456789101112131415161718192021222324252627
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Copyright 2014 Freescale Semiconductor, Inc.
  4. */
  5. #ifndef __RSA_CAAM_H
  6. #define __RSA_CAAM_H
  7. #include <common.h>
  8. /**
  9. * struct pk_in_params - holder for input to PKHA block in CAAM
  10. * These parameters are required to perform Modular Exponentiation
  11. * using PKHA Block in CAAM
  12. */
  13. struct pk_in_params {
  14. const uint8_t *e; /* public exponent as byte array */
  15. uint32_t e_siz; /* size of e[] in number of bytes */
  16. const uint8_t *n; /* modulus as byte array */
  17. uint32_t n_siz; /* size of n[] in number of bytes */
  18. const uint8_t *a; /* Signature as byte array */
  19. uint32_t a_siz; /* size of a[] in number of bytes */
  20. uint8_t *b; /* Result exp. modulus in number of bytes */
  21. uint32_t b_siz; /* size of b[] in number of bytes */
  22. };
  23. #endif