Dictionary-based trace logging engine, log filtering, and mailbox trace fallback.
More...
|
| #define | _DECLARE_LOG_ENTRY(lvl, format, comp_class, n_params) |
| | The start of this linker output MUST match the 'ldc_entry_header' struct defined in the logger program running in user space.
|
| |
| #define | _TRACE_EVENT_MAX_ARGUMENT_COUNT 4 |
| |
| #define | trace_event_with_ids(class, ctx, id_1, id_2, format, ...) |
| |
| #define | trace_event_atomic_with_ids(class, ctx, id_1, id_2, format, ...) |
| |
| #define | trace_warn_with_ids(class, ctx, id_1, id_2, format, ...) |
| |
| #define | trace_warn_atomic_with_ids(class, ctx, id_1, id_2, format, ...) |
| |
| #define | _trace_event_with_ids(lvl, class, ctx, id_1, id_2, format, ...) _log_message(trace_log_filtered, false, lvl, class, ctx, id_1, id_2, format, ##__VA_ARGS__) |
| |
| #define | _trace_event_atomic_with_ids(lvl, class, ctx, id_1, id_2, format, ...) _log_message(trace_log_filtered, true, lvl, class, ctx, id_1, id_2, format, ##__VA_ARGS__) |
| |
| #define | MTRACE_DUPLICATION_LEVEL LOG_LEVEL_ERROR |
| |
| #define | trace_point(x) platform_trace_point(x) |
| |
| #define | BASE_LOG_ASSERT_FAIL_MSG |
| |
| #define | CT_ASSERT(COND, MESSAGE) ((void)sizeof(char[1 - 2 * !(COND)])) |
| |
| #define | trace_check_size_uint32(a) CT_ASSERT(sizeof(a) <= sizeof(uint32_t), "error: trace argument is bigger than a uint32_t"); |
| |
| #define | STATIC_ASSERT_ARG_SIZE(...) META_MAP(1, trace_check_size_uint32, __VA_ARGS__) |
| |
| #define | _log_message(log_func, atomic, lvl, comp_class, ctx, id_1, id_2, format, ...) |
| | _log_message is where the memory-saving dictionary magic described above happens: the "format" string argument is moved to a special linker section and replaced by a &log_entry pointer to it.
|
| |
| #define | _log_nodict(atomic, arg_count, lvl, format, ...) |
| |
| #define | tracev_event_with_ids(class, ctx, id_1, id_2, format, ...) trace_unused(class, ctx, id_1, id_2, format, ##__VA_ARGS__) |
| |
| #define | tracev_event_atomic_with_ids(class, ctx, id_1, id_2, format, ...) trace_unused(class, ctx, id_1, id_2, format, ##__VA_ARGS__) |
| |
| #define | trace_error_with_ids(...) trace_event_with_ids(__VA_ARGS__) |
| |
| #define | trace_error_atomic_with_ids(...) trace_event_atomic_with_ids(__VA_ARGS__) |
| |
| #define | trace_dev_err(get_ctx_m, get_id_m, get_subid_m, dev, fmt, ...) |
| | Trace from a device on err level.
|
| |
| #define | trace_dev_warn(get_ctx_m, get_id_m, get_subid_m, dev, fmt, ...) |
| | Trace from a device on warning level.
|
| |
| #define | trace_dev_info(get_ctx_m, get_id_m, get_subid_m, dev, fmt, ...) |
| | Trace from a device on info level.
|
| |
| #define | trace_dev_dbg(get_ctx_m, get_id_m, get_subid_m, dev, fmt, ...) |
| | Trace from a device on dbg level.
|
| |
| #define | tr_err_atomic(ctx, fmt, ...) |
| |
| #define | tr_warn_atomic(ctx, fmt, ...) |
| |
| #define | tr_info_atomic(ctx, fmt, ...) |
| |
| #define | tr_dbg_atomic(ctx, fmt, ...) |
| |
| #define | tr_err(ctx, fmt, ...) |
| |
| #define | tr_warn(ctx, fmt, ...) |
| |
| #define | tr_info(ctx, fmt, ...) |
| |
| #define | tr_dbg(ctx, fmt, ...) |
| |
| #define | mtrace_printf(log_level, format_str, ...) |
| | Direct, low-level access to mbox / shared memory logging when DMA tracing is either not initialized yet or disabled or found broken for any reason.
|
| |
|
| static struct trace * | trace_get (void) |
| | Retrieve global trace subsystem context from SOF runtime.
|
| |
| void | trace_flush_dma_to_mbox (void) |
| | Flush buffered trace data from DMA buffer to Mailbox Window.
|
| |
| void | trace_on (void) |
| | Globally resume trace event logging.
|
| |
| void | trace_off (void) |
| | Globally pause trace event logging.
|
| |
| void | trace_init (struct sof *sof) |
| | Initialize the trace subsystem and allocate global trace buffers.
|
| |
| void | trace_log_filtered (bool send_atomic, const void *log_entry, const struct tr_ctx *ctx, uint32_t lvl, uint32_t id_1, uint32_t id_2, int arg_count, va_list args) |
| | Emit a filtered dictionary trace message.
|
| |
| void | trace_log_unfiltered (bool send_atomic, const void *log_entry, const struct tr_ctx *ctx, uint32_t lvl, uint32_t id_1, uint32_t id_2, int arg_count, va_list args) |
| | Emit an unfiltered dictionary trace message directly to buffers.
|
| |
| struct sof_ipc_trace_filter_elem * | trace_filter_fill (struct sof_ipc_trace_filter_elem *elem, struct sof_ipc_trace_filter_elem *end, struct trace_filter *filter) |
| | Populate an IPC trace filter element array.
|
| |
| int | trace_filter_update (const struct trace_filter *elem) |
| | Update runtime trace filtering configuration from IPC payload.
|
| |
| void | mtrace_dict_entry (bool atomic_context, uint32_t log_entry_pointer, int n_args,...) |
| | Appends one SOF dictionary entry and log statement to shared memory mtrace.
|
| |
| void | mtrace_event (const char *complete_packet, uint32_t length) |
| | Posts a fully prepared log header and log entry packet to mtrace buffer.
|
| |
| void | _log_sofdict (log_func_t sofdict_logf, bool atomic, const void *log_entry, const struct tr_ctx *ctx, const uint32_t lvl, uint32_t id_1, uint32_t id_2, int arg_count,...) |
| | Internal dictionary logger formatting and dispatch helper.
|
| |
Dictionary-based trace logging engine, log filtering, and mailbox trace fallback.