platform.h 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. /*
  2. * Platform specific functions
  3. *
  4. * This file is subject to the terms and conditions of the GNU General
  5. * Public License. See the file "COPYING" in the main directory of
  6. * this archive for more details.
  7. *
  8. * Copyright (C) 2001 - 2005 Tensilica Inc.
  9. */
  10. #ifndef _XTENSA_PLATFORM_H
  11. #define _XTENSA_PLATFORM_H
  12. #include <linux/types.h>
  13. #include <linux/pci.h>
  14. #include <asm/bootparam.h>
  15. /*
  16. * platform_init is called before the mmu is initialized to give the
  17. * platform a early hook-up. bp_tag_t is a list of configuration tags
  18. * passed from the boot-loader.
  19. */
  20. extern void platform_init(bp_tag_t*);
  21. /*
  22. * platform_setup is called from setup_arch with a pointer to the command-line
  23. * string.
  24. */
  25. extern void platform_setup (char **);
  26. /*
  27. * platform_restart is called to restart the system.
  28. */
  29. extern void platform_restart (void);
  30. /*
  31. * platform_halt is called to stop the system and halt.
  32. */
  33. extern void platform_halt (void);
  34. /*
  35. * platform_power_off is called to stop the system and power it off.
  36. */
  37. extern void platform_power_off (void);
  38. /*
  39. * platform_idle is called from the idle function.
  40. */
  41. extern void platform_idle (void);
  42. /*
  43. * platform_heartbeat is called every HZ
  44. */
  45. extern void platform_heartbeat (void);
  46. /*
  47. * platform_pcibios_init is called to allow the platform to setup the pci bus.
  48. */
  49. extern void platform_pcibios_init (void);
  50. /*
  51. * platform_pcibios_fixup allows to modify the PCI configuration.
  52. */
  53. extern int platform_pcibios_fixup (void);
  54. /*
  55. * platform_calibrate_ccount calibrates cpu clock freq (CONFIG_XTENSA_CALIBRATE)
  56. */
  57. extern void platform_calibrate_ccount (void);
  58. /*
  59. * Flush and reset the mmu, simulate a processor reset, and
  60. * jump to the reset vector.
  61. */
  62. void cpu_reset(void) __attribute__((noreturn));
  63. #endif /* _XTENSA_PLATFORM_H */