diff --git a/hw/application_fpga/fw/tk1/main.c b/hw/application_fpga/fw/tk1/main.c index efee02f..ac7a658 100644 --- a/hw/application_fpga/fw/tk1/main.c +++ b/hw/application_fpga/fw/tk1/main.c @@ -294,7 +294,6 @@ static enum state loading_commands(const struct frame_header *hdr, ctx->left -= nbytes; if (ctx->left == 0) { - blake2s_ctx b2s_ctx = {0}; int blake2err = 0; debug_puts("Fully loaded "); @@ -303,9 +302,7 @@ static enum state loading_commands(const struct frame_header *hdr, // Compute Blake2S digest of the app, // storing it for FW_STATE_RUN - blake2err = blake2s(&ctx->digest, 32, NULL, 0, - (const void *)TK1_RAM_BASE, - *app_size, &b2s_ctx); + blake2err = compute_app_digest(ctx->digest); assert(blake2err == 0); print_digest(ctx->digest);