Add support for Zephyr debug slot manager and use it by default#10500
Add support for Zephyr debug slot manager and use it by default#10500lgirdwood merged 2 commits intothesofproject:mainfrom
Conversation
jsarha
left a comment
There was a problem hiding this comment.
Looks Ok and works nicely debug_stream.
kv2019i
left a comment
There was a problem hiding this comment.
Code good, some typos in commit making it a bit hard to follow.
| @@ -20,11 +20,25 @@ | |||
| /* CPU specific mutexes for each circular buffer */ | |||
There was a problem hiding this comment.
Some typoes in commit (hardocded, "debug lost management"), code looks good.
There was a problem hiding this comment.
what a nice anagrams they were ;)
| static struct cpu_mutex cpu_mutex[CONFIG_MP_MAX_NUM_CPUS]; | ||
|
|
||
| #ifdef CONFIG_INTEL_ADSP_DEBUG_SLOT_MANAGER | ||
| static struct debug_stream_slot_hdr *slot; |
There was a problem hiding this comment.
please give it a longer name. Names like this make grepping / tagging quite difficult. Can be an incremental patch.
There was a problem hiding this comment.
OK, will do in while addressing the anagrams
|
|
||
| struct cpu_mutex { | ||
| struct k_mutex m; | ||
| } __aligned(CONFIG_DCACHE_LINE_SIZE); |
There was a problem hiding this comment.
Is there any documentation about how this debugging works? We use mainly the serial console for imx-es.
There was a problem hiding this comment.
Intel debugging is done via some kernel debugFS interfaces that expose a shared memory window between host OS and DSP FW. There are a few tools today that read/format the debugFS contents (all upstream).
Add support for Zephyr debug slot manager API to move away from hard coded slot allocation. The support is added with ifdef to be able to switch back to the old hard coded debug slot 'management' Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
05ac98d to
120e664
Compare
Zephyr has support for dynamic debug slot management to replace the currently used wild-west style debug slot "allocation" Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
|
Changes since v1:
|
Instead of 'blindly' writing to debug slots using hardwired numbers, use the debug slot manager API to work with the slots.
In theory this change would allow more debug slot users to be enabled and only limited by the amount on slots available for the platform.