sys_reg_trace.h 943 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. /*
  2. * Copyright (c) 2021-2023, Arm Limited. All rights reserved.
  3. *
  4. * SPDX-License-Identifier: BSD-3-Clause
  5. */
  6. #ifndef SYS_REG_TRACE_H
  7. #define SYS_REG_TRACE_H
  8. #include <context.h>
  9. #if ENABLE_SYS_REG_TRACE_FOR_NS
  10. #if __aarch64__
  11. void sys_reg_trace_enable_per_world(per_world_context_t *per_world_ctx);
  12. void sys_reg_trace_disable_per_world(per_world_context_t *per_world_ctx);
  13. void sys_reg_trace_init_el2_unused(void);
  14. #else
  15. void sys_reg_trace_init_el3(void);
  16. #endif /* __aarch64__ */
  17. #else /* !ENABLE_SYS_REG_TRACE_FOR_NS */
  18. #if __aarch64__
  19. static inline void sys_reg_trace_enable_per_world(per_world_context_t *per_world_ctx)
  20. {
  21. }
  22. static inline void sys_reg_trace_disable_per_world(per_world_context_t *per_world_ctx)
  23. {
  24. }
  25. static inline void sys_reg_trace_init_el2_unused(void)
  26. {
  27. }
  28. #else
  29. static inline void sys_reg_trace_init_el3(void)
  30. {
  31. }
  32. #endif /* __aarch64__ */
  33. #endif /* ENABLE_SYS_REG_TRACE_FOR_NS */
  34. #endif /* SYS_REG_TRACE_H */