blob: c88b4dc66e1f5a0fbdaa42ee7b548dd26ac1a1d6 [file] [log] [blame]
Loic Poulain9bd02692022-06-01 20:26:29 +02001// SPDX-License-Identifier: GPL-2.0-only
2/*
3 * sha1_ce_glue.c - SHA-1 secure hash using ARMv8 Crypto Extensions
4 *
5 * Copyright (C) 2022 Linaro Ltd <loic.poulain@linaro.org>
6 */
7
Loic Poulain9bd02692022-06-01 20:26:29 +02008#include <u-boot/sha1.h>
9
10extern void sha1_armv8_ce_process(uint32_t state[5], uint8_t const *src,
11 uint32_t blocks);
12
13void sha1_process(sha1_context *ctx, const unsigned char *data,
14 unsigned int blocks)
15{
16 if (!blocks)
17 return;
18
19 sha1_armv8_ce_process(ctx->state, data, blocks);
20}