SEGGER_SYSVIEW_Conf.h 854 B

12345678910111213141516171819202122232425262728293031
  1. /*
  2. * Copyright (c) 2020 Intel Corporation
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. */
  6. #pragma once
  7. #include <stdint.h>
  8. #include <irq.h>
  9. #define SEGGER_SYSVIEW_GET_TIMESTAMP sysview_get_timestamp
  10. #define SEGGER_SYSVIEW_GET_INTERRUPT_ID sysview_get_interrupt
  11. uint32_t sysview_get_timestamp(void);
  12. uint32_t sysview_get_interrupt(void);
  13. #define SEGGER_SYSVIEW_RTT_BUFFER_SIZE CONFIG_SEGGER_SYSVIEW_RTT_BUFFER_SIZE
  14. #define SEGGER_SYSVIEW_POST_MORTEM_MODE CONFIG_SEGGER_SYSVIEW_POST_MORTEM_MODE
  15. #if defined(CONFIG_SEGGER_SYSVIEW_SECTION_DTCM)
  16. #define SEGGER_SYSVIEW_SECTION ".dtcm_data"
  17. #endif
  18. /* Lock SystemView (nestable) */
  19. #define SEGGER_SYSVIEW_LOCK() { \
  20. unsigned int __sysview_irq_key = \
  21. irq_lock()
  22. /* Unlock SystemView (nestable) */
  23. #define SEGGER_SYSVIEW_UNLOCK() irq_unlock(__sysview_irq_key); \
  24. }