-
Notifications
You must be signed in to change notification settings - Fork 7.7k
Open
Labels
area: TracingTracingTracingbugThe issue is a bug, or the PR is fixing a bugThe issue is a bug, or the PR is fixing a bugplatform: nRFNordic nRFxNordic nRFx
Description
Describe the bug
Enabling CONFIG_TRACING_CTF
triggers the assertion on line
hal/nordic/nrfx/drivers/src/nrfx_grtc.c:278
:
NRFX_ASSERT(m_cb.state == NRFX_DRV_STATE_INITIALIZED);
By placing a breakpoint in both nrfx_grtc_init
and in nrfx_grtc_syscounter_get
, it appear that the latter is called before init is ever called, and therefore the m_cb.state
is still uninitialized.
Stack trace for the first call to nrfx_grtc_syscounter_get
:
(gdb) where
#0 nrfx_grtc_sycounter_get (p_counter=0xf72e91c0) at /home/jaagup/projects/gale_ws/gale/projects/modules/hal/nordic/nrfx/drivers/src/nrfx_grtc.c:278
#1 0x080d06e2 in counter () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/drivers/timer/nrf_grtc_timer.c:88
#2 0x080d08dc in sys_clock_cycle_get_32 () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/drivers/timer/nrf_grtc_timer.c:434
#3 0x080f5ed in arch_k_cycle_get_32 () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/include/zephyr/arch/posix/arch.h:46
#4 0x0808fa77 in k_cycle_get_32 () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/include/zephyr/kernel.h:1957
#5 0x0809a1bd in ctf_top_semaphore_init (sem_id=136284100, ret=0) at /home/jaagup/projects/gale_ws/gale/projects/zephyr/subsys/tracing/ctf/./ctf_top.h:320
#6 0x0809a7c6 in sys_trace_k_sem_init (sem=0x81f87c4 <log_buffer+44>, ret=0) at /home/jaagup/projects/gale_ws/gale/projects/zephyr/subsys/tracing/ctf/ctf_top.c:208
#7 0x0810aa36 in z_impl_k_sem_init (sem=0x81f87c4 <log_buffer+44>, initial_count=0, limit=1)
at /home/jaagup/projects/gale_ws/gale/projects/zephyr/kernel/sem.c:60
#8 0x08087fae in k_sem_init (sem=0x81f87c4 <log_buffer+44>, initial_count=0, limit=1)
at /home/jaagup/projects/gale_ws/gale/projects/hmi_app/build/hmi_app/zephyr/include/generated/zephyr/syscalls/kernel.h:1085
#9 0x0808523 in mpsc_pbuf_init (buffer=0x81f8798 <log_buffer>, cfg=0x817c7e8 <mpsc_config>)
at /home/jaagup/projects/gale_ws/gale/projects/zephyr/lib/os/mpsc_pbuf.c:46
#10 0x080915f7 in z_log_msg_init () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/subsys/logging/log_core.c:654
#11 0x08090968 in log_core_init () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/subsys/logging/log_core.c:290
#12 0x0801356 in z_cstart () at /home/jaagup/projects/gale_ws/gale/projects/zephyr/kernel/init.c:782
#13 0x0811b073 in sw_wrapper (this_arg=0x821eee0) at /home/jaagup/projects/gale_ws/gale/projects/zephyr/scripts/native_simulator/common/src/nce.c:149
#14 0xf74fc481 in ?? () from /lib32/libc.so.6
#15 0xf7593508 in ?? () from /lib32/libc.so.6
(gdb)
Regression
- This is a regression.
Steps to reproduce
No response
Relevant log output
Impact
Annoyance – Minor irritation; no significant impact on usability or functionality.
Environment
No response
Additional Context
No response
Metadata
Metadata
Assignees
Labels
area: TracingTracingTracingbugThe issue is a bug, or the PR is fixing a bugThe issue is a bug, or the PR is fixing a bugplatform: nRFNordic nRFxNordic nRFx