Skip to content

Commit

Permalink
[ot] hw/opentitan: set reset value for hmac's cfg register
Browse files Browse the repository at this point in the history
  • Loading branch information
jwnrt committed Dec 5, 2024
1 parent cc81106 commit b35d216
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions hw/opentitan/ot_hmac.c
Original file line number Diff line number Diff line change
Expand Up @@ -762,12 +762,15 @@ static void ot_hmac_realize(DeviceState *dev, Error **errp)
static void ot_hmac_reset(DeviceState *dev)
{
OtHMACState *s = OT_HMAC(dev);
OtHMACRegisters *r = s->regs;

ibex_irq_set(&s->clkmgr, false);

memset(s->ctx, 0, sizeof(*(s->ctx)));
memset(s->regs, 0, sizeof(*(s->regs)));

r->cfg = 0x4100;

ot_hmac_update_irqs(s);
ot_hmac_update_alert(s);

Expand Down

0 comments on commit b35d216

Please sign in to comment.