drv_crypto.h 749 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /*
  2. * Copyright (c) 2006-2018, Synwit Technology Co.,Ltd.
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2020-07-10 lik first version
  9. */
  10. #ifndef __DRV_CRYPTO_H__
  11. #define __DRV_CRYPTO_H__
  12. #include "board.h"
  13. /* swm config class */
  14. struct swm_crc_cfg
  15. {
  16. CRC_TypeDef *CRCx;
  17. uint32_t inival;
  18. uint8_t crc_inbits;
  19. uint8_t crc_1632;
  20. uint8_t crc_out_not;
  21. uint8_t crc_out_rev;
  22. };
  23. #ifdef BSP_USING_CRC
  24. #define DEFAULT_CRC (CRC)
  25. #define DEFAULT_INIVAL (0x00000000)
  26. #define DEFAULT_INBITS (2)
  27. #define DEFAULT_CRC1632 (0)
  28. #define DEFAULT_OUT_NOT (0)
  29. #define DEFAULT_OUT_REV (0)
  30. #endif /* BSP_USING_CRC */
  31. int rt_hw_crypto_init(void);
  32. #endif /* __DRV_CRYPTO_H__ */