system.c 389 B

12345678910111213141516171819202122
  1. // SPDX-License-Identifier: GPL-2.0-only
  2. /*
  3. * Copyright 2011 Calxeda, Inc.
  4. */
  5. #include <linux/io.h>
  6. #include <asm/proc-fns.h>
  7. #include <linux/reboot.h>
  8. #include "core.h"
  9. #include "sysregs.h"
  10. void highbank_restart(enum reboot_mode mode, const char *cmd)
  11. {
  12. if (mode == REBOOT_HARD)
  13. highbank_set_pwr_hard_reset();
  14. else
  15. highbank_set_pwr_soft_reset();
  16. while (1)
  17. cpu_do_idle();
  18. }