Skip to content

Commit

Permalink
[hw,pwrmgr,rtl] Make the slow SoC see what the slow FSM sees
Browse files Browse the repository at this point in the history
... to generate the light reset request.

Signed-off-by: Robert Schilling <[email protected]>
  • Loading branch information
Razer6 authored and rswarbrick committed Jan 18, 2025
1 parent 4ba44a9 commit de9efe7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 20 deletions.
12 changes: 2 additions & 10 deletions hw/ip_templates/pwrmgr/rtl/pwrmgr.sv.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -531,20 +531,12 @@ module pwrmgr
{NumIntRstReqs{1'b1}},
slow_reset_en};
% if wait_for_external_reset:
// TODO(#22711): Make this work also when `rstreqs` is structured differently.
logic strap_sampled;
logic internal_reset_req;
logic ext_reset_req;
assign internal_reset_req =|(
slow_peri_reqs.rstreqs &
{{NumSwRstReq{1'b1}}, // SW driven reset
{NumDebugRstReqs{1'b1}}, // debugger reset
{NumIntRstReqs{1'b1}}, // {ESC reset, slow_fsm}
// exclude the external async reset
{1'b0, slow_reset_en[0]}
}
);
// Make the SoC see what the slow FSM sees to to generate the light_reset to the SoC
assign internal_reset_req = |slow_peri_reqs_masked.rstreqs;
// The MSB of `slow_peri_reqs.rstreqs` is the external reset request. We want it to always
// propagate, in order to continue from the Reset Wait state in the fast FSM.
Expand Down
12 changes: 2 additions & 10 deletions hw/top_darjeeling/ip_autogen/pwrmgr/rtl/pwrmgr.sv
Original file line number Diff line number Diff line change
Expand Up @@ -528,20 +528,12 @@ module pwrmgr
{NumDebugRstReqs{1'b1}},
{NumIntRstReqs{1'b1}},
slow_reset_en};
// TODO(#22711): Make this work also when `rstreqs` is structured differently.
logic strap_sampled;
logic internal_reset_req;
logic ext_reset_req;

assign internal_reset_req =|(
slow_peri_reqs.rstreqs &
{{NumSwRstReq{1'b1}}, // SW driven reset
{NumDebugRstReqs{1'b1}}, // debugger reset
{NumIntRstReqs{1'b1}}, // {ESC reset, slow_fsm}
// exclude the external async reset
{1'b0, slow_reset_en[0]}
}
);
// Make the SoC see what the slow FSM sees to to generate the light_reset to the SoC
assign internal_reset_req = |slow_peri_reqs_masked.rstreqs;

// The MSB of `slow_peri_reqs.rstreqs` is the external reset request. We want it to always
// propagate, in order to continue from the Reset Wait state in the fast FSM.
Expand Down

0 comments on commit de9efe7

Please sign in to comment.