global_data.h 945 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * (C) Copyright 2002
  4. * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
  5. *
  6. * Copyright (c) 2017 Microsemi Corporation.
  7. * Padmarao Begari, Microsemi Corporation <padmarao.begari@microsemi.com>
  8. */
  9. #ifndef __ASM_GBL_DATA_H
  10. #define __ASM_GBL_DATA_H
  11. #include <asm/smp.h>
  12. /* Architecture-specific global data */
  13. struct arch_global_data {
  14. long boot_hart; /* boot hart id */
  15. #ifdef CONFIG_SIFIVE_CLINT
  16. void __iomem *clint; /* clint base address */
  17. #endif
  18. #if (defined CONFIG_ANDES_PLIC) || (defined CONFIG_THEAD_PLIC)
  19. void __iomem *plic; /* plic base address */
  20. #endif
  21. #ifdef CONFIG_ANDES_PLMT
  22. void __iomem *plmt; /* plmt base address */
  23. #endif
  24. #ifdef CONFIG_SMP
  25. struct ipi_data ipi[CONFIG_NR_CPUS];
  26. #endif
  27. #ifndef CONFIG_XIP
  28. ulong available_harts;
  29. #endif
  30. };
  31. #include <asm-generic/global_data.h>
  32. #define DECLARE_GLOBAL_DATA_PTR register gd_t *gd asm ("gp")
  33. #endif /* __ASM_GBL_DATA_H */