Skip to content
Prev Previous commit
Next Next commit
Make sure we fire SHUTDOWN_COMPLETE hooks when the AP goes down
This ensures that the hook in common/system.c that triggers an
"at-shutdown" reboot from RO to RW fires.

Without this, `ectool reboot_ec RW at-shutdown` doesn't work.
  • Loading branch information
DHowett committed Jan 23, 2023
commit c187ce17648b4538be37615520d58ab6adfd333a
4 changes: 4 additions & 0 deletions board/hx20/power_sequence.c
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,10 @@ enum power_state power_handle_state(enum power_state state)
gpio_set_level(GPIO_SYSON, 0);
hook_notify(HOOK_CHIPSET_SHUTDOWN);
cypd_set_power_active(POWER_S5);

/* Call hooks after we remove power rails */
hook_notify(HOOK_CHIPSET_SHUTDOWN_COMPLETE);

power_s5_up = 0;
return POWER_S5;
break;
Expand Down