Zephyr Project API 3.7.0
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
main.c File Reference
#include <zephyr/ztest.h>
#include <zephyr/pm/pm.h>
#include <zephyr/irq_offload.h>
#include <zephyr/debug/stack.h>

Macros

#define SLEEP_MS   100
 
#define NUM_OF_WORK   2
 
#define TEST_STRING   "TEST"
 

Functions

static void tdata_dump_callback (const struct k_thread *thread, void *user_data)
 TESTPOINT: stack analyze.
 
static void work_handler (struct k_work *w)
 
 ZTEST (profiling_api, test_call_stacks_analyze_main)
 Test stack usage through main thread.
 
 ZTEST (profiling_api_1cpu, test_call_stacks_analyze_idle)
 Test stack usage through idle thread.
 
 ZTEST (profiling_api_1cpu, test_call_stacks_analyze_workq)
 Test stack usage through system workqueue.
 
 ZTEST_SUITE (profiling_api, NULL, NULL, NULL, NULL, NULL)
 
 ZTEST_SUITE (profiling_api_1cpu, NULL, NULL, ztest_simple_1cpu_before, ztest_simple_1cpu_after, NULL)
 

Variables

static struct k_work work [2]
 
static struct k_sem sync_sema
 

Macro Definition Documentation

◆ NUM_OF_WORK

#define NUM_OF_WORK   2

◆ SLEEP_MS

#define SLEEP_MS   100

◆ TEST_STRING

#define TEST_STRING   "TEST"

Function Documentation

◆ tdata_dump_callback()

static void tdata_dump_callback ( const struct k_thread thread,
void *  user_data 
)
static

TESTPOINT: stack analyze.

◆ work_handler()

static void work_handler ( struct k_work w)
static

◆ ZTEST_SUITE() [1/2]

ZTEST_SUITE ( profiling_api  ,
NULL  ,
NULL  ,
NULL  ,
NULL  ,
NULL   
)

◆ ZTEST_SUITE() [2/2]

ZTEST_SUITE ( profiling_api_1cpu  ,
NULL  ,
NULL  ,
ztest_simple_1cpu_before  ,
ztest_simple_1cpu_after  ,
NULL   
)

Variable Documentation

◆ sync_sema

struct k_sem sync_sema
static

◆ work

struct k_work work[2]
static