Index: sys/crypto/aesni/aesni.h =================================================================== --- sys/crypto/aesni/aesni.h +++ sys/crypto/aesni/aesni.h @@ -63,7 +63,7 @@ int mlen; int hash_len; void (*hash_init)(void *); - void (*hash_update)(void *, const void *, unsigned); + int (*hash_update)(void *, const void *, unsigned); void (*hash_finalize)(void *, void *); bool hmac; }; Index: sys/crypto/aesni/aesni.c =================================================================== --- sys/crypto/aesni/aesni.c +++ sys/crypto/aesni/aesni.c @@ -386,7 +386,7 @@ MODULE_VERSION(aesni, 1); MODULE_DEPEND(aesni, crypto, 1, 1, 1); -static void +static int intel_sha1_update(void *vctx, const void *vdata, u_int datalen) { struct sha1_ctxt *ctx = vctx; @@ -419,6 +419,8 @@ intel_sha1_step(ctx->h.b32, (void *)ctx->m.b8, 1); off += copysiz; } + + return (0); } static void @@ -433,7 +435,7 @@ sha1_result(ctx, digest); } -static void +static int intel_sha256_update(void *vctx, const void *vdata, u_int len) { SHA256_CTX *ctx = vctx; @@ -454,7 +456,7 @@ /* Handle the case where we don't need to perform any transforms */ if (len < 64 - r) { memcpy(&ctx->buf[r], src, len); - return; + return (0); } /* Finish the current block */ @@ -473,6 +475,8 @@ /* Copy left over data into buffer */ memcpy(ctx->buf, src, len); + + return (0); } static void