Home
last modified time | relevance | path

Searched refs:BLAKE2S_BLOCK_SIZE (Results 1 – 7 of 7) sorted by relevance

/openbmc/linux/lib/crypto/
H A Dblake2s.c26 const size_t fill = BLAKE2S_BLOCK_SIZE - state->buflen; in blake2s_update()
32 blake2s_compress(state, state->buf, 1, BLAKE2S_BLOCK_SIZE); in blake2s_update()
37 if (inlen > BLAKE2S_BLOCK_SIZE) { in blake2s_update()
38 const size_t nblocks = DIV_ROUND_UP(inlen, BLAKE2S_BLOCK_SIZE); in blake2s_update()
39 blake2s_compress(state, in, nblocks - 1, BLAKE2S_BLOCK_SIZE); in blake2s_update()
40 in += BLAKE2S_BLOCK_SIZE * (nblocks - 1); in blake2s_update()
41 inlen -= BLAKE2S_BLOCK_SIZE * (nblocks - 1); in blake2s_update()
53 BLAKE2S_BLOCK_SIZE - state->buflen); /* Padding */ in blake2s_final()
H A Dblake2s-selftest.c603 u8 blocks[BLAKE2S_BLOCK_SIZE * 2 + TEST_ALIGNMENT - 1] in blake2s_random_test()
605 u8 *unaligned_block = blocks + BLAKE2S_BLOCK_SIZE; in blake2s_random_test()
615 blake2s_compress(&state1, blocks, 2, BLAKE2S_BLOCK_SIZE); in blake2s_random_test()
616 blake2s_compress_generic(&state2, blocks, 2, BLAKE2S_BLOCK_SIZE); in blake2s_random_test()
625 blake2s_compress(&state1, blocks, 1, BLAKE2S_BLOCK_SIZE); in blake2s_random_test()
628 BLAKE2S_BLOCK_SIZE); in blake2s_random_test()
631 BLAKE2S_BLOCK_SIZE); in blake2s_random_test()
H A Dblake2s-generic.c51 (nblocks > 1 && inc != BLAKE2S_BLOCK_SIZE)); in blake2s_compress_generic()
55 memcpy(m, block, BLAKE2S_BLOCK_SIZE); in blake2s_compress_generic()
105 block += BLAKE2S_BLOCK_SIZE; in blake2s_compress_generic()
/openbmc/linux/include/crypto/
H A Dblake2s.h15 BLAKE2S_BLOCK_SIZE = 64, enumerator
30 u8 buf[BLAKE2S_BLOCK_SIZE];
65 memset(&state->buf[keylen], 0, BLAKE2S_BLOCK_SIZE - keylen); in __blake2s_init()
66 state->buflen = BLAKE2S_BLOCK_SIZE; in __blake2s_init()
/openbmc/linux/arch/x86/crypto/
H A Dblake2s-glue.c32 BUILD_BUG_ON(SZ_4K / BLAKE2S_BLOCK_SIZE < 8); in blake2s_compress()
41 SZ_4K / BLAKE2S_BLOCK_SIZE); in blake2s_compress()
52 block += blocks * BLAKE2S_BLOCK_SIZE; in blake2s_compress()
/openbmc/linux/drivers/net/wireguard/
H A Dnoise.c308 u8 x_key[BLAKE2S_BLOCK_SIZE] __aligned(__alignof__(u32)) = { 0 }; in hmac()
312 if (keylen > BLAKE2S_BLOCK_SIZE) { in hmac()
319 for (i = 0; i < BLAKE2S_BLOCK_SIZE; ++i) in hmac()
323 blake2s_update(&state, x_key, BLAKE2S_BLOCK_SIZE); in hmac()
327 for (i = 0; i < BLAKE2S_BLOCK_SIZE; ++i) in hmac()
331 blake2s_update(&state, x_key, BLAKE2S_BLOCK_SIZE); in hmac()
336 memzero_explicit(x_key, BLAKE2S_BLOCK_SIZE); in hmac()
/openbmc/linux/drivers/char/
H A Drandom.c843 unsigned long entropy[BLAKE2S_BLOCK_SIZE / sizeof(long)]; in random_init_early()
847 static const u8 compiletime_seed[BLAKE2S_BLOCK_SIZE] __initconst __latent_entropy; in random_init_early()
1402 u8 block[BLAKE2S_BLOCK_SIZE]; in write_pool_user()