|
@@ -168,9 +168,11 @@ static void mv_cesa_ahash_std_step(struct ahash_request *req)
|
|
|
mv_cesa_adjust_op(engine, &creq->op_tmpl);
|
|
|
memcpy_toio(engine->sram, &creq->op_tmpl, sizeof(creq->op_tmpl));
|
|
|
|
|
|
- digsize = crypto_ahash_digestsize(crypto_ahash_reqtfm(req));
|
|
|
- for (i = 0; i < digsize / 4; i++)
|
|
|
- writel_relaxed(creq->state[i], engine->regs + CESA_IVDIG(i));
|
|
|
+ if (!sreq->offset) {
|
|
|
+ digsize = crypto_ahash_digestsize(crypto_ahash_reqtfm(req));
|
|
|
+ for (i = 0; i < digsize / 4; i++)
|
|
|
+ writel_relaxed(creq->state[i], engine->regs + CESA_IVDIG(i));
|
|
|
+ }
|
|
|
|
|
|
if (creq->cache_ptr)
|
|
|
memcpy_toio(engine->sram + CESA_SA_DATA_SRAM_OFFSET,
|