global_data.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. /*
  2. * (C) Copyright 2002-2010
  3. * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
  4. *
  5. * SPDX-License-Identifier: GPL-2.0+
  6. */
  7. #ifndef __ASM_GBL_DATA_H
  8. #define __ASM_GBL_DATA_H
  9. #ifdef CONFIG_OMAP
  10. #include <asm/omap_boot.h>
  11. #endif
  12. /* Architecture-specific global data */
  13. struct arch_global_data {
  14. #if defined(CONFIG_FSL_ESDHC)
  15. u32 sdhc_clk;
  16. #endif
  17. #ifdef CONFIG_AT91FAMILY
  18. /* "static data" needed by at91's clock.c */
  19. unsigned long cpu_clk_rate_hz;
  20. unsigned long main_clk_rate_hz;
  21. unsigned long mck_rate_hz;
  22. unsigned long plla_rate_hz;
  23. unsigned long pllb_rate_hz;
  24. unsigned long at91_pllb_usb_init;
  25. #endif
  26. /* "static data" needed by most of timer.c on ARM platforms */
  27. unsigned long timer_rate_hz;
  28. unsigned long tbu;
  29. unsigned long tbl;
  30. unsigned long lastinc;
  31. unsigned long long timer_reset_value;
  32. #if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
  33. unsigned long tlb_addr;
  34. unsigned long tlb_size;
  35. #endif
  36. #ifdef CONFIG_OMAP
  37. struct omap_boot_parameters omap_boot_params;
  38. #endif
  39. };
  40. #include <asm-generic/global_data.h>
  41. #ifdef CONFIG_ARM64
  42. #define DECLARE_GLOBAL_DATA_PTR register volatile gd_t *gd asm ("x18")
  43. #else
  44. #define DECLARE_GLOBAL_DATA_PTR register volatile gd_t *gd asm ("r9")
  45. #endif
  46. #endif /* __ASM_GBL_DATA_H */