idle.c 666 B

123456789101112131415161718192021222324252627282930
  1. /*
  2. * arch/arm/mach-gemini/idle.c
  3. */
  4. #include <linux/init.h>
  5. #include <asm/system.h>
  6. #include <asm/proc-fns.h>
  7. static void gemini_idle(void)
  8. {
  9. /*
  10. * Because of broken hardware we have to enable interrupts or the CPU
  11. * will never wakeup... Acctualy it is not very good to enable
  12. * interrupts first since scheduler can miss a tick, but there is
  13. * no other way around this. Platforms that needs it for power saving
  14. * should call enable_hlt() in init code, since by default it is
  15. * disabled.
  16. */
  17. local_irq_enable();
  18. cpu_do_idle();
  19. }
  20. static int __init gemini_idle_init(void)
  21. {
  22. arm_pm_idle = gemini_idle;
  23. return 0;
  24. }
  25. arch_initcall(gemini_idle_init);