summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRaymond Mao <[email protected]>2024-10-03 14:50:18 -0700
committerTom Rini <[email protected]>2024-10-14 17:58:30 -0600
commit988e749d9770bad0a8d8fbf45bfa8af3ca88da38 (patch)
tree0944f9741626c7bdef0a7d46fcb4b380760846ce /include
parent2b6f572958f3e4ab0f5b9dde64dce6ddd477fdab (diff)
sha1: Remove sha1 non-watchdog API
We don't need an API specially for non-watchdog since sha1_csum_wd supports it by disabling CONFIG_HW_WATCHDOG and CONFIG_WATCHDOG. Set 0x10000 as default chunk size for SHA1. Signed-off-by: Raymond Mao <[email protected]> Reviewed-by: Ilias Apalodimas <[email protected]>
Diffstat (limited to 'include')
-rw-r--r--include/u-boot/sha1.h12
1 files changed, 2 insertions, 10 deletions
diff --git a/include/u-boot/sha1.h b/include/u-boot/sha1.h
index ab88134fb98..36c3db15e22 100644
--- a/include/u-boot/sha1.h
+++ b/include/u-boot/sha1.h
@@ -39,6 +39,8 @@ extern "C" {
#define SHA1_SUM_LEN 20
#define SHA1_DER_LEN 15
+#define SHA1_DEF_CHUNK_SZ 0x10000
+
extern const uint8_t sha1_der_prefix[];
#if defined(CONFIG_MBEDTLS_LIB_CRYPTO)
@@ -82,16 +84,6 @@ void sha1_update(sha1_context *ctx, const unsigned char *input,
void sha1_finish( sha1_context *ctx, unsigned char output[20] );
/**
- * \brief Output = SHA-1( input buffer )
- *
- * \param input buffer holding the data
- * \param ilen length of the input data
- * \param output SHA-1 checksum result
- */
-void sha1_csum(const unsigned char *input, unsigned int ilen,
- unsigned char *output);
-
-/**
* \brief Output = SHA-1( input buffer ), with watchdog triggering
*
* \param input buffer holding the data