• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2019, STMicroelectronics - All Rights Reserved
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  */
6 
7 #ifndef STM32_HASH_H
8 #define STM32_HASH_H
9 
10 enum stm32_hash_algo_mode {
11 	HASH_MD5SUM,
12 	HASH_SHA1,
13 	HASH_SHA224,
14 	HASH_SHA256
15 };
16 
17 int stm32_hash_update(const uint8_t *buffer, size_t length);
18 int stm32_hash_final(uint8_t *digest);
19 int stm32_hash_final_update(const uint8_t *buffer, uint32_t buf_length,
20 			    uint8_t *digest);
21 void stm32_hash_init(enum stm32_hash_algo_mode mode);
22 int stm32_hash_register(void);
23 
24 #endif /* STM32_HASH_H */
25