zynqmp_ipi.c 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. /*
  2. * Copyright (c) 2017-2018, Arm Limited and Contributors. All rights reserved.
  3. * Copyright (c) 2017-2022, Xilinx, Inc. All rights reserved.
  4. * Copyright (c) 2022-2023, Advanced Micro Devices, Inc. All rights reserved.
  5. *
  6. * SPDX-License-Identifier: BSD-3-Clause
  7. */
  8. /*
  9. * Zynq UltraScale+ MPSoC IPI agent registers access management
  10. */
  11. #include <lib/utils_def.h>
  12. #include <ipi.h>
  13. #include <plat_ipi.h>
  14. /* Zynqmp ipi configuration table */
  15. static const struct ipi_config zynqmp_ipi_table[] = {
  16. /* APU IPI */
  17. {
  18. .ipi_bit_mask = 0x1,
  19. .ipi_reg_base = 0xFF300000U,
  20. .secure_only = 0,
  21. },
  22. /* RPU0 IPI */
  23. {
  24. .ipi_bit_mask = 0x100,
  25. .ipi_reg_base = 0xFF310000U,
  26. .secure_only = 0,
  27. },
  28. /* RPU1 IPI */
  29. {
  30. .ipi_bit_mask = 0x200,
  31. .ipi_reg_base = 0xFF320000U,
  32. .secure_only = 0,
  33. },
  34. /* PMU0 IPI */
  35. {
  36. .ipi_bit_mask = 0x10000,
  37. .ipi_reg_base = 0xFF330000U,
  38. .secure_only = IPI_SECURE_MASK,
  39. },
  40. /* PMU1 IPI */
  41. {
  42. .ipi_bit_mask = 0x20000,
  43. .ipi_reg_base = 0xFF331000U,
  44. .secure_only = 0,
  45. },
  46. /* PMU2 IPI */
  47. {
  48. .ipi_bit_mask = 0x40000,
  49. .ipi_reg_base = 0xFF332000U,
  50. .secure_only = IPI_SECURE_MASK,
  51. },
  52. /* PMU3 IPI */
  53. {
  54. .ipi_bit_mask = 0x80000,
  55. .ipi_reg_base = 0xFF333000U,
  56. .secure_only = IPI_SECURE_MASK,
  57. },
  58. /* PL0 IPI */
  59. {
  60. .ipi_bit_mask = 0x1000000,
  61. .ipi_reg_base = 0xFF340000U,
  62. .secure_only = 0,
  63. },
  64. /* PL1 IPI */
  65. {
  66. .ipi_bit_mask = 0x2000000,
  67. .ipi_reg_base = 0xFF350000U,
  68. .secure_only = 0,
  69. },
  70. /* PL2 IPI */
  71. {
  72. .ipi_bit_mask = 0x4000000,
  73. .ipi_reg_base = 0xFF360000U,
  74. .secure_only = 0,
  75. },
  76. /* PL3 IPI */
  77. {
  78. .ipi_bit_mask = 0x8000000,
  79. .ipi_reg_base = 0xFF370000U,
  80. .secure_only = 0,
  81. },
  82. };
  83. /**
  84. * zynqmp_ipi_config_table_init() - Initialize ZynqMP IPI configuration data.
  85. *
  86. */
  87. void zynqmp_ipi_config_table_init(void)
  88. {
  89. ipi_config_table_init(zynqmp_ipi_table, ARRAY_SIZE(zynqmp_ipi_table));
  90. }