From 1b0adf5ccb4e924874c71a8a73270dfced24854a Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Wed, 19 Sep 2018 03:43:03 +0200 Subject: poly1305: no need to trick gcc 8.1 This reverts 37f114a73ba37219b00a66f0a51219a696599745, since gcc 8.2 no longer exhibits that bug. Suggested-by: Eric Biggers --- src/crypto/zinc/poly1305/poly1305.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/crypto/zinc/poly1305/poly1305.c b/src/crypto/zinc/poly1305/poly1305.c index 38a51ea..cd6cb9b 100644 --- a/src/crypto/zinc/poly1305/poly1305.c +++ b/src/crypto/zinc/poly1305/poly1305.c @@ -83,7 +83,7 @@ static inline void poly1305_emit(void *ctx, u8 mac[POLY1305_KEY_SIZE], void poly1305_update(struct poly1305_ctx *ctx, const u8 *input, size_t len, simd_context_t *simd_context) { - const size_t num = ctx->num % POLY1305_BLOCK_SIZE; + const size_t num = ctx->num; size_t rem; if (num) { @@ -118,7 +118,7 @@ EXPORT_SYMBOL(poly1305_update); void poly1305_final(struct poly1305_ctx *ctx, u8 mac[POLY1305_MAC_SIZE], simd_context_t *simd_context) { - size_t num = ctx->num % POLY1305_BLOCK_SIZE; + size_t num = ctx->num; if (num) { ctx->data[num++] = 1; -- cgit v1.2.3-59-g8ed1b