arch.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. /*
  2. * arch/arm/include/asm/mach/arch.h
  3. *
  4. * Copyright (C) 2000 Russell King
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License version 2 as
  8. * published by the Free Software Foundation.
  9. */
  10. #ifndef __ASSEMBLY__
  11. struct tag;
  12. struct meminfo;
  13. struct sys_timer;
  14. struct machine_desc {
  15. /*
  16. * Note! The first two elements are used
  17. * by assembler code in head.S, head-common.S
  18. */
  19. unsigned int nr; /* architecture number */
  20. const char *name; /* architecture name */
  21. unsigned long boot_params; /* tagged list */
  22. unsigned int nr_irqs; /* number of IRQs */
  23. unsigned int video_start; /* start of video RAM */
  24. unsigned int video_end; /* end of video RAM */
  25. unsigned int reserve_lp0 :1; /* never has lp0 */
  26. unsigned int reserve_lp1 :1; /* never has lp1 */
  27. unsigned int reserve_lp2 :1; /* never has lp2 */
  28. unsigned int soft_reboot :1; /* soft reboot */
  29. void (*fixup)(struct machine_desc *,
  30. struct tag *, char **,
  31. struct meminfo *);
  32. void (*reserve)(void);/* reserve mem blocks */
  33. void (*map_io)(void);/* IO mapping function */
  34. void (*init_irq)(void);
  35. struct sys_timer *timer; /* system tick timer */
  36. void (*init_machine)(void);
  37. };
  38. /*
  39. * Set of macros to define architecture features. This is built into
  40. * a table by the linker.
  41. */
  42. #define MACHINE_START(_type,_name) \
  43. static const struct machine_desc __mach_desc_##_type \
  44. __used \
  45. __attribute__((__section__(".arch.info.init"))) = { \
  46. .nr = MACH_TYPE_##_type, \
  47. .name = _name,
  48. #define MACHINE_END \
  49. };
  50. #endif