Skip to content

Commit 6c76d4d

Browse files
author
Jyri Sarha
committed
zephyr: idc: Name IDC p4wq threads
Name IDC p4wq threads. Unfortunately the idc threads only get their names after they are needed for the first time. Until that time they appear as unnamed (a hex number) threads on core 0. There is also one funny thing. There is static thread reserved for core 0, but that is never activated, and it remains there as a hex number forever. However, in this simple and risk free convenience fix, I do not dare to touch that. Maybe later. Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
1 parent ac805f1 commit 6c76d4d

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/idc/zephyr_idc.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,10 +181,14 @@ int idc_send_msg(struct idc_msg *msg, uint32_t mode)
181181

182182
void idc_init_thread(void)
183183
{
184+
char thread_name[] = "idc_p4wq0";
184185
int cpu = cpu_get_id();
185186

186187
k_p4wq_enable_static_thread(q_zephyr_idc + cpu,
187188
_p4threads_q_zephyr_idc + cpu, BIT(cpu));
189+
190+
thread_name[sizeof(thread_name) - 2] = '0' + cpu;
191+
k_thread_name_set(_p4threads_q_zephyr_idc + cpu, thread_name);
188192
/*
189193
* Assign SOF system heap to the IDC thread. Otherwise by default it
190194
* uses the Zephyr heap for DP stack allocation

0 commit comments

Comments
 (0)