plat_ehf.c 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /*
  2. * Copyright (c) 2017-2023, ARM Limited and Contributors. All rights reserved.
  3. * Copyright (c) 2020, Broadcom
  4. * SPDX-License-Identifier: BSD-3-Clause
  5. */
  6. #include <bl31/ehf.h>
  7. #include <platform_def.h>
  8. /*
  9. * Enumeration of priority levels on ARM platforms.
  10. */
  11. ehf_pri_desc_t plat_exceptions[] = {
  12. #if ENABLE_FEAT_RAS && FFH_SUPPORT
  13. /* RAS Priority */
  14. EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_RAS_PRI),
  15. #endif
  16. #if SDEI_SUPPORT
  17. /* Critical priority SDEI */
  18. EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SDEI_CRITICAL_PRI),
  19. /* Normal priority SDEI */
  20. EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SDEI_NORMAL_PRI),
  21. #endif
  22. #if SPM_MM || (SPMC_AT_EL3 && SPMC_AT_EL3_SEL0_SP)
  23. #if ENABLE_FEAT_RAS && FFH_SUPPORT
  24. #if (PLAT_SP_PRI != PLAT_RAS_PRI)
  25. EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SP_PRI),
  26. #endif
  27. #else
  28. EHF_PRI_DESC(PLAT_PRI_BITS, PLAT_SP_PRI),
  29. #endif
  30. #endif
  31. /* Platform specific exceptions description */
  32. #ifdef PLAT_EHF_DESC
  33. PLAT_EHF_DESC,
  34. #endif
  35. };
  36. /* Plug in ARM exceptions to Exception Handling Framework. */
  37. EHF_REGISTER_PRIORITIES(plat_exceptions, ARRAY_SIZE(plat_exceptions), PLAT_PRI_BITS);