* Re: [PATCH v4] rethook: Remove the running task check in rethook_find_ret_addr()
From: sashiko-bot @ 2026-06-10 1:50 UTC (permalink / raw)
To: Masami Hiramatsu, Petr Mladek, Peter Zijlstra
Cc: Tengda Wu, Mathieu Desnoyers, Alexei Starovoitov, Steven Rostedt,
linux-kernel, linux-trace-kernel, live-patching
In-Reply-To: <20260610013658.1837963-1-wutengda@huaweicloud.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
Pre-existing issues:
- [High] Removing `task_is_running()` from `rethook_find_ret_addr()` exposes stack unwinders to use-after-free, wild pointer dereferences, and list corruption when unwinding running tasks, because `rethook_node` recycling and unwinding lack adequate RCU synchronization.
--
commit 83e1fac9c64377191cc2b41ef9da781c46f1e95a
Author: Tengda Wu <wutengda@huaweicloud.com>
rethook: Remove the running task check in rethook_find_ret_addr()
This commit removes the task_is_running() check from rethook_find_ret_addr().
The commit message states the check is unnecessary because unwinders hold RCU
and rethook_node structures are RCU-freed. Callers are expected to provide
their own safe context.
> The iteration is already safe from crashes because
> unwind_next_frame() holds RCU and rethook_node structures are RCU-freed;
> even if the iteration goes off the rails and returns invalid information,
> it will not crash. Callers that require consistency must provide a safe
> context themselves.
[ ... ]
> diff --git a/kernel/trace/rethook.c b/kernel/trace/rethook.c
> index 5a8bdf88999a9..1e7fdebe3cd5d 100644
> --- a/kernel/trace/rethook.c
> +++ b/kernel/trace/rethook.c
[ ... ]
> @@ -250,9 +251,6 @@ unsigned long rethook_find_ret_addr(struct task_struct *tsk, unsigned long frame
> if (WARN_ON_ONCE(!cur))
> return 0;
>
> - if (tsk != current && task_is_running(tsk))
> - return 0;
> -
> do {
> ret = __rethook_find_ret_addr(tsk, cur);
[Severity: High]
This is a pre-existing issue, but does removing this check entirely expose
the stack unwinders to a use-after-free and list corruption?
The commit message mentions that rethook_node structures are RCU-freed, but
looking at rethook_recycle(), the nodes appear to be immediately pushed back
to the lockless objpool without an RCU grace period:
kernel/trace/rethook.c:rethook_recycle() {
...
objpool_push(node, &node->rethook->pool);
}
Additionally, while unwind_next_frame() does hold RCU for a single frame
iteration, stack unwinders like x86 ORC drop the read lock between frames:
arch/x86/kernel/unwind_orc.c:unwind_next_frame() {
...
guard(rcu)();
...
}
Because the unwinder retains the list cursor (*cur) across frame iterations
while RCU is dropped, could unwinding a running task allow the target task
to recycle the node?
If the node is recycled and instantly reallocated to another task, the next
call to __rethook_find_ret_addr() would execute:
kernel/trace/rethook.c:__rethook_find_ret_addr() {
...
node = node->next;
on a stale pointer. Could removing this check turn a theoretical race into
an easily triggered use-after-free when reading /proc/<pid>/stack for tasks
executing kretprobes?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260610013658.1837963-1-wutengda@huaweicloud.com?part=1
^ permalink raw reply
* [PATCH] task_work: add tracepoints for task_work callbacks
From: Imran Khan @ 2026-06-10 4:14 UTC (permalink / raw)
To: rostedt, mhiramat, mathieu.desnoyers, peterz
Cc: linux-trace-kernel, linux-kernel
task_work tracepoints can be enabled by:
echo 1 > /sys/kernel/tracing/events/task_work/enable
and trace logs would look like:
... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a508 func=____fput notify=TWA_RESUME
... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a508 ret=0
... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a5c8 func=____fput notify=TWA_RESUME
... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a5c8 ret=0
... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a688 func=____fput notify=TWA_RESUME
... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a688 ret=0
... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a748 func=____fput notify=TWA_RESUME
... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a748 ret=0
... task_work_run_start: comm=ls pid=227 work=ffff95d20641a748 func=____fput
... task_work_run_end: comm=ls pid=227 work=ffff95d20641a748 func=____fput
... task_work_run_start: comm=ls pid=227 work=ffff95d20641a688 func=____fput
... task_work_run_end: comm=ls pid=227 work=ffff95d20641a688 func=____fput
... task_work_run_start: comm=ls pid=227 work=ffff95d20641a5c8 func=____fput
... task_work_run_end: comm=ls pid=227 work=ffff95d20641a5c8 func=____fput
... task_work_run_start: comm=ls pid=227 work=ffff95d20641a508 func=____fput
... task_work_run_end: comm=ls pid=227 work=ffff95d20641a508 func=____fput
formatted as:
target_comm=<comm of target task>
target_pid=<pid of target task>
work=<callback_head *>
func=<callback_head->func>
notify=<way to notify the target task>
comm=<comm of current task executing func>
pid=<pid of current task executing func>
Signed-off-by: Imran Khan <imran.f.khan@oracle.com>
---
include/trace/events/task_work.h | 129 +++++++++++++++++++++++++++++++
kernel/task_work.c | 32 +++++++-
2 files changed, 159 insertions(+), 2 deletions(-)
create mode 100644 include/trace/events/task_work.h
diff --git a/include/trace/events/task_work.h b/include/trace/events/task_work.h
new file mode 100644
index 0000000000000..e43ffd607e7ec
--- /dev/null
+++ b/include/trace/events/task_work.h
@@ -0,0 +1,129 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#undef TRACE_SYSTEM
+#define TRACE_SYSTEM task_work
+
+#if !defined(_TRACE_TASK_WORK_H) || defined(TRACE_HEADER_MULTI_READ)
+#define _TRACE_TASK_WORK_H
+
+#include <linux/tracepoint.h>
+#include <linux/task_work.h>
+
+TRACE_DEFINE_ENUM(TWA_NONE);
+TRACE_DEFINE_ENUM(TWA_RESUME);
+TRACE_DEFINE_ENUM(TWA_SIGNAL);
+TRACE_DEFINE_ENUM(TWA_SIGNAL_NO_IPI);
+TRACE_DEFINE_ENUM(TWA_NMI_CURRENT);
+
+#define show_task_work_notify_mode(notify) \
+ __print_symbolic(notify, \
+ { TWA_NONE, "TWA_NONE" }, \
+ { TWA_RESUME, "TWA_RESUME" }, \
+ { TWA_SIGNAL, "TWA_SIGNAL" }, \
+ { TWA_SIGNAL_NO_IPI, "TWA_SIGNAL_NO_IPI" }, \
+ { TWA_NMI_CURRENT, "TWA_NMI_CURRENT" })
+
+/*
+ * task_work_add() is split into two events:
+ *
+ * task_work:add_request - fires before the cmpxchg that enqueues
+ * @work. Guaranteed to happen-before any
+ * run_start has picked the @work.
+ * task_work:add_done - fires after the cmpxchg loop terminates,
+ * carrying the final ret value.
+ */
+TRACE_EVENT(task_work_add_request,
+
+ TP_PROTO(struct task_struct *task,
+ struct callback_head *work,
+ task_work_func_t func,
+ enum task_work_notify_mode notify),
+
+ TP_ARGS(task, work, func, notify),
+
+ TP_STRUCT__entry(
+ __field(pid_t, pid)
+ __array(char, comm, TASK_COMM_LEN)
+ __field(void *, work)
+ __field(void *, func)
+ __field(int, notify)
+ ),
+
+ TP_fast_assign(
+ __entry->pid = task->pid;
+ memcpy(__entry->comm, task->comm, TASK_COMM_LEN);
+ __entry->work = work;
+ __entry->func = func;
+ __entry->notify = notify;
+ ),
+
+ TP_printk("target_comm=%s target_pid=%d work=%p func=%ps notify=%s",
+ __entry->comm, __entry->pid, __entry->work,
+ __entry->func, show_task_work_notify_mode(__entry->notify))
+);
+
+TRACE_EVENT(task_work_add_done,
+
+ TP_PROTO(struct task_struct *task,
+ struct callback_head *work,
+ int ret),
+
+ TP_ARGS(task, work, ret),
+
+ TP_STRUCT__entry(
+ __field(pid_t, pid)
+ __array(char, comm, TASK_COMM_LEN)
+ __field(void *, work)
+ __field(int, ret)
+ ),
+
+ TP_fast_assign(
+ __entry->pid = task->pid;
+ memcpy(__entry->comm, task->comm, TASK_COMM_LEN);
+ __entry->work = work;
+ __entry->ret = ret;
+ ),
+
+ TP_printk("target_comm=%s target_pid=%d work=%p ret=%d",
+ __entry->comm, __entry->pid, __entry->work, __entry->ret)
+);
+
+DECLARE_EVENT_CLASS(task_work_run_template,
+
+ TP_PROTO(struct task_struct *task,
+ struct callback_head *work,
+ task_work_func_t func),
+
+ TP_ARGS(task, work, func),
+
+ TP_STRUCT__entry(
+ __field(pid_t, pid)
+ __array(char, comm, TASK_COMM_LEN)
+ __field(void *, work)
+ __field(void *, func)
+ ),
+
+ TP_fast_assign(
+ __entry->pid = task->pid;
+ memcpy(__entry->comm, task->comm, TASK_COMM_LEN);
+ __entry->work = work;
+ __entry->func = func;
+ ),
+
+ TP_printk("comm=%s pid=%d work=%p func=%ps",
+ __entry->comm, __entry->pid, __entry->work, __entry->func)
+);
+
+DEFINE_EVENT(task_work_run_template, task_work_run_start,
+ TP_PROTO(struct task_struct *task, struct callback_head *work,
+ task_work_func_t func),
+ TP_ARGS(task, work, func));
+
+DEFINE_EVENT(task_work_run_template, task_work_run_end,
+ TP_PROTO(struct task_struct *task, struct callback_head *work,
+ task_work_func_t func),
+ TP_ARGS(task, work, func));
+
+#endif /* _TRACE_TASK_WORK_H */
+
+/* This part must be outside protection */
+#include <trace/define_trace.h>
diff --git a/kernel/task_work.c b/kernel/task_work.c
index 0f7519f8e7c93..ed04a8c7116de 100644
--- a/kernel/task_work.c
+++ b/kernel/task_work.c
@@ -4,6 +4,9 @@
#include <linux/task_work.h>
#include <linux/resume_user_mode.h>
+#define CREATE_TRACE_POINTS
+#include <trace/events/task_work.h>
+
static struct callback_head work_exited; /* all we need is ->next == NULL */
#ifdef CONFIG_IRQ_WORK
@@ -60,6 +63,7 @@ int task_work_add(struct task_struct *task, struct callback_head *work,
enum task_work_notify_mode notify)
{
struct callback_head *head;
+ task_work_func_t func;
if (notify == TWA_NMI_CURRENT) {
if (WARN_ON_ONCE(task != current))
@@ -70,10 +74,25 @@ int task_work_add(struct task_struct *task, struct callback_head *work,
kasan_record_aux_stack(work);
}
+ /*
+ * Snapshot work->func before the cmpxchg below publishes @work.
+ * After publish, a concurrent task_work_run() on @task may invoke
+ * the callback and free @work, after which dereferencing work->func
+ * to fill the tracepoint payload would cause UAF error.
+ */
+ func = work->func;
+
+ /*
+ * Emit add_request BEFORE the cmpxchg loop.
+ * Tracing here guarantees add_request is seen before any possible
+ * run_start.
+ */
+ trace_task_work_add_request(task, work, func, notify);
+
head = READ_ONCE(task->task_works);
do {
if (unlikely(head == &work_exited))
- return -ESRCH;
+ goto out_esrch;
work->next = head;
} while (!try_cmpxchg(&task->task_works, &head, work));
@@ -100,7 +119,12 @@ int task_work_add(struct task_struct *task, struct callback_head *work,
break;
}
+ trace_task_work_add_done(task, work, 0);
return 0;
+
+out_esrch:
+ trace_task_work_add_done(task, work, -ESRCH);
+ return -ESRCH;
}
/**
@@ -229,8 +253,12 @@ void task_work_run(void)
raw_spin_unlock_irq(&task->pi_lock);
do {
+ task_work_func_t func = work->func;
+
next = work->next;
- work->func(work);
+ trace_task_work_run_start(task, work, func);
+ func(work);
+ trace_task_work_run_end(task, work, func);
work = next;
cond_resched();
} while (work);
--
2.43.0
^ permalink raw reply related
* Re: [PATCH 0/2] arm64: ftrace: support DIRECT_CALLS without CALL_OPS
From: Clayton Craft @ 2026-06-10 4:42 UTC (permalink / raw)
To: Jose Fernandez (Anthropic), Steven Rostedt, Masami Hiramatsu,
Mark Rutland, Catalin Marinas, Will Deacon, Nathan Chancellor,
Nick Desaulniers, Bill Wendling, Justin Stitt
Cc: linux-kernel, linux-trace-kernel, linux-arm-kernel, llvm, bpf,
Florent Revest, Puranjay Mohan, Xu Kuohai
In-Reply-To: <20260609-arm64-ftrace-direct-calls-v1-0-4a46f266697f@linux.dev>
On Mon Jun 8, 2026 at 10:19 PM PDT, Jose Fernandez (Anthropic) wrote:
> On arm64, HAVE_DYNAMIC_FTRACE_WITH_DIRECT_CALLS is currently selected
> only when DYNAMIC_FTRACE_WITH_CALL_OPS is available. CALL_OPS, in
> turn, is mutually exclusive with kCFI: the pre-function NOPs it needs
> would change the offset of the pre-function type hash (see
> baaf553d3bc3 ("arm64: Implement HAVE_DYNAMIC_FTRACE_WITH_CALL_OPS")),
> and the compiler support needed to reconcile the two does not exist
> yet.
>
> The result is that a CONFIG_CFI=y arm64 kernel has no
> ftrace direct calls at all, so register_fentry() fails with -ENOTSUPP
> and no BPF trampoline can attach: fentry/fexit, fmod_ret and BPF LSM
> programs are all unavailable. Deployments that want both kCFI
> hardening and BPF-based security monitoring currently have to give
> one of them up. systemd's bpf-restrict-fs feature hits this today:
> https://lore.kernel.org/all/20250610232418.GA3544567@ax162/
>
> CALL_OPS is an optimization for direct calls, not a dependency.
> In-BL-range trampolines are reached by a direct branch without
> consulting the ops pointer, and out-of-range trampolines already
> fall back to ftrace_caller, where the DIRECT_CALLS machinery
> (call_direct_funcs() storing the trampoline in ftrace_regs, the
> ftrace_caller tail-call) is gated on DIRECT_CALLS alone. s390 and
> loongarch ship HAVE_DYNAMIC_FTRACE_WITH_DIRECT_CALLS this way,
> without having CALL_OPS at all.
>
> Patch 1 prepares ftrace_modify_call() to build without CALL_OPS by
> widening its #ifdef and using the existing ftrace_rec_update_ops()
> wrapper (no functional change for current configurations). Patch 2
> drops the CALL_OPS requirement from the DIRECT_CALLS select.
>
> Configurations that keep CALL_OPS (clang !CFI, and GCC without
> CC_OPTIMIZE_FOR_SIZE) are unchanged. We verified this: in an arm64
> clang build, every object file is byte-identical before and after
> the series except ftrace.o itself, and its disassembly is identical.
> CFI builds (and GCC -Os builds) gain working direct calls, with
> out-of-range attachments taking the ftrace_caller dispatch path
> instead of the per-callsite fast path.
>
> We tested on a 6.18.y-based kernel and on this base with clang
> kCFI builds (CONFIG_CFI=y, enforcing) under qemu (TCG, and KVM on an
> arm64 host) and on GB200-based arm64 hardware: fentry/fexit, fmod_ret
> and BPF LSM programs load, attach and execute; the ftrace-direct
> sample modules (including both modify samples, exercising
> ftrace_modify_call()) run cleanly; no CFI violations observed. The
> fentry_test, fexit_test, fentry_fexit, fexit_sleep, fexit_stress,
> modify_return, tracing_struct, lsm and trampoline_count selftests and
> the ftrace direct-call selftests (test.d/direct) pass on the new
> configuration with results identical to a CALL_OPS kernel built from
> the same tree, and a broader test_progs sweep showed no differences
> attributable to this series. Without the series, all of the above
> fail at attach time with -ENOTSUPP.
>
> riscv has the same gap (its DIRECT_CALLS select also requires
> CALL_OPS, and its CALL_OPS is likewise !CFI); if this approach is
> acceptable for arm64 we can follow up there.
>
> ---
> Jose Fernandez (Anthropic) (2):
> arm64: ftrace: prepare ftrace_modify_call() for use without CALL_OPS
> arm64: ftrace: allow DIRECT_CALLS without CALL_OPS
>
> arch/arm64/Kconfig | 2 +-
> arch/arm64/kernel/ftrace.c | 5 +++--
> 2 files changed, 4 insertions(+), 3 deletions(-)
> ---
> base-commit: 254f49634ee16a731174d2ae34bc50bd5f45e731
> change-id: 20260607-arm64-ftrace-direct-calls-152230ef7077
>
> Best regards,
> --
> Jose Fernandez (Anthropic) <jose.fernandez@linux.dev>
Thanks for fixing this! I gave it a try on an aarch64 laptop (macbook m2)
using kernel 7.0.11 with CFI=y && DEBUG_INFO_BTF=y, built with clang. AFAIK it
seems to work great, I am able to finally run systemd with BPF support (e.g.,
unprivileged nspawn works now)
Tested-by: Clayton Craft <craftyguy@postmarketos.org>
^ permalink raw reply
* Re: [PATCH] tracing: fprobe: Remove __packed from generic __fprobe_header
From: Markus Schneider-Pargmann @ 2026-06-10 7:17 UTC (permalink / raw)
To: Markus Schneider-Pargmann (The Capable Hub), Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Heiko Carstens
Cc: linux-kernel, linux-trace-kernel
In-Reply-To: <20260428-topic-fprobe-packed-v7-1-v1-1-9abc9b866b4c@baylibre.com>
[-- Attachment #1: Type: text/plain, Size: 1506 bytes --]
Hi,
On Tue Apr 28, 2026 at 10:30 AM CEST, Markus Schneider-Pargmann (The Capable Hub) wrote:
> fp pointer and unsigned long have the same size on all relevant
> architectures that build Linux. Furthermore this struct is only used in
> architectures that do not set ARCH_DEFINE_ENCODE_FPROBE_HEADER which is
> set only for 64bit architectures (apart from LoongArch).
>
> Both fields are aligned on these architectures so the struct with
> __packed and without it are the same.
>
> Remove the __packed as it is unnecessary.
Friendly ping on this.
Best
Markus
>
> Fixes: 4346ba160409 ("fprobe: Rewrite fprobe on function-graph tracer")
> Signed-off-by: Markus Schneider-Pargmann (The Capable Hub) <msp@baylibre.com>
> ---
> kernel/trace/fprobe.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/trace/fprobe.c b/kernel/trace/fprobe.c
> index cc49ebd2a773..21751dcdb7b9 100644
> --- a/kernel/trace/fprobe.c
> +++ b/kernel/trace/fprobe.c
> @@ -181,7 +181,7 @@ static inline void read_fprobe_header(unsigned long *stack,
> struct __fprobe_header {
> struct fprobe *fp;
> unsigned long size_words;
> -} __packed;
> +};
>
> #define FPROBE_HEADER_SIZE_IN_LONG SIZE_IN_LONG(sizeof(struct __fprobe_header))
>
>
> ---
> base-commit: 254f49634ee16a731174d2ae34bc50bd5f45e731
> change-id: 20260427-topic-fprobe-packed-v7-1-f44f9bbdedf6
>
> Best regards,
> --
> Markus Schneider-Pargmann (The Capable Hub) <msp@baylibre.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 289 bytes --]
^ permalink raw reply
* Re: [PATCH] task_work: add tracepoints for task_work callbacks
From: Peter Zijlstra @ 2026-06-10 8:00 UTC (permalink / raw)
To: Imran Khan
Cc: rostedt, mhiramat, mathieu.desnoyers, linux-trace-kernel,
linux-kernel
In-Reply-To: <20260610041408.2461637-1-imran.f.khan@oracle.com>
On Wed, Jun 10, 2026 at 12:14:08PM +0800, Imran Khan wrote:
> task_work tracepoints can be enabled by:
>
> echo 1 > /sys/kernel/tracing/events/task_work/enable
>
> and trace logs would look like:
>
> ... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a508 func=____fput notify=TWA_RESUME
> ... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a508 ret=0
> ... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a5c8 func=____fput notify=TWA_RESUME
> ... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a5c8 ret=0
> ... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a688 func=____fput notify=TWA_RESUME
> ... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a688 ret=0
> ... task_work_add_request: target_comm=ls target_pid=227 work=ffff95d20641a748 func=____fput notify=TWA_RESUME
> ... task_work_add_done: target_comm=ls target_pid=227 work=ffff95d20641a748 ret=0
> ... task_work_run_start: comm=ls pid=227 work=ffff95d20641a748 func=____fput
> ... task_work_run_end: comm=ls pid=227 work=ffff95d20641a748 func=____fput
> ... task_work_run_start: comm=ls pid=227 work=ffff95d20641a688 func=____fput
> ... task_work_run_end: comm=ls pid=227 work=ffff95d20641a688 func=____fput
> ... task_work_run_start: comm=ls pid=227 work=ffff95d20641a5c8 func=____fput
> ... task_work_run_end: comm=ls pid=227 work=ffff95d20641a5c8 func=____fput
> ... task_work_run_start: comm=ls pid=227 work=ffff95d20641a508 func=____fput
> ... task_work_run_end: comm=ls pid=227 work=ffff95d20641a508 func=____fput
>
> formatted as:
> target_comm=<comm of target task>
> target_pid=<pid of target task>
> work=<callback_head *>
> func=<callback_head->func>
> notify=<way to notify the target task>
> comm=<comm of current task executing func>
> pid=<pid of current task executing func>
And not a single justification for all this nonsense :-( So much ugly
and no gain...
^ permalink raw reply
* Re: [PATCH] tracing: fprobe: Remove __packed from generic __fprobe_header
From: Masami Hiramatsu @ 2026-06-10 8:17 UTC (permalink / raw)
To: Markus Schneider-Pargmann (The Capable Hub)
Cc: Steven Rostedt, Mathieu Desnoyers, Heiko Carstens, linux-kernel,
linux-trace-kernel
In-Reply-To: <20260428-topic-fprobe-packed-v7-1-v1-1-9abc9b866b4c@baylibre.com>
Hi Markus,
Thanks for ping me.
On Tue, 28 Apr 2026 10:30:29 +0200
"Markus Schneider-Pargmann (The Capable Hub)" <msp@baylibre.com> wrote:
> fp pointer and unsigned long have the same size on all relevant
> architectures that build Linux. Furthermore this struct is only used in
> architectures that do not set ARCH_DEFINE_ENCODE_FPROBE_HEADER which is
> set only for 64bit architectures (apart from LoongArch).
>
> Both fields are aligned on these architectures so the struct with
> __packed and without it are the same.
>
> Remove the __packed as it is unnecessary.
>
> Fixes: 4346ba160409 ("fprobe: Rewrite fprobe on function-graph tracer")
NOTE: This is not a Fix, but just cleanup or minor update. Or, you have
any problem with this __packed attribute?
Unless there is no problem (or any concern), I would like to keep this
as it is.
Thank you,
> Signed-off-by: Markus Schneider-Pargmann (The Capable Hub) <msp@baylibre.com>
> ---
> kernel/trace/fprobe.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/trace/fprobe.c b/kernel/trace/fprobe.c
> index cc49ebd2a773..21751dcdb7b9 100644
> --- a/kernel/trace/fprobe.c
> +++ b/kernel/trace/fprobe.c
> @@ -181,7 +181,7 @@ static inline void read_fprobe_header(unsigned long *stack,
> struct __fprobe_header {
> struct fprobe *fp;
> unsigned long size_words;
> -} __packed;
> +};
>
> #define FPROBE_HEADER_SIZE_IN_LONG SIZE_IN_LONG(sizeof(struct __fprobe_header))
>
>
> ---
> base-commit: 254f49634ee16a731174d2ae34bc50bd5f45e731
> change-id: 20260427-topic-fprobe-packed-v7-1-f44f9bbdedf6
>
> Best regards,
> --
> Markus Schneider-Pargmann (The Capable Hub) <msp@baylibre.com>
>
--
Masami Hiramatsu (Google) <mhiramat@kernel.org>
^ permalink raw reply
* Re: [PATCHv4 05/13] uprobes/x86: Move optimized uprobe from nop5 to nop10
From: Jiri Olsa @ 2026-06-10 8:18 UTC (permalink / raw)
To: Andrii Nakryiko
Cc: Jiri Olsa, Oleg Nesterov, Peter Zijlstra, Ingo Molnar,
Masami Hiramatsu, Andrii Nakryiko, bpf, linux-trace-kernel
In-Reply-To: <CAEf4BzbsB-PRZRqkz37YK5wYNR=ajZv2N7tEznpZM0rdyYC_xA@mail.gmail.com>
On Tue, Jun 09, 2026 at 09:43:15AM -0700, Andrii Nakryiko wrote:
> On Tue, Jun 9, 2026 at 4:44 AM Jiri Olsa <olsajiri@gmail.com> wrote:
> >
> > On Mon, Jun 08, 2026 at 01:46:39PM -0700, Andrii Nakryiko wrote:
> > > On Tue, May 26, 2026 at 1:59 PM Jiri Olsa <jolsa@kernel.org> wrote:
> > > >
> > > > Andrii reported an issue with optimized uprobes [1] that can clobber
> > > > redzone area with call instruction storing return address on stack
> > > > where user code may keep temporary data without adjusting rsp.
> > > >
> > > > Fixing this by moving the optimized uprobes on top of 10-bytes nop
> > > > instruction, so we can squeeze another instruction to escape the
> > > > redzone area before doing the call, like:
> > > >
> > > > lea -0x80(%rsp), %rsp
> > > > call tramp
> > > >
> > > > Note the lea instruction is used to adjust the rsp register without
> > > > changing the flags.
> > > >
> > > > We use nop10 and following transformation to optimized instructions
> > > > above and back as suggested by Peterz [2].
> > > >
> > > > Optimize path (int3_update_optimize):
> > > >
> > > > 1) Initial state after set_swbp() installed the uprobe:
> > > > cc 2e 0f 1f 84 00 00 00 00 00
> > > >
> > > > From offset 0 this is INT3 followed by the tail of the original
> > > > 10-byte NOP.
> > > >
> > > > After a previous unoptimization bytes 5..9 may still contain the
> > > > old call instruction, which remains valid for threads already there.
> > > >
> > > > 2) Rewrite the LEA tail and call displacement:
> > > > cc [8d 64 24 80 e8 d0 d1 d2 d3]
> > > >
> > > > From offset 0 this traps on the uprobe INT3. Bytes 1..9 are not
> > > > executable entry points while byte 0 is trapped.
> > > >
> > > > 3) Publish the first LEA byte:
> > > > [48] 8d 64 24 80 e8 d0 d1 d2 d3
> > > >
> > > > From offset 0 this is:
> > > > lea -0x80(%rsp), %rsp
> > > > call <uprobe-trampoline>
> > > >
> > > > Unoptimize path (int3_update_unoptimize):
> > > >
> > > > 1) Initial optimized state:
> > > > 48 8d 64 24 80 e8 d0 d1 d2 d3
> > > > Same as 3) above.
> > > >
> > > > 2) Trap new entries before restoring the NOP bytes:
> > > > [cc] 8d 64 24 80 e8 d0 d1 d2 d3
> > > >
> > > > From offset 0 this traps. A thread that had already executed the
> > > > LEA can still reach the intact CALL at offset 5.
> > > >
> > > > 3) Restore bytes 1..4 of the original NOP while keeping byte 0 trapped
> > > > and byte 5 as CALL.
> > > > cc [2e 0f 1f 84] e8 d0 d1 d2 d3
> > > >
> > > > From offset 0 this still traps. Offset 5 is still the CALL for any
> > > > thread that was already past the first LEA byte.
> > > >
> > > > 4) Publish the first byte of the original NOP:
> > > > [66] 2e 0f 1f 84 e8 d0 d1 d2 d3
> > > >
> > > > From offset 0 this is the restored 10-byte NOP; the CALL opcode and
> > > > displacement are now only NOP operands. Offset 5 still decodes as
> > > > CALL for a thread that was already there.
> > > >
> > > > Tthere is only a single target uprobe-trampoline for the given nop10
> > > > instruction address, so the CALL instruction will not be changed across
> > > > unoptimization/optimization cycles.
> > > > Therefore, any task that is preempted at the CALL instruction is guaranteed
> > > > to observe that CALL and not anything else.
> > > >
> > > > Note as explained in [2] we need to use following nop10:
> > > > PF1 PF2 ESC NOPL MOD SIB DISP32
> > > > NOP10: 0x66, 0x2e, 0x0f, 0x1f, 0x84, 0x00, 0x00, 0x00, 0x00, 0x00 -- cs nopw 0x00000000(%rax,%rax,1)
> > > >
> > > > which means we need to allow 0x2e prefix which maps to INAT_PFX_CS
> > > > attribute in is_prefix_bad function.
> > > >
> > > > Also changing the uprobe syscall error when called out of uprobe
> > > > trampoline to -EPROTO, so we are able to detect the fixed kernel.
> > > >
> > > > The optimized uprobe performance stays the same:
> > > >
> > > > uprobe-nop : 3.129 ± 0.013M/s
> > > > uprobe-push : 3.045 ± 0.006M/s
> > > > uprobe-ret : 1.095 ± 0.004M/s
> > > > --> uprobe-nop10 : 7.170 ± 0.020M/s
> > > > uretprobe-nop : 2.143 ± 0.021M/s
> > > > uretprobe-push : 2.090 ± 0.000M/s
> > > > uretprobe-ret : 0.942 ± 0.000M/s
> > > > --> uretprobe-nop10: 3.381 ± 0.003M/s
> > > > usdt-nop : 3.245 ± 0.004M/s
> > > > --> usdt-nop10 : 7.256 ± 0.023M/s
> > > >
> > > > [1] https://lore.kernel.org/bpf/20260509003146.976844-1-andrii@kernel.org/
> > > > [2] https://lore.kernel.org/bpf/20260518104306.GU3102624@noisy.programming.kicks-ass.net/#t
> > > > Reported-by: Andrii Nakryiko <andrii@kernel.org>
> > > > Closes: https://lore.kernel.org/bpf/20260509003146.976844-1-andrii@kernel.org/
> > > > Fixes: ba2bfc97b462 ("uprobes/x86: Add support to optimize uprobes")
> > > > Assisted-by: Codex:GPT-5.5
> > > > Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> > > > ---
> > > > arch/x86/kernel/uprobes.c | 255 ++++++++++++++++++++++++++++----------
> > > > 1 file changed, 190 insertions(+), 65 deletions(-)
> > > >
> > >
> > > [...]
> > >
> > > > @@ -943,13 +1026,31 @@ static int int3_update(struct arch_uprobe *auprobe, struct vm_area_struct *vma,
> > > > smp_text_poke_sync_each_cpu();
> > > >
> > > > /*
> > > > - * Write first byte.
> > > > + * 3) Restore bytes 1..4 of the original NOP while keeping byte 0 trapped
> > > > + * and byte 5 as CALL:
> > > > + * cc [2e 0f 1f 84] e8 d0 d1 d2 d3
> > > > + */
> > > > + ctx.expect = EXPECT_SWBP_OPTIMIZED;
> > > > + err = uprobe_write(auprobe, vma, vaddr + 1, insn + 1,
> > > > + LEA_INSN_SIZE - 1, verify_insn,
> > > > + true /* is_register */, false /* do_update_ref_ctr */,
> > >
> > > tbh, it's quite subtle and non-obvious why is_register should be set
> > > to true first two times (and especially that is_register and
> > > do_update_ref_ctr are implicitly connected), not sure how to make it
> > > cleaner, but maybe leave a short comment explaining this twice
> > > register, once unregister sequence?
> >
> > ok, I came up with comment below
> >
> > thanks,
> > jirka
> >
> >
> > ---
> > diff --git a/arch/x86/kernel/uprobes.c b/arch/x86/kernel/uprobes.c
> > index de544516ea70..92449f34c005 100644
> > --- a/arch/x86/kernel/uprobes.c
> > +++ b/arch/x86/kernel/uprobes.c
> > @@ -1011,6 +1011,12 @@ static int int3_update_unoptimize(struct arch_uprobe *auprobe, struct vm_area_st
> > int err;
> >
> > /*
> > + * Note the first two uprobe_write calls use is_register=true, because they
> > + * are intermediate patching states while the probe is still active.
>
> this doesn't really explain why is_register=true is the right one. It
> actually doesn't matter as long as do_update_ref_ctr=true, isn't that
> right? So maybe just to avoid a bit of confusion let's pass
> is_register=false and do_update_ref_ctr=false, and in the comment
> explain as you said that it's intermediate update and we don't want to
> update refctr just yet until the very last step?
apart from refctr update there's also different way the concerned
page is managed, IIUC:
with is_register=true we force to get exclusive anonymous page for
the update (or pin the existing one)
with is_register=false we try to zap the private anonymous page and
return the mapping to the original page
there are several comments on this in uprobe_write/__uprobe_write
how about the update below
jirka
---
diff --git a/arch/x86/kernel/uprobes.c b/arch/x86/kernel/uprobes.c
index de544516ea70..09f5ff71227c 100644
--- a/arch/x86/kernel/uprobes.c
+++ b/arch/x86/kernel/uprobes.c
@@ -1011,6 +1011,16 @@ static int int3_update_unoptimize(struct arch_uprobe *auprobe, struct vm_area_st
int err;
/*
+ * Note the first two uprobe_write calls use is_register=true, because they
+ * are intermediate patching states while the probe is still active, so
+ * we force the exclusive anonymous page for the update.
+ * Also we use do_update_ref_ctr=false because refctr was already updated by
+ * the initial int3 install.
+ *
+ * The last uprobe_write to nop10 instruction is called with is_register=false
+ * and do_update_ref_ctr=true to trigger the refctr update and to instruct
+ * uprobe_write to zap the anonymous page if it now matches the file page.
+ *
* 1) Initial optimized state:
* 48 8d 64 24 80 e8 d0 d1 d2 d3
*
^ permalink raw reply related
* Re: [PATCH v3] rethook: Remove the running task check in rethook_find_ret_addr()
From: Masami Hiramatsu @ 2026-06-10 8:29 UTC (permalink / raw)
To: Tengda Wu
Cc: Petr Mladek, Masami Hiramatsu, Peter Zijlstra, Steven Rostedt,
Mathieu Desnoyers, Alexei Starovoitov, linux-trace-kernel,
linux-kernel, live-patching
In-Reply-To: <e016536c-df99-4de8-a8fb-6ac50932fd2f@huaweicloud.com>
On Tue, 9 Jun 2026 19:12:41 +0800
Tengda Wu <wutengda@huaweicloud.com> wrote:
>
>
> On 2026/6/9 17:43, Petr Mladek wrote:
> > Added live-patching mailing list.
> >
> > On Tue 2026-06-09 16:49:53, Tengda Wu wrote:
> >> The current check in rethook_find_ret_addr() prevents obtaining a return
> >> address when the target task is marked as running. However, this condition
> >> is both insufficient for correctness and unnecessary for its intended
> >> purpose.
> >>
> >> The check is inherently racy: a task can begin running on another CPU
> >> immediately after task_is_running() returns false, potentially leading to
> >> concurrent modification of rethook data structures while the iteration is
> >> in progress.
> >>
> >> Rather than trying to fix this unreliable check deep in the unwinding
> >> path, simply remove it. The iteration is already safe from crashes because
> >> unwind_next_frame() holds RCU and rethook_node structures are RCU-freed;
> >> even if the iteration goes off the rails and returns invalid information,
> >> it will not crash. Callers that require consistency must provide a safe
> >> context themselves.
> >>
> >> Fixes: 54ecbe6f1ed5 ("rethook: Add a generic return hook")
> >> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
> >> Signed-off-by: Tengda Wu <wutengda@huaweicloud.com>
> >> ---
> >> v3: Improve commit message: clarify safety semantics and document that RCU guarantees no crash.
> >> v2: https://lore.kernel.org/all/20260609005728.458962-1-wutengda@huaweicloud.com/
> >> v1: https://lore.kernel.org/all/20260525132253.1889726-1-wutengda@huaweicloud.com/
> >>
> >> --- a/kernel/trace/rethook.c
> >> +++ b/kernel/trace/rethook.c
> >> @@ -250,9 +250,6 @@ unsigned long rethook_find_ret_addr(struct task_struct *tsk, unsigned long frame
> >> if (WARN_ON_ONCE(!cur))
> >> return 0;
> >>
> >> - if (tsk != current && task_is_running(tsk))
> >> - return 0;
> >> -
> >
> > The description of the function should be updated as well. It still
> > mentions:
> >
> > * The @tsk must be 'current' or a task which is not running.
> >
> > Instead it should explain that it safe to call the function even
> > on another running tasks but the returned address is not reliable
> > then.
> >
>
> Oh, I forgot that. Thanks for pointing it out.
Yeah, but it should be updated to explain what you need to do.
For example call it should hold RCU, or use for current.
Thanks,
--
Masami Hiramatsu (Google) <mhiramat@kernel.org>
^ permalink raw reply
* Re: [PATCH] tracing: fprobe: Remove __packed from generic __fprobe_header
From: Markus Schneider-Pargmann @ 2026-06-10 9:20 UTC (permalink / raw)
To: Masami Hiramatsu, Markus Schneider-Pargmann (The Capable Hub)
Cc: Steven Rostedt, Mathieu Desnoyers, Heiko Carstens, linux-kernel,
linux-trace-kernel
In-Reply-To: <20260610171740.c30c43c5faee0beac3ad7546@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 1560 bytes --]
Hi Masami,
On Wed Jun 10, 2026 at 10:17 AM CEST, Masami Hiramatsu wrote:
> Hi Markus,
>
> Thanks for ping me.
>
> On Tue, 28 Apr 2026 10:30:29 +0200
> "Markus Schneider-Pargmann (The Capable Hub)" <msp@baylibre.com> wrote:
>
>> fp pointer and unsigned long have the same size on all relevant
>> architectures that build Linux. Furthermore this struct is only used in
>> architectures that do not set ARCH_DEFINE_ENCODE_FPROBE_HEADER which is
>> set only for 64bit architectures (apart from LoongArch).
>>
>> Both fields are aligned on these architectures so the struct with
>> __packed and without it are the same.
>>
>> Remove the __packed as it is unnecessary.
>>
>> Fixes: 4346ba160409 ("fprobe: Rewrite fprobe on function-graph tracer")
>
> NOTE: This is not a Fix, but just cleanup or minor update. Or, you have
> any problem with this __packed attribute?
Thanks, yes it is not fixing a bug, I can remove this.
>
> Unless there is no problem (or any concern), I would like to keep this
> as it is.
There is currently no problem with __packed in the upstream kernel. I
just thought this would be a good cleanup to remove the unnecessary
attribute. I am working on CHERI architectures where pointers have
capabilities. __packed breaks these capability tags and therefore
doesn't work on CHERI. When looking into why this struct has a __packed
attribute I didn't see a reason, so I thought this would be a good patch
for upstream as well even though CHERI is not yet relevant for upstream
linux.
Best
Markus
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 289 bytes --]
^ permalink raw reply
* Re: [PATCH v9 2/6] mm/memory-failure: surface unhandlable kernel pages as -ENOTRECOVERABLE
From: Breno Leitao @ 2026-06-10 9:53 UTC (permalink / raw)
To: David Hildenbrand (Arm)
Cc: Miaohe Lin, Andrew Morton, Lorenzo Stoakes, Vlastimil Babka,
Mike Rapoport, Suren Baghdasaryan, Michal Hocko, Shuah Khan,
Naoya Horiguchi, Jonathan Corbet, Shuah Khan, Liam R. Howlett,
lance.yang, Steven Rostedt, Masami Hiramatsu, Mathieu Desnoyers,
linux-mm, linux-kernel, linux-doc, linux-kselftest,
linux-trace-kernel, kernel-team
In-Reply-To: <cf2bb24e-9341-4ded-b238-064dca442a92@kernel.org>
On Tue, Jun 09, 2026 at 08:41:25PM +0200, David Hildenbrand (Arm) wrote:
> On 6/9/26 18:15, Breno Leitao wrote:
> > On Tue, Jun 09, 2026 at 04:41:01PM +0200, David Hildenbrand (Arm) wrote:
> >> a) HWPoisonKernelOwned: this is not the common style for us to name functions.
> >>
> >> is_kernel_owned_page() or sth like that would do.
> >
> > Ack, I will rename it is_kernel_owned_page()
> >
> > In my defence, most of the functions similar to HWPoisonKernelOwned()
> > has this name format, and I got this discussion earlier (with Lance?
> > I think). Here are the similar function names in that file:
> >
> > * HWPoisonHandlable
> > * PageHWPoisonTakenOff()
> > * SetPageHWPoisonTakenOff
>
> Some of these probably date back to our old way of handling page flags and
> things, like PageLRU.
>
> But we really should stop :)
Ack!
> > I will update in the new version.
>
> Thanks! Probably best to wait a bit, the merge window is coming up either way,
> so this will have to wait a bit either way.
no hurry at all,
Thanks for the review,
--breno
^ permalink raw reply
* Re: [LSF/MM/BPF TOPIC][RFC PATCH v4 00/27] Private Memory Nodes (w/ Compressed RAM)
From: Gregory Price @ 2026-06-10 10:41 UTC (permalink / raw)
To: Balbir Singh
Cc: lsf-pc, linux-kernel, linux-cxl, cgroups, linux-mm,
linux-trace-kernel, damon, kernel-team, gregkh, rafael, dakr,
dave, jonathan.cameron, dave.jiang, alison.schofield,
vishal.l.verma, ira.weiny, dan.j.williams, longman, akpm, david,
lorenzo.stoakes, Liam.Howlett, vbabka, rppt, surenb, mhocko,
osalvador, ziy, matthew.brost, joshua.hahnjy, rakie.kim,
byungchul, ying.huang, apopple, axelrasmussen, yuanchu, weixugc,
yury.norov, linux, mhiramat, mathieu.desnoyers, tj, hannes,
mkoutny, jackmanb, sj, baolin.wang, npache, ryan.roberts,
dev.jain, baohua, lance.yang, muchun.song, xu.xin16,
chengming.zhou, jannh, linmiaohe, nao.horiguchi, pfalcato,
rientjes, shakeel.butt, riel, harry.yoo, cl, roman.gushchin,
chrisl, kasong, shikemeng, nphamcs, bhe, zhengqi.arch,
terry.bowman
In-Reply-To: <ah-0CyZurn5D1ezY@parvat>
On Wed, Jun 03, 2026 at 03:00:01PM +1000, Balbir Singh wrote:
> >
> > __GFP_THISNODE cannot be overloaded to do anything useful here.
>
> Let me clarify, I meant to say, let's use a nodemask for allocation
> and __GFP_THISNODE gets us to the node we desire, if that is the only
> node. My earlier comment might not have been clear.
>
I've been tested an stripped back patch set where I drop all FALLBACK
entries for private nodes (including for itself) and only keep the
NOFALLBACK entry for private nodes.
This effectively isolates the nodes for any allocation without
__GFP_THISNODE.
This also precludes these nodes from ever using non-mbind mempolicies,
which I think is a completely reasonable compromise and something I was
already expecting we would do.
Notably: slub.c injects __GFP_THISNODE internally on behalf of kmalloc,
which causes spillage into private nodes because slub allows private
nodes in its mask. I think this is fixable.
I have to inspect some other __GFP_THISNODE users (hugetlb, some arch
code, etc), but it seems like fully dropping the FALLBACK entries and
requiring __GFP_THISNODE might be sufficient.
~Gregory
^ permalink raw reply
* Re: [PATCH] tracing: fprobe: Remove __packed from generic __fprobe_header
From: David Laight @ 2026-06-10 11:06 UTC (permalink / raw)
To: Masami Hiramatsu (Google)
Cc: Markus Schneider-Pargmann (The Capable Hub), Steven Rostedt,
Mathieu Desnoyers, Heiko Carstens, linux-kernel,
linux-trace-kernel
In-Reply-To: <20260610171740.c30c43c5faee0beac3ad7546@kernel.org>
On Wed, 10 Jun 2026 17:17:40 +0900
Masami Hiramatsu (Google) <mhiramat@kernel.org> wrote:
> Hi Markus,
>
> Thanks for ping me.
>
> On Tue, 28 Apr 2026 10:30:29 +0200
> "Markus Schneider-Pargmann (The Capable Hub)" <msp@baylibre.com> wrote:
>
> > fp pointer and unsigned long have the same size on all relevant
> > architectures that build Linux. Furthermore this struct is only used in
> > architectures that do not set ARCH_DEFINE_ENCODE_FPROBE_HEADER which is
> > set only for 64bit architectures (apart from LoongArch).
> >
> > Both fields are aligned on these architectures so the struct with
> > __packed and without it are the same.
> >
> > Remove the __packed as it is unnecessary.
> >
> > Fixes: 4346ba160409 ("fprobe: Rewrite fprobe on function-graph tracer")
>
> NOTE: This is not a Fix, but just cleanup or minor update. Or, you have
> any problem with this __packed attribute?
>
> Unless there is no problem (or any concern), I would like to keep this
> as it is.
There is likely to be a difference on architectures that fault misaligned
accesses.
On those gcc will use multiple byte-sized accesses (and a log of shifts etc)
for code that accesses those members because it will assume that the
structure itself can be misaligned.
So you only want __packed on structures that might be misaligned and those
that contain misaligned members.
If the structure is only guaranteed to be 32bit aligned then use __packed
__aligned(4) so that two 32bit accesses get used instead of 8 8bit ones.
-- David
>
> Thank you,
>
> > Signed-off-by: Markus Schneider-Pargmann (The Capable Hub) <msp@baylibre.com>
> > ---
> > kernel/trace/fprobe.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/kernel/trace/fprobe.c b/kernel/trace/fprobe.c
> > index cc49ebd2a773..21751dcdb7b9 100644
> > --- a/kernel/trace/fprobe.c
> > +++ b/kernel/trace/fprobe.c
> > @@ -181,7 +181,7 @@ static inline void read_fprobe_header(unsigned long *stack,
> > struct __fprobe_header {
> > struct fprobe *fp;
> > unsigned long size_words;
> > -} __packed;
> > +};
> >
> > #define FPROBE_HEADER_SIZE_IN_LONG SIZE_IN_LONG(sizeof(struct __fprobe_header))
> >
> >
> > ---
> > base-commit: 254f49634ee16a731174d2ae34bc50bd5f45e731
> > change-id: 20260427-topic-fprobe-packed-v7-1-f44f9bbdedf6
> >
> > Best regards,
> > --
> > Markus Schneider-Pargmann (The Capable Hub) <msp@baylibre.com>
> >
>
>
^ permalink raw reply
* Re: [PATCH] rtla/tests: Fix pgrep filter in get_workload_pids.sh
From: Wander Lairson Costa @ 2026-06-10 12:52 UTC (permalink / raw)
To: Tomas Glozar
Cc: Steven Rostedt, John Kacur, Luis Goncalves, Crystal Wood,
Costa Shulyupin, LKML, linux-trace-kernel
In-Reply-To: <20260604140547.3616495-1-tglozar@redhat.com>
On Thu, Jun 04, 2026 at 04:05:47PM +0200, Tomas Glozar wrote:
> Multiple runtime tests in RTLA rely on the get_workload_pids() shell
> helper function to get the PIDs of both kernel and user workloads.
>
> On some systems (e.g. Fedora 43), pgrep matches kernel thread names
> including square brackets: "[osnoise/0]"; on other systems (e.g.
> RHEL 9.8), brackets are not included: "osnoise/0".
>
> Accept both as valid workload PIDs rather that just the non-bracket form
> to make the tests work on all systems.
>
> Fixes: a98dad63cda3 ("rtla/tests: Add runtime test for -k and -u options")
> Reported-by: Crystal Wood <crwood@redhat.com>
> Signed-off-by: Tomas Glozar <tglozar@redhat.com>
> ---
>
> Note: the file touched by this commit is included by .gitignore, that is
> an error that will be fixed by [1].
>
> [1] https://lore.kernel.org/linux-trace-kernel/20260601091835.3118094-1-tglozar@redhat.com/
>
Reviewed-by: Wander Lairson Costa <wander@redhat.com>
^ permalink raw reply
* [RFC PATCH 1/2] tracing/osnoise: Sample IPI counts
From: Valentin Schneider @ 2026-06-10 13:04 UTC (permalink / raw)
To: linux-kernel, linux-trace-kernel
Cc: Steven Rostedt, Masami Hiramatsu, Mathieu Desnoyers, Tomas Glozar,
Costa Shulyupin, Crystal Wood, Ivan Pravdin
In-Reply-To: <20260610130457.1304245-1-vschneid@redhat.com>
Osnoise already implictly accounts IPIs via its IRQ tracking, however it
can be interesting to distiguish between the two: undesired IPIs usually
imply a software configuration issue (e.g. wrong/incomplete CPU isolation)
whereas undesired (non-IPI) IRQs usually imply a hardware configuration
issue.
Signed-off-by: Valentin Schneider <vschneid@redhat.com>
---
Note that this is modifying the osnoise:osnoise_entry Ftrace entry; I know
trace events are sort of supposed to be stable, but I'm not sure about
ftrace entries.
Alternatively I can have this be purely supported in userspace osnoise by
hooking into the IPI events and counting IPIs separately from the osnoise
events.
---
include/trace/events/osnoise.h | 1 +
kernel/trace/trace_entries.h | 6 ++-
kernel/trace/trace_osnoise.c | 80 ++++++++++++++++++++++++++++++++--
3 files changed, 81 insertions(+), 6 deletions(-)
diff --git a/include/trace/events/osnoise.h b/include/trace/events/osnoise.h
index 3f42736238014..58442e58fe652 100644
--- a/include/trace/events/osnoise.h
+++ b/include/trace/events/osnoise.h
@@ -19,6 +19,7 @@ struct osnoise_sample {
int irq_count; /* # IRQs during this sample */
int softirq_count; /* # softirqs during this sample */
int thread_count; /* # threads during this sample */
+ int ipi_count; /* # IPIs during this sample */
};
#ifdef CONFIG_TIMERLAT_TRACER
diff --git a/kernel/trace/trace_entries.h b/kernel/trace/trace_entries.h
index 54417468fdeb1..aed778d859d37 100644
--- a/kernel/trace/trace_entries.h
+++ b/kernel/trace/trace_entries.h
@@ -430,16 +430,18 @@ FTRACE_ENTRY(osnoise, osnoise_entry,
__field( unsigned int, irq_count )
__field( unsigned int, softirq_count )
__field( unsigned int, thread_count )
+ __field( unsigned int, ipi_count )
),
- F_printk("noise:%llu\tmax_sample:%llu\thw:%u\tnmi:%u\tirq:%u\tsoftirq:%u\tthread:%u\n",
+ F_printk("noise:%llu\tmax_sample:%llu\thw:%u\tnmi:%u\tirq:%u\tsoftirq:%u\tthread:%u\tipi:%u\n",
__entry->noise,
__entry->max_sample,
__entry->hw_count,
__entry->nmi_count,
__entry->irq_count,
__entry->softirq_count,
- __entry->thread_count)
+ __entry->thread_count,
+ __entry->ipi_count)
);
FTRACE_ENTRY(timerlat, timerlat_entry,
diff --git a/kernel/trace/trace_osnoise.c b/kernel/trace/trace_osnoise.c
index 75678053b21c5..574629a6b22b3 100644
--- a/kernel/trace/trace_osnoise.c
+++ b/kernel/trace/trace_osnoise.c
@@ -35,6 +35,7 @@
#include <trace/events/irq.h>
#include <trace/events/sched.h>
+#include <trace/events/ipi.h>
#define CREATE_TRACE_POINTS
#include <trace/events/osnoise.h>
@@ -83,6 +84,10 @@ struct osnoise_instance {
static struct list_head osnoise_instances;
+static struct cpumask osnoise_cpumask;
+static struct cpumask save_cpumask;
+static struct cpumask kthread_cpumask;
+
static bool osnoise_has_registered_instances(void)
{
return !!list_first_or_null_rcu(&osnoise_instances,
@@ -203,6 +208,11 @@ struct osn_thread {
u64 delta_start;
};
+/* IPI runtime info */
+struct osn_ipi {
+ u64 count;
+};
+
/*
* Runtime information: this structure saves the runtime information used by
* one sampling thread.
@@ -215,6 +225,7 @@ struct osnoise_variables {
struct osn_irq irq;
struct osn_softirq softirq;
struct osn_thread thread;
+ struct osn_ipi ipi;
local_t int_counter;
};
@@ -505,6 +516,7 @@ __record_osnoise_sample(struct osnoise_sample *sample, struct trace_buffer *buff
entry->irq_count = sample->irq_count;
entry->softirq_count = sample->softirq_count;
entry->thread_count = sample->thread_count;
+ entry->ipi_count = sample->ipi_count;
trace_buffer_unlock_commit_nostack(buffer, event);
}
@@ -1288,6 +1300,7 @@ trace_sched_switch_callback(void *data, bool preempt,
* Hook the osnoise tracer callbacks to handle the noise from other
* threads on the necessary kernel events.
*/
+
static int hook_thread_events(void)
{
int ret;
@@ -1319,6 +1332,60 @@ static void unhook_thread_events(void)
unregister_migration_monitor();
}
+static void ipi_emission(struct osnoise_variables *osn_var, unsigned int dst_cpu)
+{
+ if (!osn_var->sampling)
+ return;
+
+ osn_var->ipi.count++;
+}
+
+static void trace_ipi_send_cpu_callback(void *data, unsigned int cpu,
+ unsigned long callsite, void *callback)
+{
+ struct osnoise_variables *osn_var;
+
+ osn_var = per_cpu_ptr(&per_cpu_osnoise_var, cpu);
+ ipi_emission(osn_var, cpu);
+}
+
+static void trace_ipi_send_cpumask_callback(void *data, const struct cpumask *cpumask,
+ unsigned long callsite, void *callback)
+{
+ struct osnoise_variables *osn_var;
+ int cpu;
+
+ for_each_cpu_and(cpu, cpumask, &osnoise_cpumask) {
+ osn_var = per_cpu_ptr(&per_cpu_osnoise_var, cpu);
+ ipi_emission(osn_var, cpu);
+ }
+}
+
+static int hook_ipi_events(void)
+{
+ int ret;
+
+ ret = register_trace_ipi_send_cpu(trace_ipi_send_cpu_callback, NULL);
+ if (ret)
+ return -EINVAL;
+
+ ret = register_trace_ipi_send_cpumask(trace_ipi_send_cpumask_callback, NULL);
+ if (ret)
+ goto out_unreg;
+
+ return 0;
+
+out_unreg:
+ unregister_trace_ipi_send_cpu(trace_ipi_send_cpu_callback, NULL);
+ return -EINVAL;
+}
+
+static void unhook_ipi_events(void)
+{
+ unregister_trace_ipi_send_cpu(trace_ipi_send_cpu_callback, NULL);
+ unregister_trace_ipi_send_cpumask(trace_ipi_send_cpumask_callback, NULL);
+}
+
/*
* save_osn_sample_stats - Save the osnoise_sample statistics
*
@@ -1333,6 +1400,7 @@ save_osn_sample_stats(struct osnoise_variables *osn_var, struct osnoise_sample *
s->irq_count = osn_var->irq.count;
s->softirq_count = osn_var->softirq.count;
s->thread_count = osn_var->thread.count;
+ s->ipi_count = osn_var->ipi.count;
}
/*
@@ -1349,6 +1417,7 @@ diff_osn_sample_stats(struct osnoise_variables *osn_var, struct osnoise_sample *
s->irq_count = osn_var->irq.count - s->irq_count;
s->softirq_count = osn_var->softirq.count - s->softirq_count;
s->thread_count = osn_var->thread.count - s->thread_count;
+ s->ipi_count = osn_var->ipi.count - s->ipi_count;
}
/*
@@ -1613,10 +1682,6 @@ static int run_osnoise(void)
return ret;
}
-static struct cpumask osnoise_cpumask;
-static struct cpumask save_cpumask;
-static struct cpumask kthread_cpumask;
-
/*
* osnoise_sleep - sleep until the next period
*/
@@ -2892,12 +2957,18 @@ static int osnoise_hook_events(void)
goto out_unhook_irq;
retval = hook_thread_events();
+ if (retval)
+ goto out_unhook_softirq;
+
+ retval = hook_ipi_events();
/*
* All fine!
*/
if (!retval)
return 0;
+ unhook_thread_events();
+out_unhook_softirq:
unhook_softirq_events();
out_unhook_irq:
unhook_irq_events();
@@ -2906,6 +2977,7 @@ static int osnoise_hook_events(void)
static void osnoise_unhook_events(void)
{
+ unhook_ipi_events();
unhook_thread_events();
unhook_softirq_events();
unhook_irq_events();
--
2.54.0
^ permalink raw reply related
* [RFC PATCH 0/2] tracing/osnoise: Track IPIs
From: Valentin Schneider @ 2026-06-10 13:04 UTC (permalink / raw)
To: linux-kernel, linux-trace-kernel
Cc: Steven Rostedt, Masami Hiramatsu, Mathieu Desnoyers, Tomas Glozar,
Costa Shulyupin, Crystal Wood, Ivan Pravdin
Hi folks,
So I've seen a few times now reports of latency spikes caused by IPIs, usually
because of isolation misconfiguration, but only detected at the tail of end
e.g. a 24h timerlat run.
It's not because those IPIs are rare, but rather that they don't by themselves
cause a monitered CPU to reach the latency threshold, it's usually a combined
interference that gets us there.
I'd like to make it easier to detect such misconfigurations and thus IPIs
hitting supposedly-isolated CPUs. I initially kludged a timerlat option to stop
tracing as soon as an IPI was sent to a monitored CPU, regardless of the latency
threshold. It sort of did the trick, but Tomáš convinced me timerlat wasn't
really the place for that.
So here's IPI tracking added to osnoise. Two things worth pointing out:
o This only adds IPI count tracking, nothing about noise duration - this is
already tracked as part of the IRQ noise.
o This modifies the osnoise Ftrace entry, I have no idea how acceptable this is,
although the only real consumer of these should be rtla...
Tested with:
$ rtla osnoise top -d 5s
$ trace-cmd record -p osnoise hackbench -l 10000
Cheers,
Valentin
Valentin Schneider (2):
tracing/osnoise: Sample IPI counts
rtla/osnoise: Report IPI count in osnoise top
include/trace/events/osnoise.h | 1 +
kernel/trace/trace_entries.h | 6 ++-
kernel/trace/trace_osnoise.c | 80 ++++++++++++++++++++++++++--
tools/tracing/rtla/src/osnoise_top.c | 9 +++-
4 files changed, 88 insertions(+), 8 deletions(-)
--
2.54.0
^ permalink raw reply
* [RFC PATCH 2/2] rtla/osnoise: Report IPI count in osnoise top
From: Valentin Schneider @ 2026-06-10 13:04 UTC (permalink / raw)
To: linux-kernel, linux-trace-kernel
Cc: Steven Rostedt, Masami Hiramatsu, Mathieu Desnoyers, Tomas Glozar,
Costa Shulyupin, Crystal Wood, Ivan Pravdin
In-Reply-To: <20260610130457.1304245-1-vschneid@redhat.com>
The osnoise tracer now also reports IPI count, extract & report them.
Signed-off-by: Valentin Schneider <vschneid@redhat.com>
---
tools/tracing/rtla/src/osnoise_top.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/tools/tracing/rtla/src/osnoise_top.c b/tools/tracing/rtla/src/osnoise_top.c
index e65312ec26c43..6fd5353c82f38 100644
--- a/tools/tracing/rtla/src/osnoise_top.c
+++ b/tools/tracing/rtla/src/osnoise_top.c
@@ -25,6 +25,7 @@ struct osnoise_top_cpu {
unsigned long long irq_count;
unsigned long long softirq_count;
unsigned long long thread_count;
+ unsigned long long ipi_count;
int sum_cycles;
};
@@ -116,6 +117,9 @@ osnoise_top_handler(struct trace_seq *s, struct tep_record *record,
tep_get_field_val(s, event, "thread_count", record, &val, 1);
update_sum(&cpu_data->thread_count, &val);
+ tep_get_field_val(s, event, "ipi_count", record, &val, 1);
+ update_sum(&cpu_data->ipi_count, &val);
+
return 0;
}
@@ -163,7 +167,7 @@ static void osnoise_top_header(struct osnoise_tool *top)
if (params->mode == MODE_HWNOISE)
goto eol;
- trace_seq_printf(s, " IRQ Softirq Thread");
+ trace_seq_printf(s, " IRQ Softirq Thread IPI");
eol:
if (pretty)
@@ -218,7 +222,8 @@ static void osnoise_top_print(struct osnoise_tool *tool, int cpu)
trace_seq_printf(s, "%12llu ", cpu_data->irq_count);
trace_seq_printf(s, "%12llu ", cpu_data->softirq_count);
- trace_seq_printf(s, "%12llu\n", cpu_data->thread_count);
+ trace_seq_printf(s, "%12llu ", cpu_data->thread_count);
+ trace_seq_printf(s, "%12llu\n", cpu_data->ipi_count);
}
/*
--
2.54.0
^ permalink raw reply related
* Re: [PATCH v4 3/7] bootconfig: render embedded bootconfig as a kernel cmdline at build time
From: Julian Braha @ 2026-06-10 13:44 UTC (permalink / raw)
To: Breno Leitao, Masami Hiramatsu, Andrew Morton, Nathan Chancellor,
paulmck, Nicolas Schier
Cc: Thomas Gleixner, Ingo Molnar, Borislav Petkov, Dave Hansen, x86,
H. Peter Anvin, linux-kernel, linux-trace-kernel, linux-kbuild,
bpf, kernel-team
In-Reply-To: <20260609-bootconfig_using_tools-v4-3-73c463f03a97@debian.org>
On 6/9/26 11:28, Breno Leitao wrote:
> + depends on BOOT_CONFIG_EMBED
> + depends on BOOT_CONFIG_EMBED_FILE != ""
Hi Breno,
Just an FYI, this dependency on BOOT_CONFIG_EMBED is redundant because
the:
BOOT_CONFIG_EMBED_FILE != ""
is only possible when BOOT_CONFIG_EMBED is enabled.
- Julian Braha
^ permalink raw reply
* [PATCH v2 0/9] v4l2: Add tracing for stateless codecs
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
Hi !
This patchset aims to improve codec event tracing in v4l2.
The traces added in visl by Daniel Almeida are moved to the global trace
events.
They are adapted to trace each each field separately and not just the
whole struct so that userspace can filter on different fields and
libraries like libtracefs and libtraceevent can be used to list the
fields instead of parsing the trace printk's.
The trace event templates are also reworked to avoid long lines, but
quoted string splits are kept as they don't cut words.
To each trace event are also added a tgid and fd fields, helping
userspace track different decoding sessions (contexts) based on the given
file descriptor used by the given process id.
Also for better tracking, stream on and stream off events are added as
well as HW run and HW done events to track decoder core usage.
The main focus is to be able to generate perfetto traces to show VPU usage,
a perfetto producer using this can be found at [1] (it will be renamed to
match the more generic approach than hantro).
Other controls can be traced later as well, this patch set only focuses on
mem2mem type drivers.
[1]:
https://gitlab.collabora.com/detlev/hantro-perf/-/tree/hantro-improved-info
Changes since v1:
- Don't modify the printk format
- Trace all fields of the structs instead of the whole struct as a buffer
- Remove fdinfo patches (they will come in another patch set)
- Fix long lines
- Rename v4l2_requests.h trace header to v4l2_controls.h
- Add basic documentation
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
---
Detlev Casanova (9):
media: Move visl traces to v4l2-core
media: Map each struct field to its own trace field
media: Add tgid and fd fields in v4l2_fh struct
media: Add tgid and fd to the v4l2-requests trace fields
media: Add missing types to v4l2_ctrl_ptr
media: Trace the stateless controls when set in v4l2-ctrls-core.c
media: Add stream on/off traces and run them in the ioctl
media: Add HW run/done trace events
media: hantro: Add v4l2_hw run/done traces
drivers/media/platform/verisilicon/hantro.h | 1 +
drivers/media/platform/verisilicon/hantro_drv.c | 10 +
.../platform/verisilicon/rockchip_vpu981_regs.h | 1 +
.../media/platform/verisilicon/rockchip_vpu_hw.c | 4 +
drivers/media/test-drivers/visl/Makefile | 2 +-
drivers/media/test-drivers/visl/visl-dec.c | 76 -
drivers/media/test-drivers/visl/visl-trace-av1.h | 314 ---
drivers/media/test-drivers/visl/visl-trace-fwht.h | 66 -
drivers/media/test-drivers/visl/visl-trace-h264.h | 349 ---
drivers/media/test-drivers/visl/visl-trace-hevc.h | 464 ----
drivers/media/test-drivers/visl/visl-trace-mpeg2.h | 99 -
.../media/test-drivers/visl/visl-trace-points.c | 11 -
drivers/media/test-drivers/visl/visl-trace-vp8.h | 156 --
drivers/media/test-drivers/visl/visl-trace-vp9.h | 292 ---
drivers/media/v4l2-core/v4l2-ctrls-api.c | 10 +
drivers/media/v4l2-core/v4l2-ctrls-core.c | 114 +
drivers/media/v4l2-core/v4l2-fh.c | 1 +
drivers/media/v4l2-core/v4l2-ioctl.c | 37 +-
drivers/media/v4l2-core/v4l2-trace.c | 48 +
include/media/v4l2-ctrls.h | 19 +
include/media/v4l2-fh.h | 4 +
include/trace/events/v4l2.h | 77 +
include/trace/events/v4l2_controls.h | 2708 ++++++++++++++++++++
23 files changed, 3033 insertions(+), 1830 deletions(-)
---
base-commit: acb7500801e98639f6d8c2d796ed9f64cba83d3a
change-id: 20260608-v4l2-add-ftrace-aec6e7f60a6c
Best regards,
--
Detlev Casanova <detlev.casanova@collabora.com>
^ permalink raw reply
* [PATCH v2 1/9] media: Move visl traces to v4l2-core
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
The visl driver defines traces for all stateless controls.
Move those definition to a new v4l2_requests.h file and expose them for
all drivers to use.
As each event can be enabled individually in userspace, group them all in
the same v4l2_requests event folder.
Later, it can also be used by v4l2-core to trace controls as they are
being set.
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
---
drivers/media/test-drivers/visl/Makefile | 2 +-
drivers/media/test-drivers/visl/visl-dec.c | 8 +-
drivers/media/test-drivers/visl/visl-trace-av1.h | 314 ----
drivers/media/test-drivers/visl/visl-trace-fwht.h | 66 -
drivers/media/test-drivers/visl/visl-trace-h264.h | 349 -----
drivers/media/test-drivers/visl/visl-trace-hevc.h | 464 ------
drivers/media/test-drivers/visl/visl-trace-mpeg2.h | 99 --
.../media/test-drivers/visl/visl-trace-points.c | 11 -
drivers/media/test-drivers/visl/visl-trace-vp8.h | 156 --
drivers/media/test-drivers/visl/visl-trace-vp9.h | 292 ----
drivers/media/v4l2-core/v4l2-trace.c | 45 +
include/trace/events/v4l2_controls.h | 1645 ++++++++++++++++++++
12 files changed, 1692 insertions(+), 1759 deletions(-)
diff --git a/drivers/media/test-drivers/visl/Makefile b/drivers/media/test-drivers/visl/Makefile
index fb4d5ae1b17f..a5049e2af844 100644
--- a/drivers/media/test-drivers/visl/Makefile
+++ b/drivers/media/test-drivers/visl/Makefile
@@ -1,5 +1,5 @@
# SPDX-License-Identifier: GPL-2.0+
-visl-y := visl-core.o visl-video.o visl-dec.o visl-trace-points.o
+visl-y := visl-core.o visl-video.o visl-dec.o
ifeq ($(CONFIG_VISL_DEBUGFS),y)
visl-y += visl-debugfs.o
diff --git a/drivers/media/test-drivers/visl/visl-dec.c b/drivers/media/test-drivers/visl/visl-dec.c
index 6bbf93757047..1c66a1b8d78f 100644
--- a/drivers/media/test-drivers/visl/visl-dec.c
+++ b/drivers/media/test-drivers/visl/visl-dec.c
@@ -7,18 +7,12 @@
#include "visl.h"
#include "visl-debugfs.h"
#include "visl-dec.h"
-#include "visl-trace-fwht.h"
-#include "visl-trace-mpeg2.h"
-#include "visl-trace-vp8.h"
-#include "visl-trace-vp9.h"
-#include "visl-trace-h264.h"
-#include "visl-trace-hevc.h"
-#include "visl-trace-av1.h"
#include <linux/delay.h>
#include <linux/workqueue.h>
#include <media/v4l2-mem2mem.h>
#include <media/tpg/v4l2-tpg.h>
+#include <trace/events/v4l2_controls.h>
#define LAST_BUF_IDX (V4L2_AV1_REF_LAST_FRAME - V4L2_AV1_REF_LAST_FRAME)
#define LAST2_BUF_IDX (V4L2_AV1_REF_LAST2_FRAME - V4L2_AV1_REF_LAST_FRAME)
diff --git a/drivers/media/test-drivers/visl/visl-trace-av1.h b/drivers/media/test-drivers/visl/visl-trace-av1.h
deleted file mode 100644
index 09f205de53df..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-av1.h
+++ /dev/null
@@ -1,314 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#if !defined(_VISL_TRACE_AV1_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_AV1_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_av1_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_av1_seq_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_sequence, s)),
- TP_fast_assign(__entry->s = *s;),
- TP_printk("\nflags %s\nseq_profile: %u\norder_hint_bits: %u\nbit_depth: %u\n"
- "max_frame_width_minus_1: %u\nmax_frame_height_minus_1: %u\n",
- __print_flags(__entry->s.flags, "|",
- {V4L2_AV1_SEQUENCE_FLAG_STILL_PICTURE, "STILL_PICTURE"},
- {V4L2_AV1_SEQUENCE_FLAG_USE_128X128_SUPERBLOCK, "USE_128X128_SUPERBLOCK"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_FILTER_INTRA, "ENABLE_FILTER_INTRA"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_INTRA_EDGE_FILTER, "ENABLE_INTRA_EDGE_FILTER"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_INTERINTRA_COMPOUND, "ENABLE_INTERINTRA_COMPOUND"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_MASKED_COMPOUND, "ENABLE_MASKED_COMPOUND"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_WARPED_MOTION, "ENABLE_WARPED_MOTION"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_DUAL_FILTER, "ENABLE_DUAL_FILTER"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_ORDER_HINT, "ENABLE_ORDER_HINT"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_JNT_COMP, "ENABLE_JNT_COMP"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_REF_FRAME_MVS, "ENABLE_REF_FRAME_MVS"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_SUPERRES, "ENABLE_SUPERRES"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_CDEF, "ENABLE_CDEF"},
- {V4L2_AV1_SEQUENCE_FLAG_ENABLE_RESTORATION, "ENABLE_RESTORATION"},
- {V4L2_AV1_SEQUENCE_FLAG_MONO_CHROME, "MONO_CHROME"},
- {V4L2_AV1_SEQUENCE_FLAG_COLOR_RANGE, "COLOR_RANGE"},
- {V4L2_AV1_SEQUENCE_FLAG_SUBSAMPLING_X, "SUBSAMPLING_X"},
- {V4L2_AV1_SEQUENCE_FLAG_SUBSAMPLING_Y, "SUBSAMPLING_Y"},
- {V4L2_AV1_SEQUENCE_FLAG_FILM_GRAIN_PARAMS_PRESENT, "FILM_GRAIN_PARAMS_PRESENT"},
- {V4L2_AV1_SEQUENCE_FLAG_SEPARATE_UV_DELTA_Q, "SEPARATE_UV_DELTA_Q"}),
- __entry->s.seq_profile,
- __entry->s.order_hint_bits,
- __entry->s.bit_depth,
- __entry->s.max_frame_width_minus_1,
- __entry->s.max_frame_height_minus_1
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_av1_tge_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
- TP_ARGS(t),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_tile_group_entry, t)),
- TP_fast_assign(__entry->t = *t;),
- TP_printk("\ntile_offset: %u\n tile_size: %u\n tile_row: %u\ntile_col: %u\n",
- __entry->t.tile_offset,
- __entry->t.tile_size,
- __entry->t.tile_row,
- __entry->t.tile_col
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_frame, f)),
- TP_fast_assign(__entry->f = *f;),
- TP_printk("\ntile_info.flags: %s\ntile_info.context_update_tile_id: %u\n"
- "tile_info.tile_cols: %u\ntile_info.tile_rows: %u\n"
- "tile_info.mi_col_starts: %s\ntile_info.mi_row_starts: %s\n"
- "tile_info.width_in_sbs_minus_1: %s\ntile_info.height_in_sbs_minus_1: %s\n"
- "tile_info.tile_size_bytes: %u\nquantization.flags: %s\n"
- "quantization.base_q_idx: %u\nquantization.delta_q_y_dc: %d\n"
- "quantization.delta_q_u_dc: %d\nquantization.delta_q_u_ac: %d\n"
- "quantization.delta_q_v_dc: %d\nquantization.delta_q_v_ac: %d\n"
- "quantization.qm_y: %u\nquantization.qm_u: %u\nquantization.qm_v: %u\n"
- "quantization.delta_q_res: %u\nsuperres_denom: %u\nsegmentation.flags: %s\n"
- "segmentation.last_active_seg_id: %u\nsegmentation.feature_enabled:%s\n"
- "loop_filter.flags: %s\nloop_filter.level: %s\nloop_filter.sharpness: %u\n"
- "loop_filter.ref_deltas: %s\nloop_filter.mode_deltas: %s\n"
- "loop_filter.delta_lf_res: %u\ncdef.damping_minus_3: %u\ncdef.bits: %u\n"
- "cdef.y_pri_strength: %s\ncdef.y_sec_strength: %s\n"
- "cdef.uv_pri_strength: %s\ncdef.uv_sec_strength:%s\nskip_mode_frame: %s\n"
- "primary_ref_frame: %u\nloop_restoration.flags: %s\n"
- "loop_restoration.lr_unit_shift: %u\nloop_restoration.lr_uv_shift: %u\n"
- "loop_restoration.frame_restoration_type: %s\n"
- "loop_restoration.loop_restoration_size: %s\nflags: %s\norder_hint: %u\n"
- "upscaled_width: %u\nframe_width_minus_1: %u\nframe_height_minus_1: %u\n"
- "render_width_minus_1: %u\nrender_height_minus_1: %u\ncurrent_frame_id: %u\n"
- "buffer_removal_time: %s\norder_hints: %s\nreference_frame_ts: %s\n"
- "ref_frame_idx: %s\nrefresh_frame_flags: %u\n",
- __print_flags(__entry->f.tile_info.flags, "|",
- {V4L2_AV1_TILE_INFO_FLAG_UNIFORM_TILE_SPACING, "UNIFORM_TILE_SPACING"}),
- __entry->f.tile_info.context_update_tile_id,
- __entry->f.tile_info.tile_cols,
- __entry->f.tile_info.tile_rows,
- __print_array(__entry->f.tile_info.mi_col_starts,
- ARRAY_SIZE(__entry->f.tile_info.mi_col_starts),
- sizeof(__entry->f.tile_info.mi_col_starts[0])),
- __print_array(__entry->f.tile_info.mi_row_starts,
- ARRAY_SIZE(__entry->f.tile_info.mi_row_starts),
- sizeof(__entry->f.tile_info.mi_row_starts[0])),
- __print_array(__entry->f.tile_info.width_in_sbs_minus_1,
- ARRAY_SIZE(__entry->f.tile_info.width_in_sbs_minus_1),
- sizeof(__entry->f.tile_info.width_in_sbs_minus_1[0])),
- __print_array(__entry->f.tile_info.height_in_sbs_minus_1,
- ARRAY_SIZE(__entry->f.tile_info.height_in_sbs_minus_1),
- sizeof(__entry->f.tile_info.height_in_sbs_minus_1[0])),
- __entry->f.tile_info.tile_size_bytes,
- __print_flags(__entry->f.quantization.flags, "|",
- {V4L2_AV1_QUANTIZATION_FLAG_DIFF_UV_DELTA, "DIFF_UV_DELTA"},
- {V4L2_AV1_QUANTIZATION_FLAG_USING_QMATRIX, "USING_QMATRIX"},
- {V4L2_AV1_QUANTIZATION_FLAG_DELTA_Q_PRESENT, "DELTA_Q_PRESENT"}),
- __entry->f.quantization.base_q_idx,
- __entry->f.quantization.delta_q_y_dc,
- __entry->f.quantization.delta_q_u_dc,
- __entry->f.quantization.delta_q_u_ac,
- __entry->f.quantization.delta_q_v_dc,
- __entry->f.quantization.delta_q_v_ac,
- __entry->f.quantization.qm_y,
- __entry->f.quantization.qm_u,
- __entry->f.quantization.qm_v,
- __entry->f.quantization.delta_q_res,
- __entry->f.superres_denom,
- __print_flags(__entry->f.segmentation.flags, "|",
- {V4L2_AV1_SEGMENTATION_FLAG_ENABLED, "ENABLED"},
- {V4L2_AV1_SEGMENTATION_FLAG_UPDATE_MAP, "UPDATE_MAP"},
- {V4L2_AV1_SEGMENTATION_FLAG_TEMPORAL_UPDATE, "TEMPORAL_UPDATE"},
- {V4L2_AV1_SEGMENTATION_FLAG_UPDATE_DATA, "UPDATE_DATA"},
- {V4L2_AV1_SEGMENTATION_FLAG_SEG_ID_PRE_SKIP, "SEG_ID_PRE_SKIP"}),
- __entry->f.segmentation.last_active_seg_id,
- __print_array(__entry->f.segmentation.feature_enabled,
- ARRAY_SIZE(__entry->f.segmentation.feature_enabled),
- sizeof(__entry->f.segmentation.feature_enabled[0])),
- __print_flags(__entry->f.loop_filter.flags, "|",
- {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_ENABLED, "DELTA_ENABLED"},
- {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_UPDATE, "DELTA_UPDATE"},
- {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_LF_PRESENT, "DELTA_LF_PRESENT"},
- {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_LF_MULTI, "DELTA_LF_MULTI"}),
- __print_array(__entry->f.loop_filter.level,
- ARRAY_SIZE(__entry->f.loop_filter.level),
- sizeof(__entry->f.loop_filter.level[0])),
- __entry->f.loop_filter.sharpness,
- __print_array(__entry->f.loop_filter.ref_deltas,
- ARRAY_SIZE(__entry->f.loop_filter.ref_deltas),
- sizeof(__entry->f.loop_filter.ref_deltas[0])),
- __print_array(__entry->f.loop_filter.mode_deltas,
- ARRAY_SIZE(__entry->f.loop_filter.mode_deltas),
- sizeof(__entry->f.loop_filter.mode_deltas[0])),
- __entry->f.loop_filter.delta_lf_res,
- __entry->f.cdef.damping_minus_3,
- __entry->f.cdef.bits,
- __print_array(__entry->f.cdef.y_pri_strength,
- ARRAY_SIZE(__entry->f.cdef.y_pri_strength),
- sizeof(__entry->f.cdef.y_pri_strength[0])),
- __print_array(__entry->f.cdef.y_sec_strength,
- ARRAY_SIZE(__entry->f.cdef.y_sec_strength),
- sizeof(__entry->f.cdef.y_sec_strength[0])),
- __print_array(__entry->f.cdef.uv_pri_strength,
- ARRAY_SIZE(__entry->f.cdef.uv_pri_strength),
- sizeof(__entry->f.cdef.uv_pri_strength[0])),
- __print_array(__entry->f.cdef.uv_sec_strength,
- ARRAY_SIZE(__entry->f.cdef.uv_sec_strength),
- sizeof(__entry->f.cdef.uv_sec_strength[0])),
- __print_array(__entry->f.skip_mode_frame,
- ARRAY_SIZE(__entry->f.skip_mode_frame),
- sizeof(__entry->f.skip_mode_frame[0])),
- __entry->f.primary_ref_frame,
- __print_flags(__entry->f.loop_restoration.flags, "|",
- {V4L2_AV1_LOOP_RESTORATION_FLAG_USES_LR, "USES_LR"},
- {V4L2_AV1_LOOP_RESTORATION_FLAG_USES_CHROMA_LR, "USES_CHROMA_LR"}),
- __entry->f.loop_restoration.lr_unit_shift,
- __entry->f.loop_restoration.lr_uv_shift,
- __print_array(__entry->f.loop_restoration.frame_restoration_type,
- ARRAY_SIZE(__entry->f.loop_restoration.frame_restoration_type),
- sizeof(__entry->f.loop_restoration.frame_restoration_type[0])),
- __print_array(__entry->f.loop_restoration.loop_restoration_size,
- ARRAY_SIZE(__entry->f.loop_restoration.loop_restoration_size),
- sizeof(__entry->f.loop_restoration.loop_restoration_size[0])),
- __print_flags(__entry->f.flags, "|",
- {V4L2_AV1_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
- {V4L2_AV1_FRAME_FLAG_SHOWABLE_FRAME, "SHOWABLE_FRAME"},
- {V4L2_AV1_FRAME_FLAG_ERROR_RESILIENT_MODE, "ERROR_RESILIENT_MODE"},
- {V4L2_AV1_FRAME_FLAG_DISABLE_CDF_UPDATE, "DISABLE_CDF_UPDATE"},
- {V4L2_AV1_FRAME_FLAG_ALLOW_SCREEN_CONTENT_TOOLS, "ALLOW_SCREEN_CONTENT_TOOLS"},
- {V4L2_AV1_FRAME_FLAG_FORCE_INTEGER_MV, "FORCE_INTEGER_MV"},
- {V4L2_AV1_FRAME_FLAG_ALLOW_INTRABC, "ALLOW_INTRABC"},
- {V4L2_AV1_FRAME_FLAG_USE_SUPERRES, "USE_SUPERRES"},
- {V4L2_AV1_FRAME_FLAG_ALLOW_HIGH_PRECISION_MV, "ALLOW_HIGH_PRECISION_MV"},
- {V4L2_AV1_FRAME_FLAG_IS_MOTION_MODE_SWITCHABLE, "IS_MOTION_MODE_SWITCHABLE"},
- {V4L2_AV1_FRAME_FLAG_USE_REF_FRAME_MVS, "USE_REF_FRAME_MVS"},
- {V4L2_AV1_FRAME_FLAG_DISABLE_FRAME_END_UPDATE_CDF,
- "DISABLE_FRAME_END_UPDATE_CDF"},
- {V4L2_AV1_FRAME_FLAG_ALLOW_WARPED_MOTION, "ALLOW_WARPED_MOTION"},
- {V4L2_AV1_FRAME_FLAG_REFERENCE_SELECT, "REFERENCE_SELECT"},
- {V4L2_AV1_FRAME_FLAG_REDUCED_TX_SET, "REDUCED_TX_SET"},
- {V4L2_AV1_FRAME_FLAG_SKIP_MODE_ALLOWED, "SKIP_MODE_ALLOWED"},
- {V4L2_AV1_FRAME_FLAG_SKIP_MODE_PRESENT, "SKIP_MODE_PRESENT"},
- {V4L2_AV1_FRAME_FLAG_FRAME_SIZE_OVERRIDE, "FRAME_SIZE_OVERRIDE"},
- {V4L2_AV1_FRAME_FLAG_BUFFER_REMOVAL_TIME_PRESENT, "BUFFER_REMOVAL_TIME_PRESENT"},
- {V4L2_AV1_FRAME_FLAG_FRAME_REFS_SHORT_SIGNALING, "FRAME_REFS_SHORT_SIGNALING"}),
- __entry->f.order_hint,
- __entry->f.upscaled_width,
- __entry->f.frame_width_minus_1,
- __entry->f.frame_height_minus_1,
- __entry->f.render_width_minus_1,
- __entry->f.render_height_minus_1,
- __entry->f.current_frame_id,
- __print_array(__entry->f.buffer_removal_time,
- ARRAY_SIZE(__entry->f.buffer_removal_time),
- sizeof(__entry->f.buffer_removal_time[0])),
- __print_array(__entry->f.order_hints,
- ARRAY_SIZE(__entry->f.order_hints),
- sizeof(__entry->f.order_hints[0])),
- __print_array(__entry->f.reference_frame_ts,
- ARRAY_SIZE(__entry->f.reference_frame_ts),
- sizeof(__entry->f.reference_frame_ts[0])),
- __print_array(__entry->f.ref_frame_idx,
- ARRAY_SIZE(__entry->f.ref_frame_idx),
- sizeof(__entry->f.ref_frame_idx[0])),
- __entry->f.refresh_frame_flags
- )
-);
-
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_film_grain, f)),
- TP_fast_assign(__entry->f = *f;),
- TP_printk("\nflags %s\ncr_mult: %u\ngrain_seed: %u\n"
- "film_grain_params_ref_idx: %u\nnum_y_points: %u\npoint_y_value: %s\n"
- "point_y_scaling: %s\nnum_cb_points: %u\npoint_cb_value: %s\n"
- "point_cb_scaling: %s\nnum_cr_points: %u\npoint_cr_value: %s\n"
- "point_cr_scaling: %s\ngrain_scaling_minus_8: %u\nar_coeff_lag: %u\n"
- "ar_coeffs_y_plus_128: %s\nar_coeffs_cb_plus_128: %s\n"
- "ar_coeffs_cr_plus_128: %s\nar_coeff_shift_minus_6: %u\n"
- "grain_scale_shift: %u\ncb_mult: %u\ncb_luma_mult: %u\ncr_luma_mult: %u\n"
- "cb_offset: %u\ncr_offset: %u\n",
- __print_flags(__entry->f.flags, "|",
- {V4L2_AV1_FILM_GRAIN_FLAG_APPLY_GRAIN, "APPLY_GRAIN"},
- {V4L2_AV1_FILM_GRAIN_FLAG_UPDATE_GRAIN, "UPDATE_GRAIN"},
- {V4L2_AV1_FILM_GRAIN_FLAG_CHROMA_SCALING_FROM_LUMA, "CHROMA_SCALING_FROM_LUMA"},
- {V4L2_AV1_FILM_GRAIN_FLAG_OVERLAP, "OVERLAP"},
- {V4L2_AV1_FILM_GRAIN_FLAG_CLIP_TO_RESTRICTED_RANGE, "CLIP_TO_RESTRICTED_RANGE"}),
- __entry->f.cr_mult,
- __entry->f.grain_seed,
- __entry->f.film_grain_params_ref_idx,
- __entry->f.num_y_points,
- __print_array(__entry->f.point_y_value,
- ARRAY_SIZE(__entry->f.point_y_value),
- sizeof(__entry->f.point_y_value[0])),
- __print_array(__entry->f.point_y_scaling,
- ARRAY_SIZE(__entry->f.point_y_scaling),
- sizeof(__entry->f.point_y_scaling[0])),
- __entry->f.num_cb_points,
- __print_array(__entry->f.point_cb_value,
- ARRAY_SIZE(__entry->f.point_cb_value),
- sizeof(__entry->f.point_cb_value[0])),
- __print_array(__entry->f.point_cb_scaling,
- ARRAY_SIZE(__entry->f.point_cb_scaling),
- sizeof(__entry->f.point_cb_scaling[0])),
- __entry->f.num_cr_points,
- __print_array(__entry->f.point_cr_value,
- ARRAY_SIZE(__entry->f.point_cr_value),
- sizeof(__entry->f.point_cr_value[0])),
- __print_array(__entry->f.point_cr_scaling,
- ARRAY_SIZE(__entry->f.point_cr_scaling),
- sizeof(__entry->f.point_cr_scaling[0])),
- __entry->f.grain_scaling_minus_8,
- __entry->f.ar_coeff_lag,
- __print_array(__entry->f.ar_coeffs_y_plus_128,
- ARRAY_SIZE(__entry->f.ar_coeffs_y_plus_128),
- sizeof(__entry->f.ar_coeffs_y_plus_128[0])),
- __print_array(__entry->f.ar_coeffs_cb_plus_128,
- ARRAY_SIZE(__entry->f.ar_coeffs_cb_plus_128),
- sizeof(__entry->f.ar_coeffs_cb_plus_128[0])),
- __print_array(__entry->f.ar_coeffs_cr_plus_128,
- ARRAY_SIZE(__entry->f.ar_coeffs_cr_plus_128),
- sizeof(__entry->f.ar_coeffs_cr_plus_128[0])),
- __entry->f.ar_coeff_shift_minus_6,
- __entry->f.grain_scale_shift,
- __entry->f.cb_mult,
- __entry->f.cb_luma_mult,
- __entry->f.cr_luma_mult,
- __entry->f.cb_offset,
- __entry->f.cr_offset
- )
-)
-
-DEFINE_EVENT(v4l2_ctrl_av1_seq_tmpl, v4l2_ctrl_av1_sequence,
- TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_ctrl_av1_frame_tmpl, v4l2_ctrl_av1_frame,
- TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
- TP_ARGS(f)
-);
-
-DEFINE_EVENT(v4l2_ctrl_av1_tge_tmpl, v4l2_ctrl_av1_tile_group_entry,
- TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
- TP_ARGS(t)
-);
-
-DEFINE_EVENT(v4l2_ctrl_av1_film_grain_tmpl, v4l2_ctrl_av1_film_grain,
- TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
- TP_ARGS(f)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-av1
-#include <trace/define_trace.h>
diff --git a/drivers/media/test-drivers/visl/visl-trace-fwht.h b/drivers/media/test-drivers/visl/visl-trace-fwht.h
deleted file mode 100644
index 54b119359ff5..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-fwht.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#if !defined(_VISL_TRACE_FWHT_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_FWHT_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_fwht_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_fwht_params *p),
- TP_ARGS(p),
- TP_STRUCT__entry(
- __field(u64, backward_ref_ts)
- __field(u32, version)
- __field(u32, width)
- __field(u32, height)
- __field(u32, flags)
- __field(u32, colorspace)
- __field(u32, xfer_func)
- __field(u32, ycbcr_enc)
- __field(u32, quantization)
- ),
- TP_fast_assign(
- __entry->backward_ref_ts = p->backward_ref_ts;
- __entry->version = p->version;
- __entry->width = p->width;
- __entry->height = p->height;
- __entry->flags = p->flags;
- __entry->colorspace = p->colorspace;
- __entry->xfer_func = p->xfer_func;
- __entry->ycbcr_enc = p->ycbcr_enc;
- __entry->quantization = p->quantization;
- ),
- TP_printk("backward_ref_ts %llu version %u width %u height %u flags %s colorspace %u xfer_func %u ycbcr_enc %u quantization %u",
- __entry->backward_ref_ts, __entry->version, __entry->width, __entry->height,
- __print_flags(__entry->flags, "|",
- {V4L2_FWHT_FL_IS_INTERLACED, "IS_INTERLACED"},
- {V4L2_FWHT_FL_IS_BOTTOM_FIRST, "IS_BOTTOM_FIRST"},
- {V4L2_FWHT_FL_IS_ALTERNATE, "IS_ALTERNATE"},
- {V4L2_FWHT_FL_IS_BOTTOM_FIELD, "IS_BOTTOM_FIELD"},
- {V4L2_FWHT_FL_LUMA_IS_UNCOMPRESSED, "LUMA_IS_UNCOMPRESSED"},
- {V4L2_FWHT_FL_CB_IS_UNCOMPRESSED, "CB_IS_UNCOMPRESSED"},
- {V4L2_FWHT_FL_CR_IS_UNCOMPRESSED, "CR_IS_UNCOMPRESSED"},
- {V4L2_FWHT_FL_ALPHA_IS_UNCOMPRESSED, "ALPHA_IS_UNCOMPRESSED"},
- {V4L2_FWHT_FL_I_FRAME, "I_FRAME"},
- {V4L2_FWHT_FL_PIXENC_HSV, "PIXENC_HSV"},
- {V4L2_FWHT_FL_PIXENC_RGB, "PIXENC_RGB"},
- {V4L2_FWHT_FL_PIXENC_YUV, "PIXENC_YUV"}),
- __entry->colorspace, __entry->xfer_func, __entry->ycbcr_enc,
- __entry->quantization)
-);
-
-DEFINE_EVENT(v4l2_ctrl_fwht_params_tmpl, v4l2_ctrl_fwht_params,
- TP_PROTO(const struct v4l2_ctrl_fwht_params *p),
- TP_ARGS(p)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-fwht
-#include <trace/define_trace.h>
diff --git a/drivers/media/test-drivers/visl/visl-trace-h264.h b/drivers/media/test-drivers/visl/visl-trace-h264.h
deleted file mode 100644
index d84296a01deb..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-h264.h
+++ /dev/null
@@ -1,349 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#if !defined(_VISL_TRACE_H264_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_H264_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_h264_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_sps, s)),
- TP_fast_assign(__entry->s = *s),
- TP_printk("\nprofile_idc %u\n"
- "constraint_set_flags %s\n"
- "level_idc %u\n"
- "seq_parameter_set_id %u\n"
- "chroma_format_idc %u\n"
- "bit_depth_luma_minus8 %u\n"
- "bit_depth_chroma_minus8 %u\n"
- "log2_max_frame_num_minus4 %u\n"
- "pic_order_cnt_type %u\n"
- "log2_max_pic_order_cnt_lsb_minus4 %u\n"
- "max_num_ref_frames %u\n"
- "num_ref_frames_in_pic_order_cnt_cycle %u\n"
- "offset_for_ref_frame %s\n"
- "offset_for_non_ref_pic %d\n"
- "offset_for_top_to_bottom_field %d\n"
- "pic_width_in_mbs_minus1 %u\n"
- "pic_height_in_map_units_minus1 %u\n"
- "flags %s",
- __entry->s.profile_idc,
- __print_flags(__entry->s.constraint_set_flags, "|",
- {V4L2_H264_SPS_CONSTRAINT_SET0_FLAG, "CONSTRAINT_SET0_FLAG"},
- {V4L2_H264_SPS_CONSTRAINT_SET1_FLAG, "CONSTRAINT_SET1_FLAG"},
- {V4L2_H264_SPS_CONSTRAINT_SET2_FLAG, "CONSTRAINT_SET2_FLAG"},
- {V4L2_H264_SPS_CONSTRAINT_SET3_FLAG, "CONSTRAINT_SET3_FLAG"},
- {V4L2_H264_SPS_CONSTRAINT_SET4_FLAG, "CONSTRAINT_SET4_FLAG"},
- {V4L2_H264_SPS_CONSTRAINT_SET5_FLAG, "CONSTRAINT_SET5_FLAG"}),
- __entry->s.level_idc,
- __entry->s.seq_parameter_set_id,
- __entry->s.chroma_format_idc,
- __entry->s.bit_depth_luma_minus8,
- __entry->s.bit_depth_chroma_minus8,
- __entry->s.log2_max_frame_num_minus4,
- __entry->s.pic_order_cnt_type,
- __entry->s.log2_max_pic_order_cnt_lsb_minus4,
- __entry->s.max_num_ref_frames,
- __entry->s.num_ref_frames_in_pic_order_cnt_cycle,
- __print_array(__entry->s.offset_for_ref_frame,
- ARRAY_SIZE(__entry->s.offset_for_ref_frame),
- sizeof(__entry->s.offset_for_ref_frame[0])),
- __entry->s.offset_for_non_ref_pic,
- __entry->s.offset_for_top_to_bottom_field,
- __entry->s.pic_width_in_mbs_minus1,
- __entry->s.pic_height_in_map_units_minus1,
- __print_flags(__entry->s.flags, "|",
- {V4L2_H264_SPS_FLAG_SEPARATE_COLOUR_PLANE, "SEPARATE_COLOUR_PLANE"},
- {V4L2_H264_SPS_FLAG_QPPRIME_Y_ZERO_TRANSFORM_BYPASS, "QPPRIME_Y_ZERO_TRANSFORM_BYPASS"},
- {V4L2_H264_SPS_FLAG_DELTA_PIC_ORDER_ALWAYS_ZERO, "DELTA_PIC_ORDER_ALWAYS_ZERO"},
- {V4L2_H264_SPS_FLAG_GAPS_IN_FRAME_NUM_VALUE_ALLOWED, "GAPS_IN_FRAME_NUM_VALUE_ALLOWED"},
- {V4L2_H264_SPS_FLAG_FRAME_MBS_ONLY, "FRAME_MBS_ONLY"},
- {V4L2_H264_SPS_FLAG_MB_ADAPTIVE_FRAME_FIELD, "MB_ADAPTIVE_FRAME_FIELD"},
- {V4L2_H264_SPS_FLAG_DIRECT_8X8_INFERENCE, "DIRECT_8X8_INFERENCE"}
- ))
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_pps, p)),
- TP_fast_assign(__entry->p = *p),
- TP_printk("\npic_parameter_set_id %u\n"
- "seq_parameter_set_id %u\n"
- "num_slice_groups_minus1 %u\n"
- "num_ref_idx_l0_default_active_minus1 %u\n"
- "num_ref_idx_l1_default_active_minus1 %u\n"
- "weighted_bipred_idc %u\n"
- "pic_init_qp_minus26 %d\n"
- "pic_init_qs_minus26 %d\n"
- "chroma_qp_index_offset %d\n"
- "second_chroma_qp_index_offset %d\n"
- "flags %s",
- __entry->p.pic_parameter_set_id,
- __entry->p.seq_parameter_set_id,
- __entry->p.num_slice_groups_minus1,
- __entry->p.num_ref_idx_l0_default_active_minus1,
- __entry->p.num_ref_idx_l1_default_active_minus1,
- __entry->p.weighted_bipred_idc,
- __entry->p.pic_init_qp_minus26,
- __entry->p.pic_init_qs_minus26,
- __entry->p.chroma_qp_index_offset,
- __entry->p.second_chroma_qp_index_offset,
- __print_flags(__entry->p.flags, "|",
- {V4L2_H264_PPS_FLAG_ENTROPY_CODING_MODE, "ENTROPY_CODING_MODE"},
- {V4L2_H264_PPS_FLAG_BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT, "BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT"},
- {V4L2_H264_PPS_FLAG_WEIGHTED_PRED, "WEIGHTED_PRED"},
- {V4L2_H264_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT, "DEBLOCKING_FILTER_CONTROL_PRESENT"},
- {V4L2_H264_PPS_FLAG_CONSTRAINED_INTRA_PRED, "CONSTRAINED_INTRA_PRED"},
- {V4L2_H264_PPS_FLAG_REDUNDANT_PIC_CNT_PRESENT, "REDUNDANT_PIC_CNT_PRESENT"},
- {V4L2_H264_PPS_FLAG_TRANSFORM_8X8_MODE, "TRANSFORM_8X8_MODE"},
- {V4L2_H264_PPS_FLAG_SCALING_MATRIX_PRESENT, "SCALING_MATRIX_PRESENT"}
- ))
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_h264_scaling_matrix_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_scaling_matrix, s)),
- TP_fast_assign(__entry->s = *s),
- TP_printk("\nscaling_list_4x4 {%s}\nscaling_list_8x8 {%s}",
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_4x4,
- sizeof(__entry->s.scaling_list_4x4),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_8x8,
- sizeof(__entry->s.scaling_list_8x8),
- false)
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_pred_weights, p)),
- TP_fast_assign(__entry->p = *p),
- TP_printk("\nluma_log2_weight_denom %u\n"
- "chroma_log2_weight_denom %u\n"
- "weight_factor[0].luma_weight %s\n"
- "weight_factor[0].luma_offset %s\n"
- "weight_factor[0].chroma_weight {%s}\n"
- "weight_factor[0].chroma_offset {%s}\n"
- "weight_factor[1].luma_weight %s\n"
- "weight_factor[1].luma_offset %s\n"
- "weight_factor[1].chroma_weight {%s}\n"
- "weight_factor[1].chroma_offset {%s}\n",
- __entry->p.luma_log2_weight_denom,
- __entry->p.chroma_log2_weight_denom,
- __print_array(__entry->p.weight_factors[0].luma_weight,
- ARRAY_SIZE(__entry->p.weight_factors[0].luma_weight),
- sizeof(__entry->p.weight_factors[0].luma_weight[0])),
- __print_array(__entry->p.weight_factors[0].luma_offset,
- ARRAY_SIZE(__entry->p.weight_factors[0].luma_offset),
- sizeof(__entry->p.weight_factors[0].luma_offset[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[0].chroma_weight,
- sizeof(__entry->p.weight_factors[0].chroma_weight),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[0].chroma_offset,
- sizeof(__entry->p.weight_factors[0].chroma_offset),
- false),
- __print_array(__entry->p.weight_factors[1].luma_weight,
- ARRAY_SIZE(__entry->p.weight_factors[1].luma_weight),
- sizeof(__entry->p.weight_factors[1].luma_weight[0])),
- __print_array(__entry->p.weight_factors[1].luma_offset,
- ARRAY_SIZE(__entry->p.weight_factors[1].luma_offset),
- sizeof(__entry->p.weight_factors[1].luma_offset[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[1].chroma_weight,
- sizeof(__entry->p.weight_factors[1].chroma_weight),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[1].chroma_offset,
- sizeof(__entry->p.weight_factors[1].chroma_offset),
- false)
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_slice_params, s)),
- TP_fast_assign(__entry->s = *s),
- TP_printk("\nheader_bit_size %u\n"
- "first_mb_in_slice %u\n"
- "slice_type %s\n"
- "colour_plane_id %u\n"
- "redundant_pic_cnt %u\n"
- "cabac_init_idc %u\n"
- "slice_qp_delta %d\n"
- "slice_qs_delta %d\n"
- "disable_deblocking_filter_idc %u\n"
- "slice_alpha_c0_offset_div2 %u\n"
- "slice_beta_offset_div2 %u\n"
- "num_ref_idx_l0_active_minus1 %u\n"
- "num_ref_idx_l1_active_minus1 %u\n"
- "flags %s",
- __entry->s.header_bit_size,
- __entry->s.first_mb_in_slice,
- __print_symbolic(__entry->s.slice_type,
- {V4L2_H264_SLICE_TYPE_P, "P"},
- {V4L2_H264_SLICE_TYPE_B, "B"},
- {V4L2_H264_SLICE_TYPE_I, "I"},
- {V4L2_H264_SLICE_TYPE_SP, "SP"},
- {V4L2_H264_SLICE_TYPE_SI, "SI"}),
- __entry->s.colour_plane_id,
- __entry->s.redundant_pic_cnt,
- __entry->s.cabac_init_idc,
- __entry->s.slice_qp_delta,
- __entry->s.slice_qs_delta,
- __entry->s.disable_deblocking_filter_idc,
- __entry->s.slice_alpha_c0_offset_div2,
- __entry->s.slice_beta_offset_div2,
- __entry->s.num_ref_idx_l0_active_minus1,
- __entry->s.num_ref_idx_l1_active_minus1,
- __print_flags(__entry->s.flags, "|",
- {V4L2_H264_SLICE_FLAG_DIRECT_SPATIAL_MV_PRED, "DIRECT_SPATIAL_MV_PRED"},
- {V4L2_H264_SLICE_FLAG_SP_FOR_SWITCH, "SP_FOR_SWITCH"})
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_h264_reference_tmpl,
- TP_PROTO(const struct v4l2_h264_reference *r, int i),
- TP_ARGS(r, i),
- TP_STRUCT__entry(__field_struct(struct v4l2_h264_reference, r)
- __field(int, i)),
- TP_fast_assign(__entry->r = *r; __entry->i = i;),
- TP_printk("[%d]: fields %s index %u",
- __entry->i,
- __print_flags(__entry->r.fields, "|",
- {V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
- {V4L2_H264_BOTTOM_FIELD_REF, "BOTTOM_FIELD_REF"},
- {V4L2_H264_FRAME_REF, "FRAME_REF"}),
- __entry->r.index
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
- TP_ARGS(d),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_decode_params, d)),
- TP_fast_assign(__entry->d = *d),
- TP_printk("\nnal_ref_idc %u\n"
- "frame_num %u\n"
- "top_field_order_cnt %d\n"
- "bottom_field_order_cnt %d\n"
- "idr_pic_id %u\n"
- "pic_order_cnt_lsb %u\n"
- "delta_pic_order_cnt_bottom %d\n"
- "delta_pic_order_cnt0 %d\n"
- "delta_pic_order_cnt1 %d\n"
- "dec_ref_pic_marking_bit_size %u\n"
- "pic_order_cnt_bit_size %u\n"
- "slice_group_change_cycle %u\n"
- "flags %s\n",
- __entry->d.nal_ref_idc,
- __entry->d.frame_num,
- __entry->d.top_field_order_cnt,
- __entry->d.bottom_field_order_cnt,
- __entry->d.idr_pic_id,
- __entry->d.pic_order_cnt_lsb,
- __entry->d.delta_pic_order_cnt_bottom,
- __entry->d.delta_pic_order_cnt0,
- __entry->d.delta_pic_order_cnt1,
- __entry->d.dec_ref_pic_marking_bit_size,
- __entry->d.pic_order_cnt_bit_size,
- __entry->d.slice_group_change_cycle,
- __print_flags(__entry->d.flags, "|",
- {V4L2_H264_DECODE_PARAM_FLAG_IDR_PIC, "IDR_PIC"},
- {V4L2_H264_DECODE_PARAM_FLAG_FIELD_PIC, "FIELD_PIC"},
- {V4L2_H264_DECODE_PARAM_FLAG_BOTTOM_FIELD, "BOTTOM_FIELD"},
- {V4L2_H264_DECODE_PARAM_FLAG_PFRAME, "PFRAME"},
- {V4L2_H264_DECODE_PARAM_FLAG_BFRAME, "BFRAME"})
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
- TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
- TP_ARGS(e, i),
- TP_STRUCT__entry(__field_struct(struct v4l2_h264_dpb_entry, e)
- __field(int, i)),
- TP_fast_assign(__entry->e = *e; __entry->i = i;),
- TP_printk("[%d]: reference_ts %llu, pic_num %u frame_num %u fields %s "
- "top_field_order_cnt %d bottom_field_order_cnt %d flags %s",
- __entry->i,
- __entry->e.reference_ts,
- __entry->e.pic_num,
- __entry->e.frame_num,
- __print_flags(__entry->e.fields, "|",
- {V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
- {V4L2_H264_BOTTOM_FIELD_REF, "BOTTOM_FIELD_REF"},
- {V4L2_H264_FRAME_REF, "FRAME_REF"}),
- __entry->e.top_field_order_cnt,
- __entry->e.bottom_field_order_cnt,
- __print_flags(__entry->e.flags, "|",
- {V4L2_H264_DPB_ENTRY_FLAG_VALID, "VALID"},
- {V4L2_H264_DPB_ENTRY_FLAG_ACTIVE, "ACTIVE"},
- {V4L2_H264_DPB_ENTRY_FLAG_LONG_TERM, "LONG_TERM"},
- {V4L2_H264_DPB_ENTRY_FLAG_FIELD, "FIELD"})
-
- )
-);
-
-DEFINE_EVENT(v4l2_ctrl_h264_sps_tmpl, v4l2_ctrl_h264_sps,
- TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_ctrl_h264_pps_tmpl, v4l2_ctrl_h264_pps,
- TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
- TP_ARGS(p)
-);
-
-DEFINE_EVENT(v4l2_ctrl_h264_scaling_matrix_tmpl, v4l2_ctrl_h264_scaling_matrix,
- TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_ctrl_h264_pred_weights_tmpl, v4l2_ctrl_h264_pred_weights,
- TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
- TP_ARGS(p)
-);
-
-DEFINE_EVENT(v4l2_ctrl_h264_slice_params_tmpl, v4l2_ctrl_h264_slice_params,
- TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_h264_reference_tmpl, v4l2_h264_ref_pic_list0,
- TP_PROTO(const struct v4l2_h264_reference *r, int i),
- TP_ARGS(r, i)
-);
-
-DEFINE_EVENT(v4l2_h264_reference_tmpl, v4l2_h264_ref_pic_list1,
- TP_PROTO(const struct v4l2_h264_reference *r, int i),
- TP_ARGS(r, i)
-);
-
-DEFINE_EVENT(v4l2_ctrl_h264_decode_params_tmpl, v4l2_ctrl_h264_decode_params,
- TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
- TP_ARGS(d)
-);
-
-DEFINE_EVENT(v4l2_h264_dpb_entry_tmpl, v4l2_h264_dpb_entry,
- TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
- TP_ARGS(e, i)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-h264
-#include <trace/define_trace.h>
diff --git a/drivers/media/test-drivers/visl/visl-trace-hevc.h b/drivers/media/test-drivers/visl/visl-trace-hevc.h
deleted file mode 100644
index 963914c463db..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-hevc.h
+++ /dev/null
@@ -1,464 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0+ */
-#include "linux/v4l2-controls.h"
-#if !defined(_VISL_TRACE_HEVC_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_HEVC_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_hevc_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_sps, s)),
- TP_fast_assign(__entry->s = *s),
- TP_printk("\nvideo_parameter_set_id %u\n"
- "seq_parameter_set_id %u\n"
- "pic_width_in_luma_samples %u\n"
- "pic_height_in_luma_samples %u\n"
- "bit_depth_luma_minus8 %u\n"
- "bit_depth_chroma_minus8 %u\n"
- "log2_max_pic_order_cnt_lsb_minus4 %u\n"
- "sps_max_dec_pic_buffering_minus1 %u\n"
- "sps_max_num_reorder_pics %u\n"
- "sps_max_latency_increase_plus1 %u\n"
- "log2_min_luma_coding_block_size_minus3 %u\n"
- "log2_diff_max_min_luma_coding_block_size %u\n"
- "log2_min_luma_transform_block_size_minus2 %u\n"
- "log2_diff_max_min_luma_transform_block_size %u\n"
- "max_transform_hierarchy_depth_inter %u\n"
- "max_transform_hierarchy_depth_intra %u\n"
- "pcm_sample_bit_depth_luma_minus1 %u\n"
- "pcm_sample_bit_depth_chroma_minus1 %u\n"
- "log2_min_pcm_luma_coding_block_size_minus3 %u\n"
- "log2_diff_max_min_pcm_luma_coding_block_size %u\n"
- "num_short_term_ref_pic_sets %u\n"
- "num_long_term_ref_pics_sps %u\n"
- "chroma_format_idc %u\n"
- "sps_max_sub_layers_minus1 %u\n"
- "flags %s",
- __entry->s.video_parameter_set_id,
- __entry->s.seq_parameter_set_id,
- __entry->s.pic_width_in_luma_samples,
- __entry->s.pic_height_in_luma_samples,
- __entry->s.bit_depth_luma_minus8,
- __entry->s.bit_depth_chroma_minus8,
- __entry->s.log2_max_pic_order_cnt_lsb_minus4,
- __entry->s.sps_max_dec_pic_buffering_minus1,
- __entry->s.sps_max_num_reorder_pics,
- __entry->s.sps_max_latency_increase_plus1,
- __entry->s.log2_min_luma_coding_block_size_minus3,
- __entry->s.log2_diff_max_min_luma_coding_block_size,
- __entry->s.log2_min_luma_transform_block_size_minus2,
- __entry->s.log2_diff_max_min_luma_transform_block_size,
- __entry->s.max_transform_hierarchy_depth_inter,
- __entry->s.max_transform_hierarchy_depth_intra,
- __entry->s.pcm_sample_bit_depth_luma_minus1,
- __entry->s.pcm_sample_bit_depth_chroma_minus1,
- __entry->s.log2_min_pcm_luma_coding_block_size_minus3,
- __entry->s.log2_diff_max_min_pcm_luma_coding_block_size,
- __entry->s.num_short_term_ref_pic_sets,
- __entry->s.num_long_term_ref_pics_sps,
- __entry->s.chroma_format_idc,
- __entry->s.sps_max_sub_layers_minus1,
- __print_flags(__entry->s.flags, "|",
- {V4L2_HEVC_SPS_FLAG_SEPARATE_COLOUR_PLANE, "SEPARATE_COLOUR_PLANE"},
- {V4L2_HEVC_SPS_FLAG_SCALING_LIST_ENABLED, "SCALING_LIST_ENABLED"},
- {V4L2_HEVC_SPS_FLAG_AMP_ENABLED, "AMP_ENABLED"},
- {V4L2_HEVC_SPS_FLAG_SAMPLE_ADAPTIVE_OFFSET, "SAMPLE_ADAPTIVE_OFFSET"},
- {V4L2_HEVC_SPS_FLAG_PCM_ENABLED, "PCM_ENABLED"},
- {V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED, "V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED"},
- {V4L2_HEVC_SPS_FLAG_LONG_TERM_REF_PICS_PRESENT, "LONG_TERM_REF_PICS_PRESENT"},
- {V4L2_HEVC_SPS_FLAG_SPS_TEMPORAL_MVP_ENABLED, "TEMPORAL_MVP_ENABLED"},
- {V4L2_HEVC_SPS_FLAG_STRONG_INTRA_SMOOTHING_ENABLED, "STRONG_INTRA_SMOOTHING_ENABLED"}
- ))
-
-);
-
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_pps, p)),
- TP_fast_assign(__entry->p = *p),
- TP_printk("\npic_parameter_set_id %u\n"
- "num_extra_slice_header_bits %u\n"
- "num_ref_idx_l0_default_active_minus1 %u\n"
- "num_ref_idx_l1_default_active_minus1 %u\n"
- "init_qp_minus26 %d\n"
- "diff_cu_qp_delta_depth %u\n"
- "pps_cb_qp_offset %d\n"
- "pps_cr_qp_offset %d\n"
- "num_tile_columns_minus1 %d\n"
- "num_tile_rows_minus1 %d\n"
- "column_width_minus1 %s\n"
- "row_height_minus1 %s\n"
- "pps_beta_offset_div2 %d\n"
- "pps_tc_offset_div2 %d\n"
- "log2_parallel_merge_level_minus2 %u\n"
- "flags %s",
- __entry->p.pic_parameter_set_id,
- __entry->p.num_extra_slice_header_bits,
- __entry->p.num_ref_idx_l0_default_active_minus1,
- __entry->p.num_ref_idx_l1_default_active_minus1,
- __entry->p.init_qp_minus26,
- __entry->p.diff_cu_qp_delta_depth,
- __entry->p.pps_cb_qp_offset,
- __entry->p.pps_cr_qp_offset,
- __entry->p.num_tile_columns_minus1,
- __entry->p.num_tile_rows_minus1,
- __print_array(__entry->p.column_width_minus1,
- ARRAY_SIZE(__entry->p.column_width_minus1),
- sizeof(__entry->p.column_width_minus1[0])),
- __print_array(__entry->p.row_height_minus1,
- ARRAY_SIZE(__entry->p.row_height_minus1),
- sizeof(__entry->p.row_height_minus1[0])),
- __entry->p.pps_beta_offset_div2,
- __entry->p.pps_tc_offset_div2,
- __entry->p.log2_parallel_merge_level_minus2,
- __print_flags(__entry->p.flags, "|",
- {V4L2_HEVC_PPS_FLAG_DEPENDENT_SLICE_SEGMENT_ENABLED, "DEPENDENT_SLICE_SEGMENT_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_OUTPUT_FLAG_PRESENT, "OUTPUT_FLAG_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_SIGN_DATA_HIDING_ENABLED, "SIGN_DATA_HIDING_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_CABAC_INIT_PRESENT, "CABAC_INIT_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_CONSTRAINED_INTRA_PRED, "CONSTRAINED_INTRA_PRED"},
- {V4L2_HEVC_PPS_FLAG_CU_QP_DELTA_ENABLED, "CU_QP_DELTA_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT, "PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_WEIGHTED_PRED, "WEIGHTED_PRED"},
- {V4L2_HEVC_PPS_FLAG_WEIGHTED_BIPRED, "WEIGHTED_BIPRED"},
- {V4L2_HEVC_PPS_FLAG_TRANSQUANT_BYPASS_ENABLED, "TRANSQUANT_BYPASS_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_TILES_ENABLED, "TILES_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_ENTROPY_CODING_SYNC_ENABLED, "ENTROPY_CODING_SYNC_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_LOOP_FILTER_ACROSS_TILES_ENABLED, "LOOP_FILTER_ACROSS_TILES_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED, "PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_OVERRIDE_ENABLED, "DEBLOCKING_FILTER_OVERRIDE_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_PPS_DISABLE_DEBLOCKING_FILTER, "DISABLE_DEBLOCKING_FILTER"},
- {V4L2_HEVC_PPS_FLAG_LISTS_MODIFICATION_PRESENT, "LISTS_MODIFICATION_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_SLICE_SEGMENT_HEADER_EXTENSION_PRESENT, "SLICE_SEGMENT_HEADER_EXTENSION_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT, "DEBLOCKING_FILTER_CONTROL_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_UNIFORM_SPACING, "UNIFORM_SPACING"}
- ))
-
-);
-
-
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_slice_params, s)),
- TP_fast_assign(__entry->s = *s),
- TP_printk("\nbit_size %u\n"
- "data_byte_offset %u\n"
- "num_entry_point_offsets %u\n"
- "nal_unit_type %u\n"
- "nuh_temporal_id_plus1 %u\n"
- "slice_type %u\n"
- "colour_plane_id %u\n"
- "slice_pic_order_cnt %d\n"
- "num_ref_idx_l0_active_minus1 %u\n"
- "num_ref_idx_l1_active_minus1 %u\n"
- "collocated_ref_idx %u\n"
- "five_minus_max_num_merge_cand %u\n"
- "slice_qp_delta %d\n"
- "slice_cb_qp_offset %d\n"
- "slice_cr_qp_offset %d\n"
- "slice_act_y_qp_offset %d\n"
- "slice_act_cb_qp_offset %d\n"
- "slice_act_cr_qp_offset %d\n"
- "slice_beta_offset_div2 %d\n"
- "slice_tc_offset_div2 %d\n"
- "pic_struct %u\n"
- "slice_segment_addr %u\n"
- "ref_idx_l0 %s\n"
- "ref_idx_l1 %s\n"
- "short_term_ref_pic_set_size %u\n"
- "long_term_ref_pic_set_size %u\n"
- "flags %s",
- __entry->s.bit_size,
- __entry->s.data_byte_offset,
- __entry->s.num_entry_point_offsets,
- __entry->s.nal_unit_type,
- __entry->s.nuh_temporal_id_plus1,
- __entry->s.slice_type,
- __entry->s.colour_plane_id,
- __entry->s.slice_pic_order_cnt,
- __entry->s.num_ref_idx_l0_active_minus1,
- __entry->s.num_ref_idx_l1_active_minus1,
- __entry->s.collocated_ref_idx,
- __entry->s.five_minus_max_num_merge_cand,
- __entry->s.slice_qp_delta,
- __entry->s.slice_cb_qp_offset,
- __entry->s.slice_cr_qp_offset,
- __entry->s.slice_act_y_qp_offset,
- __entry->s.slice_act_cb_qp_offset,
- __entry->s.slice_act_cr_qp_offset,
- __entry->s.slice_beta_offset_div2,
- __entry->s.slice_tc_offset_div2,
- __entry->s.pic_struct,
- __entry->s.slice_segment_addr,
- __print_array(__entry->s.ref_idx_l0,
- ARRAY_SIZE(__entry->s.ref_idx_l0),
- sizeof(__entry->s.ref_idx_l0[0])),
- __print_array(__entry->s.ref_idx_l1,
- ARRAY_SIZE(__entry->s.ref_idx_l1),
- sizeof(__entry->s.ref_idx_l1[0])),
- __entry->s.short_term_ref_pic_set_size,
- __entry->s.long_term_ref_pic_set_size,
- __print_flags(__entry->s.flags, "|",
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_LUMA, "SLICE_SAO_LUMA"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_CHROMA, "SLICE_SAO_CHROMA"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_TEMPORAL_MVP_ENABLED, "SLICE_TEMPORAL_MVP_ENABLED"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_MVD_L1_ZERO, "MVD_L1_ZERO"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_CABAC_INIT, "CABAC_INIT"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_COLLOCATED_FROM_L0, "COLLOCATED_FROM_L0"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_USE_INTEGER_MV, "USE_INTEGER_MV"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_DEBLOCKING_FILTER_DISABLED, "SLICE_DEBLOCKING_FILTER_DISABLED"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED, "SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_DEPENDENT_SLICE_SEGMENT, "DEPENDENT_SLICE_SEGMENT"}
-
- ))
-);
-
-DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
- TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_hevc_pred_weight_table, p)),
- TP_fast_assign(__entry->p = *p),
- TP_printk("\ndelta_luma_weight_l0 %s\n"
- "luma_offset_l0 %s\n"
- "delta_chroma_weight_l0 {%s}\n"
- "chroma_offset_l0 {%s}\n"
- "delta_luma_weight_l1 %s\n"
- "luma_offset_l1 %s\n"
- "delta_chroma_weight_l1 {%s}\n"
- "chroma_offset_l1 {%s}\n"
- "luma_log2_weight_denom %d\n"
- "delta_chroma_log2_weight_denom %d\n",
- __print_array(__entry->p.delta_luma_weight_l0,
- ARRAY_SIZE(__entry->p.delta_luma_weight_l0),
- sizeof(__entry->p.delta_luma_weight_l0[0])),
- __print_array(__entry->p.luma_offset_l0,
- ARRAY_SIZE(__entry->p.luma_offset_l0),
- sizeof(__entry->p.luma_offset_l0[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.delta_chroma_weight_l0,
- sizeof(__entry->p.delta_chroma_weight_l0),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.chroma_offset_l0,
- sizeof(__entry->p.chroma_offset_l0),
- false),
- __print_array(__entry->p.delta_luma_weight_l1,
- ARRAY_SIZE(__entry->p.delta_luma_weight_l1),
- sizeof(__entry->p.delta_luma_weight_l1[0])),
- __print_array(__entry->p.luma_offset_l1,
- ARRAY_SIZE(__entry->p.luma_offset_l1),
- sizeof(__entry->p.luma_offset_l1[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.delta_chroma_weight_l1,
- sizeof(__entry->p.delta_chroma_weight_l1),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.chroma_offset_l1,
- sizeof(__entry->p.chroma_offset_l1),
- false),
- __entry->p.luma_log2_weight_denom,
- __entry->p.delta_chroma_log2_weight_denom
-
- ))
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_scaling_matrix, s)),
- TP_fast_assign(__entry->s = *s),
- TP_printk("\nscaling_list_4x4 {%s}\n"
- "scaling_list_8x8 {%s}\n"
- "scaling_list_16x16 {%s}\n"
- "scaling_list_32x32 {%s}\n"
- "scaling_list_dc_coef_16x16 %s\n"
- "scaling_list_dc_coef_32x32 %s\n",
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_4x4,
- sizeof(__entry->s.scaling_list_4x4),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_8x8,
- sizeof(__entry->s.scaling_list_8x8),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_16x16,
- sizeof(__entry->s.scaling_list_16x16),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_32x32,
- sizeof(__entry->s.scaling_list_32x32),
- false),
- __print_array(__entry->s.scaling_list_dc_coef_16x16,
- ARRAY_SIZE(__entry->s.scaling_list_dc_coef_16x16),
- sizeof(__entry->s.scaling_list_dc_coef_16x16[0])),
- __print_array(__entry->s.scaling_list_dc_coef_32x32,
- ARRAY_SIZE(__entry->s.scaling_list_dc_coef_32x32),
- sizeof(__entry->s.scaling_list_dc_coef_32x32[0]))
- ))
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
- TP_ARGS(d),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_decode_params, d)),
- TP_fast_assign(__entry->d = *d),
- TP_printk("\npic_order_cnt_val %d\n"
- "short_term_ref_pic_set_size %u\n"
- "long_term_ref_pic_set_size %u\n"
- "num_active_dpb_entries %u\n"
- "num_poc_st_curr_before %u\n"
- "num_poc_st_curr_after %u\n"
- "num_poc_lt_curr %u\n"
- "poc_st_curr_before %s\n"
- "poc_st_curr_after %s\n"
- "poc_lt_curr %s\n"
- "flags %s",
- __entry->d.pic_order_cnt_val,
- __entry->d.short_term_ref_pic_set_size,
- __entry->d.long_term_ref_pic_set_size,
- __entry->d.num_active_dpb_entries,
- __entry->d.num_poc_st_curr_before,
- __entry->d.num_poc_st_curr_after,
- __entry->d.num_poc_lt_curr,
- __print_array(__entry->d.poc_st_curr_before,
- ARRAY_SIZE(__entry->d.poc_st_curr_before),
- sizeof(__entry->d.poc_st_curr_before[0])),
- __print_array(__entry->d.poc_st_curr_after,
- ARRAY_SIZE(__entry->d.poc_st_curr_after),
- sizeof(__entry->d.poc_st_curr_after[0])),
- __print_array(__entry->d.poc_lt_curr,
- ARRAY_SIZE(__entry->d.poc_lt_curr),
- sizeof(__entry->d.poc_lt_curr[0])),
- __print_flags(__entry->d.flags, "|",
- {V4L2_HEVC_DECODE_PARAM_FLAG_IRAP_PIC, "IRAP_PIC"},
- {V4L2_HEVC_DECODE_PARAM_FLAG_IDR_PIC, "IDR_PIC"},
- {V4L2_HEVC_DECODE_PARAM_FLAG_NO_OUTPUT_OF_PRIOR, "NO_OUTPUT_OF_PRIOR"}
- ))
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
- TP_ARGS(lt),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_ext_sps_lt_rps, lt)),
- TP_fast_assign(__entry->lt = *lt),
- TP_printk("\nflags %s\n"
- "lt_ref_pic_poc_lsb_sps %x\n",
- __print_flags(__entry->lt.flags, "|",
- {V4L2_HEVC_EXT_SPS_LT_RPS_FLAG_USED_LT, "USED_LT"}
- ),
- __entry->lt.lt_ref_pic_poc_lsb_sps
- )
-)
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
- TP_ARGS(st),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_ext_sps_st_rps, st)),
- TP_fast_assign(__entry->st = *st),
- TP_printk("\nflags %s\n"
- "delta_idx_minus1: %u\n"
- "delta_rps_sign: %u\n"
- "abs_delta_rps_minus1: %u\n"
- "num_negative_pics: %u\n"
- "num_positive_pics: %u\n"
- "used_by_curr_pic: %08x\n"
- "use_delta_flag: %08x\n"
- "delta_poc_s0_minus1: %s\n"
- "delta_poc_s1_minus1: %s\n",
- __print_flags(__entry->st.flags, "|",
- {V4L2_HEVC_EXT_SPS_ST_RPS_FLAG_INTER_REF_PIC_SET_PRED, "INTER_REF_PIC_SET_PRED"}
- ),
- __entry->st.delta_idx_minus1,
- __entry->st.delta_rps_sign,
- __entry->st.abs_delta_rps_minus1,
- __entry->st.num_negative_pics,
- __entry->st.num_positive_pics,
- __entry->st.used_by_curr_pic,
- __entry->st.use_delta_flag,
- __print_array(__entry->st.delta_poc_s0_minus1,
- ARRAY_SIZE(__entry->st.delta_poc_s0_minus1),
- sizeof(__entry->st.delta_poc_s0_minus1[0])),
- __print_array(__entry->st.delta_poc_s1_minus1,
- ARRAY_SIZE(__entry->st.delta_poc_s1_minus1),
- sizeof(__entry->st.delta_poc_s1_minus1[0]))
- )
-)
-
-
-DECLARE_EVENT_CLASS(v4l2_hevc_dpb_entry_tmpl,
- TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
- TP_ARGS(e),
- TP_STRUCT__entry(__field_struct(struct v4l2_hevc_dpb_entry, e)),
- TP_fast_assign(__entry->e = *e),
- TP_printk("\ntimestamp %llu\n"
- "flags %s\n"
- "field_pic %u\n"
- "pic_order_cnt_val %d\n",
- __entry->e.timestamp,
- __print_flags(__entry->e.flags, "|",
- {V4L2_HEVC_DPB_ENTRY_LONG_TERM_REFERENCE, "LONG_TERM_REFERENCE"}
- ),
- __entry->e.field_pic,
- __entry->e.pic_order_cnt_val
- ))
-
-DEFINE_EVENT(v4l2_ctrl_hevc_sps_tmpl, v4l2_ctrl_hevc_sps,
- TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_ctrl_hevc_pps_tmpl, v4l2_ctrl_hevc_pps,
- TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
- TP_ARGS(p)
-);
-
-DEFINE_EVENT(v4l2_ctrl_hevc_slice_params_tmpl, v4l2_ctrl_hevc_slice_params,
- TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_hevc_pred_weight_table_tmpl, v4l2_hevc_pred_weight_table,
- TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
- TP_ARGS(p)
-);
-
-DEFINE_EVENT(v4l2_ctrl_hevc_scaling_matrix_tmpl, v4l2_ctrl_hevc_scaling_matrix,
- TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_ctrl_hevc_decode_params_tmpl, v4l2_ctrl_hevc_decode_params,
- TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
- TP_ARGS(d)
-);
-
-DEFINE_EVENT(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl, v4l2_ctrl_hevc_ext_sps_lt_rps,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
- TP_ARGS(lt)
-);
-
-DEFINE_EVENT(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl, v4l2_ctrl_hevc_ext_sps_st_rps,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
- TP_ARGS(st)
-);
-
-DEFINE_EVENT(v4l2_hevc_dpb_entry_tmpl, v4l2_hevc_dpb_entry,
- TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
- TP_ARGS(e)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-hevc
-#include <trace/define_trace.h>
diff --git a/drivers/media/test-drivers/visl/visl-trace-mpeg2.h b/drivers/media/test-drivers/visl/visl-trace-mpeg2.h
deleted file mode 100644
index ba6c65481194..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-mpeg2.h
+++ /dev/null
@@ -1,99 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#if !defined(_VISL_TRACE_MPEG2_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_MPEG2_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_mpeg2_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_seq_tmpl,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_sequence, s)),
- TP_fast_assign(__entry->s = *s;),
- TP_printk("\nhorizontal_size %u\nvertical_size %u\nvbv_buffer_size %u\n"
- "profile_and_level_indication %u\nchroma_format %u\nflags %s\n",
- __entry->s.horizontal_size,
- __entry->s.vertical_size,
- __entry->s.vbv_buffer_size,
- __entry->s.profile_and_level_indication,
- __entry->s.chroma_format,
- __print_flags(__entry->s.flags, "|",
- {V4L2_MPEG2_SEQ_FLAG_PROGRESSIVE, "PROGRESSIVE"})
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_pic_tmpl,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_picture, p)),
- TP_fast_assign(__entry->p = *p;),
- TP_printk("\nbackward_ref_ts %llu\nforward_ref_ts %llu\nflags %s\nf_code {%s}\n"
- "picture_coding_type: %u\npicture_structure %u\nintra_dc_precision %u\n",
- __entry->p.backward_ref_ts,
- __entry->p.forward_ref_ts,
- __print_flags(__entry->p.flags, "|",
- {V4L2_MPEG2_PIC_FLAG_TOP_FIELD_FIRST, "TOP_FIELD_FIRST"},
- {V4L2_MPEG2_PIC_FLAG_FRAME_PRED_DCT, "FRAME_PRED_DCT"},
- {V4L2_MPEG2_PIC_FLAG_CONCEALMENT_MV, "CONCEALMENT_MV"},
- {V4L2_MPEG2_PIC_FLAG_Q_SCALE_TYPE, "Q_SCALE_TYPE"},
- {V4L2_MPEG2_PIC_FLAG_INTRA_VLC, "INTA_VLC"},
- {V4L2_MPEG2_PIC_FLAG_ALT_SCAN, "ALT_SCAN"},
- {V4L2_MPEG2_PIC_FLAG_REPEAT_FIRST, "REPEAT_FIRST"},
- {V4L2_MPEG2_PIC_FLAG_PROGRESSIVE, "PROGRESSIVE"}),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.f_code,
- sizeof(__entry->p.f_code),
- false),
- __entry->p.picture_coding_type,
- __entry->p.picture_structure,
- __entry->p.intra_dc_precision
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_quant_tmpl,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
- TP_ARGS(q),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_quantisation, q)),
- TP_fast_assign(__entry->q = *q;),
- TP_printk("\nintra_quantiser_matrix %s\nnon_intra_quantiser_matrix %s\n"
- "chroma_intra_quantiser_matrix %s\nchroma_non_intra_quantiser_matrix %s\n",
- __print_array(__entry->q.intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.intra_quantiser_matrix),
- sizeof(__entry->q.intra_quantiser_matrix[0])),
- __print_array(__entry->q.non_intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.non_intra_quantiser_matrix),
- sizeof(__entry->q.non_intra_quantiser_matrix[0])),
- __print_array(__entry->q.chroma_intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.chroma_intra_quantiser_matrix),
- sizeof(__entry->q.chroma_intra_quantiser_matrix[0])),
- __print_array(__entry->q.chroma_non_intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.chroma_non_intra_quantiser_matrix),
- sizeof(__entry->q.chroma_non_intra_quantiser_matrix[0]))
- )
-)
-
-DEFINE_EVENT(v4l2_ctrl_mpeg2_seq_tmpl, v4l2_ctrl_mpeg2_sequence,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
- TP_ARGS(s)
-);
-
-DEFINE_EVENT(v4l2_ctrl_mpeg2_pic_tmpl, v4l2_ctrl_mpeg2_picture,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
- TP_ARGS(p)
-);
-
-DEFINE_EVENT(v4l2_ctrl_mpeg2_quant_tmpl, v4l2_ctrl_mpeg2_quantisation,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
- TP_ARGS(q)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-mpeg2
-#include <trace/define_trace.h>
diff --git a/drivers/media/test-drivers/visl/visl-trace-points.c b/drivers/media/test-drivers/visl/visl-trace-points.c
deleted file mode 100644
index 321ff732c682..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-points.c
+++ /dev/null
@@ -1,11 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0
-#include "visl.h"
-
-#define CREATE_TRACE_POINTS
-#include "visl-trace-fwht.h"
-#include "visl-trace-mpeg2.h"
-#include "visl-trace-vp8.h"
-#include "visl-trace-vp9.h"
-#include "visl-trace-h264.h"
-#include "visl-trace-hevc.h"
-#include "visl-trace-av1.h"
diff --git a/drivers/media/test-drivers/visl/visl-trace-vp8.h b/drivers/media/test-drivers/visl/visl-trace-vp8.h
deleted file mode 100644
index dabe17d69ddc..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-vp8.h
+++ /dev/null
@@ -1,156 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#if !defined(_VISL_TRACE_VP8_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_VP8_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_vp8_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp8_frame, f)),
- TP_fast_assign(__entry->f = *f;),
- TP_printk("\nentropy.coeff_probs {%s}\n"
- "entropy.y_mode_probs %s\n"
- "entropy.uv_mode_probs %s\n"
- "entropy.mv_probs {%s}",
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->f.entropy.coeff_probs,
- sizeof(__entry->f.entropy.coeff_probs),
- false),
- __print_array(__entry->f.entropy.y_mode_probs,
- ARRAY_SIZE(__entry->f.entropy.y_mode_probs),
- sizeof(__entry->f.entropy.y_mode_probs[0])),
- __print_array(__entry->f.entropy.uv_mode_probs,
- ARRAY_SIZE(__entry->f.entropy.uv_mode_probs),
- sizeof(__entry->f.entropy.uv_mode_probs[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->f.entropy.mv_probs,
- sizeof(__entry->f.entropy.mv_probs),
- false)
- )
-)
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp8_frame, f)),
- TP_fast_assign(__entry->f = *f;),
- TP_printk("\nsegment.quant_update %s\n"
- "segment.lf_update %s\n"
- "segment.segment_probs %s\n"
- "segment.flags %s\n"
- "lf.ref_frm_delta %s\n"
- "lf.mb_mode_delta %s\n"
- "lf.sharpness_level %u\n"
- "lf.level %u\n"
- "lf.flags %s\n"
- "quant.y_ac_qi %u\n"
- "quant.y_dc_delta %d\n"
- "quant.y2_dc_delta %d\n"
- "quant.y2_ac_delta %d\n"
- "quant.uv_dc_delta %d\n"
- "quant.uv_ac_delta %d\n"
- "coder_state.range %u\n"
- "coder_state.value %u\n"
- "coder_state.bit_count %u\n"
- "width %u\n"
- "height %u\n"
- "horizontal_scale %u\n"
- "vertical_scale %u\n"
- "version %u\n"
- "prob_skip_false %u\n"
- "prob_intra %u\n"
- "prob_last %u\n"
- "prob_gf %u\n"
- "num_dct_parts %u\n"
- "first_part_size %u\n"
- "first_part_header_bits %u\n"
- "dct_part_sizes %s\n"
- "last_frame_ts %llu\n"
- "golden_frame_ts %llu\n"
- "alt_frame_ts %llu\n"
- "flags %s",
- __print_array(__entry->f.segment.quant_update,
- ARRAY_SIZE(__entry->f.segment.quant_update),
- sizeof(__entry->f.segment.quant_update[0])),
- __print_array(__entry->f.segment.lf_update,
- ARRAY_SIZE(__entry->f.segment.lf_update),
- sizeof(__entry->f.segment.lf_update[0])),
- __print_array(__entry->f.segment.segment_probs,
- ARRAY_SIZE(__entry->f.segment.segment_probs),
- sizeof(__entry->f.segment.segment_probs[0])),
- __print_flags(__entry->f.segment.flags, "|",
- {V4L2_VP8_SEGMENT_FLAG_ENABLED, "SEGMENT_ENABLED"},
- {V4L2_VP8_SEGMENT_FLAG_UPDATE_MAP, "SEGMENT_UPDATE_MAP"},
- {V4L2_VP8_SEGMENT_FLAG_UPDATE_FEATURE_DATA, "SEGMENT_UPDATE_FEATURE_DATA"},
- {V4L2_VP8_SEGMENT_FLAG_DELTA_VALUE_MODE, "SEGMENT_DELTA_VALUE_MODE"}),
- __print_array(__entry->f.lf.ref_frm_delta,
- ARRAY_SIZE(__entry->f.lf.ref_frm_delta),
- sizeof(__entry->f.lf.ref_frm_delta[0])),
- __print_array(__entry->f.lf.mb_mode_delta,
- ARRAY_SIZE(__entry->f.lf.mb_mode_delta),
- sizeof(__entry->f.lf.mb_mode_delta[0])),
- __entry->f.lf.sharpness_level,
- __entry->f.lf.level,
- __print_flags(__entry->f.lf.flags, "|",
- {V4L2_VP8_LF_ADJ_ENABLE, "LF_ADJ_ENABLED"},
- {V4L2_VP8_LF_DELTA_UPDATE, "LF_DELTA_UPDATE"},
- {V4L2_VP8_LF_FILTER_TYPE_SIMPLE, "LF_FILTER_TYPE_SIMPLE"}),
- __entry->f.quant.y_ac_qi,
- __entry->f.quant.y_dc_delta,
- __entry->f.quant.y2_dc_delta,
- __entry->f.quant.y2_ac_delta,
- __entry->f.quant.uv_dc_delta,
- __entry->f.quant.uv_ac_delta,
- __entry->f.coder_state.range,
- __entry->f.coder_state.value,
- __entry->f.coder_state.bit_count,
- __entry->f.width,
- __entry->f.height,
- __entry->f.horizontal_scale,
- __entry->f.vertical_scale,
- __entry->f.version,
- __entry->f.prob_skip_false,
- __entry->f.prob_intra,
- __entry->f.prob_last,
- __entry->f.prob_gf,
- __entry->f.num_dct_parts,
- __entry->f.first_part_size,
- __entry->f.first_part_header_bits,
- __print_array(__entry->f.dct_part_sizes,
- ARRAY_SIZE(__entry->f.dct_part_sizes),
- sizeof(__entry->f.dct_part_sizes[0])),
- __entry->f.last_frame_ts,
- __entry->f.golden_frame_ts,
- __entry->f.alt_frame_ts,
- __print_flags(__entry->f.flags, "|",
- {V4L2_VP8_FRAME_FLAG_KEY_FRAME, "KEY_FRAME"},
- {V4L2_VP8_FRAME_FLAG_EXPERIMENTAL, "EXPERIMENTAL"},
- {V4L2_VP8_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
- {V4L2_VP8_FRAME_FLAG_MB_NO_SKIP_COEFF, "MB_NO_SKIP_COEFF"},
- {V4L2_VP8_FRAME_FLAG_SIGN_BIAS_GOLDEN, "SIGN_BIAS_GOLDEN"},
- {V4L2_VP8_FRAME_FLAG_SIGN_BIAS_ALT, "SIGN_BIAS_ALT"})
- )
-);
-
-DEFINE_EVENT(v4l2_ctrl_vp8_frame_tmpl, v4l2_ctrl_vp8_frame,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f)
-);
-
-DEFINE_EVENT(v4l2_ctrl_vp8_entropy_tmpl, v4l2_ctrl_vp8_entropy,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-vp8
-#include <trace/define_trace.h>
diff --git a/drivers/media/test-drivers/visl/visl-trace-vp9.h b/drivers/media/test-drivers/visl/visl-trace-vp9.h
deleted file mode 100644
index 362b92b07f93..000000000000
--- a/drivers/media/test-drivers/visl/visl-trace-vp9.h
+++ /dev/null
@@ -1,292 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#if !defined(_VISL_TRACE_VP9_H_) || defined(TRACE_HEADER_MULTI_READ)
-#define _VISL_TRACE_VP9_H_
-
-#include <linux/tracepoint.h>
-#include "visl.h"
-
-#undef TRACE_SYSTEM
-#define TRACE_SYSTEM visl_vp9_controls
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_frame, f)),
- TP_fast_assign(__entry->f = *f;),
- TP_printk("\nlf.ref_deltas %s\n"
- "lf.mode_deltas %s\n"
- "lf.level %u\n"
- "lf.sharpness %u\n"
- "lf.flags %s\n"
- "quant.base_q_idx %u\n"
- "quant.delta_q_y_dc %d\n"
- "quant.delta_q_uv_dc %d\n"
- "quant.delta_q_uv_ac %d\n"
- "seg.feature_data {%s}\n"
- "seg.feature_enabled %s\n"
- "seg.tree_probs %s\n"
- "seg.pred_probs %s\n"
- "seg.flags %s\n"
- "flags %s\n"
- "compressed_header_size %u\n"
- "uncompressed_header_size %u\n"
- "frame_width_minus_1 %u\n"
- "frame_height_minus_1 %u\n"
- "render_width_minus_1 %u\n"
- "render_height_minus_1 %u\n"
- "last_frame_ts %llu\n"
- "golden_frame_ts %llu\n"
- "alt_frame_ts %llu\n"
- "ref_frame_sign_bias %s\n"
- "reset_frame_context %s\n"
- "frame_context_idx %u\n"
- "profile %u\n"
- "bit_depth %u\n"
- "interpolation_filter %s\n"
- "tile_cols_log2 %u\n"
- "tile_rows_log_2 %u\n"
- "reference_mode %s\n",
- __print_array(__entry->f.lf.ref_deltas,
- ARRAY_SIZE(__entry->f.lf.ref_deltas),
- sizeof(__entry->f.lf.ref_deltas[0])),
- __print_array(__entry->f.lf.mode_deltas,
- ARRAY_SIZE(__entry->f.lf.mode_deltas),
- sizeof(__entry->f.lf.mode_deltas[0])),
- __entry->f.lf.level,
- __entry->f.lf.sharpness,
- __print_flags(__entry->f.lf.flags, "|",
- {V4L2_VP9_LOOP_FILTER_FLAG_DELTA_ENABLED, "DELTA_ENABLED"},
- {V4L2_VP9_LOOP_FILTER_FLAG_DELTA_UPDATE, "DELTA_UPDATE"}),
- __entry->f.quant.base_q_idx,
- __entry->f.quant.delta_q_y_dc,
- __entry->f.quant.delta_q_uv_dc,
- __entry->f.quant.delta_q_uv_ac,
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->f.seg.feature_data,
- sizeof(__entry->f.seg.feature_data),
- false),
- __print_array(__entry->f.seg.feature_enabled,
- ARRAY_SIZE(__entry->f.seg.feature_enabled),
- sizeof(__entry->f.seg.feature_enabled[0])),
- __print_array(__entry->f.seg.tree_probs,
- ARRAY_SIZE(__entry->f.seg.tree_probs),
- sizeof(__entry->f.seg.tree_probs[0])),
- __print_array(__entry->f.seg.pred_probs,
- ARRAY_SIZE(__entry->f.seg.pred_probs),
- sizeof(__entry->f.seg.pred_probs[0])),
- __print_flags(__entry->f.seg.flags, "|",
- {V4L2_VP9_SEGMENTATION_FLAG_ENABLED, "ENABLED"},
- {V4L2_VP9_SEGMENTATION_FLAG_UPDATE_MAP, "UPDATE_MAP"},
- {V4L2_VP9_SEGMENTATION_FLAG_TEMPORAL_UPDATE, "TEMPORAL_UPDATE"},
- {V4L2_VP9_SEGMENTATION_FLAG_UPDATE_DATA, "UPDATE_DATA"},
- {V4L2_VP9_SEGMENTATION_FLAG_ABS_OR_DELTA_UPDATE, "ABS_OR_DELTA_UPDATE"}),
- __print_flags(__entry->f.flags, "|",
- {V4L2_VP9_FRAME_FLAG_KEY_FRAME, "KEY_FRAME"},
- {V4L2_VP9_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
- {V4L2_VP9_FRAME_FLAG_ERROR_RESILIENT, "ERROR_RESILIENT"},
- {V4L2_VP9_FRAME_FLAG_INTRA_ONLY, "INTRA_ONLY"},
- {V4L2_VP9_FRAME_FLAG_ALLOW_HIGH_PREC_MV, "ALLOW_HIGH_PREC_MV"},
- {V4L2_VP9_FRAME_FLAG_REFRESH_FRAME_CTX, "REFRESH_FRAME_CTX"},
- {V4L2_VP9_FRAME_FLAG_PARALLEL_DEC_MODE, "PARALLEL_DEC_MODE"},
- {V4L2_VP9_FRAME_FLAG_X_SUBSAMPLING, "X_SUBSAMPLING"},
- {V4L2_VP9_FRAME_FLAG_Y_SUBSAMPLING, "Y_SUBSAMPLING"},
- {V4L2_VP9_FRAME_FLAG_COLOR_RANGE_FULL_SWING, "COLOR_RANGE_FULL_SWING"}),
- __entry->f.compressed_header_size,
- __entry->f.uncompressed_header_size,
- __entry->f.frame_width_minus_1,
- __entry->f.frame_height_minus_1,
- __entry->f.render_width_minus_1,
- __entry->f.render_height_minus_1,
- __entry->f.last_frame_ts,
- __entry->f.golden_frame_ts,
- __entry->f.alt_frame_ts,
- __print_symbolic(__entry->f.ref_frame_sign_bias,
- {V4L2_VP9_SIGN_BIAS_LAST, "SIGN_BIAS_LAST"},
- {V4L2_VP9_SIGN_BIAS_GOLDEN, "SIGN_BIAS_GOLDEN"},
- {V4L2_VP9_SIGN_BIAS_ALT, "SIGN_BIAS_ALT"}),
- __print_symbolic(__entry->f.reset_frame_context,
- {V4L2_VP9_RESET_FRAME_CTX_NONE, "RESET_FRAME_CTX_NONE"},
- {V4L2_VP9_RESET_FRAME_CTX_SPEC, "RESET_FRAME_CTX_SPEC"},
- {V4L2_VP9_RESET_FRAME_CTX_ALL, "RESET_FRAME_CTX_ALL"}),
- __entry->f.frame_context_idx,
- __entry->f.profile,
- __entry->f.bit_depth,
- __print_symbolic(__entry->f.interpolation_filter,
- {V4L2_VP9_INTERP_FILTER_EIGHTTAP, "INTERP_FILTER_EIGHTTAP"},
- {V4L2_VP9_INTERP_FILTER_EIGHTTAP_SMOOTH, "INTERP_FILTER_EIGHTTAP_SMOOTH"},
- {V4L2_VP9_INTERP_FILTER_EIGHTTAP_SHARP, "INTERP_FILTER_EIGHTTAP_SHARP"},
- {V4L2_VP9_INTERP_FILTER_BILINEAR, "INTERP_FILTER_BILINEAR"},
- {V4L2_VP9_INTERP_FILTER_SWITCHABLE, "INTERP_FILTER_SWITCHABLE"}),
- __entry->f.tile_cols_log2,
- __entry->f.tile_rows_log2,
- __print_symbolic(__entry->f.reference_mode,
- {V4L2_VP9_REFERENCE_MODE_SINGLE_REFERENCE, "REFERENCE_MODE_SINGLE_REFERENCE"},
- {V4L2_VP9_REFERENCE_MODE_COMPOUND_REFERENCE, "REFERENCE_MODE_COMPOUND_REFERENCE"},
- {V4L2_VP9_REFERENCE_MODE_SELECT, "REFERENCE_MODE_SELECT"}))
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_compressed_hdr, h)),
- TP_fast_assign(__entry->h = *h;),
- TP_printk("\ntx_mode %s\n"
- "tx8 {%s}\n"
- "tx16 {%s}\n"
- "tx32 {%s}\n"
- "skip %s\n"
- "inter_mode {%s}\n"
- "interp_filter {%s}\n"
- "is_inter %s\n"
- "comp_mode %s\n"
- "single_ref {%s}\n"
- "comp_ref %s\n"
- "y_mode {%s}\n"
- "uv_mode {%s}\n"
- "partition {%s}\n",
- __print_symbolic(__entry->h.tx_mode,
- {V4L2_VP9_TX_MODE_ONLY_4X4, "TX_MODE_ONLY_4X4"},
- {V4L2_VP9_TX_MODE_ALLOW_8X8, "TX_MODE_ALLOW_8X8"},
- {V4L2_VP9_TX_MODE_ALLOW_16X16, "TX_MODE_ALLOW_16X16"},
- {V4L2_VP9_TX_MODE_ALLOW_32X32, "TX_MODE_ALLOW_32X32"},
- {V4L2_VP9_TX_MODE_SELECT, "TX_MODE_SELECT"}),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.tx8,
- sizeof(__entry->h.tx8),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.tx16,
- sizeof(__entry->h.tx16),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.tx32,
- sizeof(__entry->h.tx32),
- false),
- __print_array(__entry->h.skip,
- ARRAY_SIZE(__entry->h.skip),
- sizeof(__entry->h.skip[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.inter_mode,
- sizeof(__entry->h.inter_mode),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.interp_filter,
- sizeof(__entry->h.interp_filter),
- false),
- __print_array(__entry->h.is_inter,
- ARRAY_SIZE(__entry->h.is_inter),
- sizeof(__entry->h.is_inter[0])),
- __print_array(__entry->h.comp_mode,
- ARRAY_SIZE(__entry->h.comp_mode),
- sizeof(__entry->h.comp_mode[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.single_ref,
- sizeof(__entry->h.single_ref),
- false),
- __print_array(__entry->h.comp_ref,
- ARRAY_SIZE(__entry->h.comp_ref),
- sizeof(__entry->h.comp_ref[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.y_mode,
- sizeof(__entry->h.y_mode),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.uv_mode,
- sizeof(__entry->h.uv_mode),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.partition,
- sizeof(__entry->h.partition),
- false)
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_coef_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_compressed_hdr, h)),
- TP_fast_assign(__entry->h = *h;),
- TP_printk("\n coef {%s}",
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.coef,
- sizeof(__entry->h.coef),
- false)
- )
-);
-
-DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
- TP_PROTO(const struct v4l2_vp9_mv_probs *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_vp9_mv_probs, p)),
- TP_fast_assign(__entry->p = *p;),
- TP_printk("\n joint %s\n"
- "sign %s\n"
- "classes {%s}\n"
- "class0_bit %s\n"
- "bits {%s}\n"
- "class0_fr {%s}\n"
- "fr {%s}\n"
- "class0_hp %s\n"
- "hp %s\n",
- __print_array(__entry->p.joint,
- ARRAY_SIZE(__entry->p.joint),
- sizeof(__entry->p.joint[0])),
- __print_array(__entry->p.sign,
- ARRAY_SIZE(__entry->p.sign),
- sizeof(__entry->p.sign[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.classes,
- sizeof(__entry->p.classes),
- false),
- __print_array(__entry->p.class0_bit,
- ARRAY_SIZE(__entry->p.class0_bit),
- sizeof(__entry->p.class0_bit[0])),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.bits,
- sizeof(__entry->p.bits),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.class0_fr,
- sizeof(__entry->p.class0_fr),
- false),
- __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.fr,
- sizeof(__entry->p.fr),
- false),
- __print_array(__entry->p.class0_hp,
- ARRAY_SIZE(__entry->p.class0_hp),
- sizeof(__entry->p.class0_hp[0])),
- __print_array(__entry->p.hp,
- ARRAY_SIZE(__entry->p.hp),
- sizeof(__entry->p.hp[0]))
- )
-);
-
-DEFINE_EVENT(v4l2_ctrl_vp9_frame_tmpl, v4l2_ctrl_vp9_frame,
- TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
- TP_ARGS(f)
-);
-
-DEFINE_EVENT(v4l2_ctrl_vp9_compressed_hdr_tmpl, v4l2_ctrl_vp9_compressed_hdr,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h)
-);
-
-DEFINE_EVENT(v4l2_ctrl_vp9_compressed_coef_tmpl, v4l2_ctrl_vp9_compressed_coeff,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h)
-);
-
-
-DEFINE_EVENT(v4l2_vp9_mv_probs_tmpl, v4l2_vp9_mv_probs,
- TP_PROTO(const struct v4l2_vp9_mv_probs *p),
- TP_ARGS(p)
-);
-
-#endif
-
-#undef TRACE_INCLUDE_PATH
-#undef TRACE_INCLUDE_FILE
-#define TRACE_INCLUDE_PATH ../../drivers/media/test-drivers/visl
-#define TRACE_INCLUDE_FILE visl-trace-vp9
-#include <trace/define_trace.h>
diff --git a/drivers/media/v4l2-core/v4l2-trace.c b/drivers/media/v4l2-core/v4l2-trace.c
index 95f3b02e1f84..183d5ecb49c5 100644
--- a/drivers/media/v4l2-core/v4l2-trace.c
+++ b/drivers/media/v4l2-core/v4l2-trace.c
@@ -5,8 +5,53 @@
#define CREATE_TRACE_POINTS
#include <trace/events/v4l2.h>
+#include <trace/events/v4l2_controls.h>
EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_v4l2_buf_done);
EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_v4l2_buf_queue);
EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_v4l2_dqbuf);
EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_v4l2_qbuf);
+
+/* Export AV1 controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_av1_sequence);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_av1_frame);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_av1_tile_group_entry);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_av1_film_grain);
+
+/* Export FWHT controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_fwht_params);
+
+/* Export H264 controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_h264_sps);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_h264_pps);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_h264_scaling_matrix);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_h264_pred_weights);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_h264_slice_params);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_h264_ref_pic_list0);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_h264_ref_pic_list1);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_h264_decode_params);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_h264_dpb_entry);
+
+/* Export HEVC controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_hevc_sps);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_hevc_pps);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_hevc_slice_params);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_hevc_pred_weight_table);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_hevc_scaling_matrix);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_hevc_decode_params);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_hevc_dpb_entry);
+
+/* Export MPEG2 controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_mpeg2_sequence);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_mpeg2_picture);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_mpeg2_quantisation);
+
+/* Export VP8 controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_vp8_frame);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_vp8_entropy);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_vp9_frame);
+
+/* Export VP9 controls */
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_vp9_compressed_hdr);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_ctrl_vp9_compressed_coeff);
+EXPORT_TRACEPOINT_SYMBOL_GPL(v4l2_vp9_mv_probs);
diff --git a/include/trace/events/v4l2_controls.h b/include/trace/events/v4l2_controls.h
new file mode 100644
index 000000000000..9c74309b31ef
--- /dev/null
+++ b/include/trace/events/v4l2_controls.h
@@ -0,0 +1,1645 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#if !defined(_TRACE_V4L2_CONTROLS_H_) || defined(TRACE_HEADER_MULTI_READ)
+#define _TRACE_V4L2_CONTROLS_H_
+
+#include <linux/tracepoint.h>
+#include <linux/v4l2-controls.h>
+
+#undef TRACE_SYSTEM
+#define TRACE_SYSTEM v4l2_controls
+
+/* AV1 controls */
+DECLARE_EVENT_CLASS(v4l2_ctrl_av1_seq_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_sequence, s)),
+ TP_fast_assign(__entry->s = *s;),
+ TP_printk("\nflags %s\nseq_profile: %u\norder_hint_bits: %u\nbit_depth: %u\n"
+ "max_frame_width_minus_1: %u\nmax_frame_height_minus_1: %u\n",
+ __print_flags(__entry->s.flags, "|",
+ {V4L2_AV1_SEQUENCE_FLAG_STILL_PICTURE, "STILL_PICTURE"},
+ {V4L2_AV1_SEQUENCE_FLAG_USE_128X128_SUPERBLOCK, "USE_128X128_SUPERBLOCK"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_FILTER_INTRA, "ENABLE_FILTER_INTRA"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_INTRA_EDGE_FILTER, "ENABLE_INTRA_EDGE_FILTER"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_INTERINTRA_COMPOUND, "ENABLE_INTERINTRA_COMPOUND"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_MASKED_COMPOUND, "ENABLE_MASKED_COMPOUND"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_WARPED_MOTION, "ENABLE_WARPED_MOTION"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_DUAL_FILTER, "ENABLE_DUAL_FILTER"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_ORDER_HINT, "ENABLE_ORDER_HINT"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_JNT_COMP, "ENABLE_JNT_COMP"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_REF_FRAME_MVS, "ENABLE_REF_FRAME_MVS"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_SUPERRES, "ENABLE_SUPERRES"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_CDEF, "ENABLE_CDEF"},
+ {V4L2_AV1_SEQUENCE_FLAG_ENABLE_RESTORATION, "ENABLE_RESTORATION"},
+ {V4L2_AV1_SEQUENCE_FLAG_MONO_CHROME, "MONO_CHROME"},
+ {V4L2_AV1_SEQUENCE_FLAG_COLOR_RANGE, "COLOR_RANGE"},
+ {V4L2_AV1_SEQUENCE_FLAG_SUBSAMPLING_X, "SUBSAMPLING_X"},
+ {V4L2_AV1_SEQUENCE_FLAG_SUBSAMPLING_Y, "SUBSAMPLING_Y"},
+ {V4L2_AV1_SEQUENCE_FLAG_FILM_GRAIN_PARAMS_PRESENT, "FILM_GRAIN_PARAMS_PRESENT"},
+ {V4L2_AV1_SEQUENCE_FLAG_SEPARATE_UV_DELTA_Q, "SEPARATE_UV_DELTA_Q"}),
+ __entry->s.seq_profile,
+ __entry->s.order_hint_bits,
+ __entry->s.bit_depth,
+ __entry->s.max_frame_width_minus_1,
+ __entry->s.max_frame_height_minus_1
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_av1_tge_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
+ TP_ARGS(t),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_tile_group_entry, t)),
+ TP_fast_assign(__entry->t = *t;),
+ TP_printk("\ntile_offset: %u\n tile_size: %u\n tile_row: %u\ntile_col: %u\n",
+ __entry->t.tile_offset,
+ __entry->t.tile_size,
+ __entry->t.tile_row,
+ __entry->t.tile_col
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
+ TP_ARGS(f),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_frame, f)),
+ TP_fast_assign(__entry->f = *f;),
+ TP_printk("\ntile_info.flags: %s\ntile_info.context_update_tile_id: %u\n"
+ "tile_info.tile_cols: %u\ntile_info.tile_rows: %u\n"
+ "tile_info.mi_col_starts: %s\ntile_info.mi_row_starts: %s\n"
+ "tile_info.width_in_sbs_minus_1: %s\ntile_info.height_in_sbs_minus_1: %s\n"
+ "tile_info.tile_size_bytes: %u\nquantization.flags: %s\n"
+ "quantization.base_q_idx: %u\nquantization.delta_q_y_dc: %d\n"
+ "quantization.delta_q_u_dc: %d\nquantization.delta_q_u_ac: %d\n"
+ "quantization.delta_q_v_dc: %d\nquantization.delta_q_v_ac: %d\n"
+ "quantization.qm_y: %u\nquantization.qm_u: %u\nquantization.qm_v: %u\n"
+ "quantization.delta_q_res: %u\nsuperres_denom: %u\nsegmentation.flags: %s\n"
+ "segmentation.last_active_seg_id: %u\nsegmentation.feature_enabled:%s\n"
+ "loop_filter.flags: %s\nloop_filter.level: %s\nloop_filter.sharpness: %u\n"
+ "loop_filter.ref_deltas: %s\nloop_filter.mode_deltas: %s\n"
+ "loop_filter.delta_lf_res: %u\ncdef.damping_minus_3: %u\ncdef.bits: %u\n"
+ "cdef.y_pri_strength: %s\ncdef.y_sec_strength: %s\n"
+ "cdef.uv_pri_strength: %s\ncdef.uv_sec_strength:%s\nskip_mode_frame: %s\n"
+ "primary_ref_frame: %u\nloop_restoration.flags: %s\n"
+ "loop_restoration.lr_unit_shift: %u\nloop_restoration.lr_uv_shift: %u\n"
+ "loop_restoration.frame_restoration_type: %s\n"
+ "loop_restoration.loop_restoration_size: %s\nflags: %s\norder_hint: %u\n"
+ "upscaled_width: %u\nframe_width_minus_1: %u\nframe_height_minus_1: %u\n"
+ "render_width_minus_1: %u\nrender_height_minus_1: %u\ncurrent_frame_id: %u\n"
+ "buffer_removal_time: %s\norder_hints: %s\nreference_frame_ts: %s\n"
+ "ref_frame_idx: %s\nrefresh_frame_flags: %u\n",
+ __print_flags(__entry->f.tile_info.flags, "|",
+ {V4L2_AV1_TILE_INFO_FLAG_UNIFORM_TILE_SPACING, "UNIFORM_TILE_SPACING"}),
+ __entry->f.tile_info.context_update_tile_id,
+ __entry->f.tile_info.tile_cols,
+ __entry->f.tile_info.tile_rows,
+ __print_array(__entry->f.tile_info.mi_col_starts,
+ ARRAY_SIZE(__entry->f.tile_info.mi_col_starts),
+ sizeof(__entry->f.tile_info.mi_col_starts[0])),
+ __print_array(__entry->f.tile_info.mi_row_starts,
+ ARRAY_SIZE(__entry->f.tile_info.mi_row_starts),
+ sizeof(__entry->f.tile_info.mi_row_starts[0])),
+ __print_array(__entry->f.tile_info.width_in_sbs_minus_1,
+ ARRAY_SIZE(__entry->f.tile_info.width_in_sbs_minus_1),
+ sizeof(__entry->f.tile_info.width_in_sbs_minus_1[0])),
+ __print_array(__entry->f.tile_info.height_in_sbs_minus_1,
+ ARRAY_SIZE(__entry->f.tile_info.height_in_sbs_minus_1),
+ sizeof(__entry->f.tile_info.height_in_sbs_minus_1[0])),
+ __entry->f.tile_info.tile_size_bytes,
+ __print_flags(__entry->f.quantization.flags, "|",
+ {V4L2_AV1_QUANTIZATION_FLAG_DIFF_UV_DELTA, "DIFF_UV_DELTA"},
+ {V4L2_AV1_QUANTIZATION_FLAG_USING_QMATRIX, "USING_QMATRIX"},
+ {V4L2_AV1_QUANTIZATION_FLAG_DELTA_Q_PRESENT, "DELTA_Q_PRESENT"}),
+ __entry->f.quantization.base_q_idx,
+ __entry->f.quantization.delta_q_y_dc,
+ __entry->f.quantization.delta_q_u_dc,
+ __entry->f.quantization.delta_q_u_ac,
+ __entry->f.quantization.delta_q_v_dc,
+ __entry->f.quantization.delta_q_v_ac,
+ __entry->f.quantization.qm_y,
+ __entry->f.quantization.qm_u,
+ __entry->f.quantization.qm_v,
+ __entry->f.quantization.delta_q_res,
+ __entry->f.superres_denom,
+ __print_flags(__entry->f.segmentation.flags, "|",
+ {V4L2_AV1_SEGMENTATION_FLAG_ENABLED, "ENABLED"},
+ {V4L2_AV1_SEGMENTATION_FLAG_UPDATE_MAP, "UPDATE_MAP"},
+ {V4L2_AV1_SEGMENTATION_FLAG_TEMPORAL_UPDATE, "TEMPORAL_UPDATE"},
+ {V4L2_AV1_SEGMENTATION_FLAG_UPDATE_DATA, "UPDATE_DATA"},
+ {V4L2_AV1_SEGMENTATION_FLAG_SEG_ID_PRE_SKIP, "SEG_ID_PRE_SKIP"}),
+ __entry->f.segmentation.last_active_seg_id,
+ __print_array(__entry->f.segmentation.feature_enabled,
+ ARRAY_SIZE(__entry->f.segmentation.feature_enabled),
+ sizeof(__entry->f.segmentation.feature_enabled[0])),
+ __print_flags(__entry->f.loop_filter.flags, "|",
+ {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_ENABLED, "DELTA_ENABLED"},
+ {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_UPDATE, "DELTA_UPDATE"},
+ {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_LF_PRESENT, "DELTA_LF_PRESENT"},
+ {V4L2_AV1_LOOP_FILTER_FLAG_DELTA_LF_MULTI, "DELTA_LF_MULTI"}),
+ __print_array(__entry->f.loop_filter.level,
+ ARRAY_SIZE(__entry->f.loop_filter.level),
+ sizeof(__entry->f.loop_filter.level[0])),
+ __entry->f.loop_filter.sharpness,
+ __print_array(__entry->f.loop_filter.ref_deltas,
+ ARRAY_SIZE(__entry->f.loop_filter.ref_deltas),
+ sizeof(__entry->f.loop_filter.ref_deltas[0])),
+ __print_array(__entry->f.loop_filter.mode_deltas,
+ ARRAY_SIZE(__entry->f.loop_filter.mode_deltas),
+ sizeof(__entry->f.loop_filter.mode_deltas[0])),
+ __entry->f.loop_filter.delta_lf_res,
+ __entry->f.cdef.damping_minus_3,
+ __entry->f.cdef.bits,
+ __print_array(__entry->f.cdef.y_pri_strength,
+ ARRAY_SIZE(__entry->f.cdef.y_pri_strength),
+ sizeof(__entry->f.cdef.y_pri_strength[0])),
+ __print_array(__entry->f.cdef.y_sec_strength,
+ ARRAY_SIZE(__entry->f.cdef.y_sec_strength),
+ sizeof(__entry->f.cdef.y_sec_strength[0])),
+ __print_array(__entry->f.cdef.uv_pri_strength,
+ ARRAY_SIZE(__entry->f.cdef.uv_pri_strength),
+ sizeof(__entry->f.cdef.uv_pri_strength[0])),
+ __print_array(__entry->f.cdef.uv_sec_strength,
+ ARRAY_SIZE(__entry->f.cdef.uv_sec_strength),
+ sizeof(__entry->f.cdef.uv_sec_strength[0])),
+ __print_array(__entry->f.skip_mode_frame,
+ ARRAY_SIZE(__entry->f.skip_mode_frame),
+ sizeof(__entry->f.skip_mode_frame[0])),
+ __entry->f.primary_ref_frame,
+ __print_flags(__entry->f.loop_restoration.flags, "|",
+ {V4L2_AV1_LOOP_RESTORATION_FLAG_USES_LR, "USES_LR"},
+ {V4L2_AV1_LOOP_RESTORATION_FLAG_USES_CHROMA_LR, "USES_CHROMA_LR"}),
+ __entry->f.loop_restoration.lr_unit_shift,
+ __entry->f.loop_restoration.lr_uv_shift,
+ __print_array(__entry->f.loop_restoration.frame_restoration_type,
+ ARRAY_SIZE(__entry->f.loop_restoration.frame_restoration_type),
+ sizeof(__entry->f.loop_restoration.frame_restoration_type[0])),
+ __print_array(__entry->f.loop_restoration.loop_restoration_size,
+ ARRAY_SIZE(__entry->f.loop_restoration.loop_restoration_size),
+ sizeof(__entry->f.loop_restoration.loop_restoration_size[0])),
+ __print_flags(__entry->f.flags, "|",
+ {V4L2_AV1_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
+ {V4L2_AV1_FRAME_FLAG_SHOWABLE_FRAME, "SHOWABLE_FRAME"},
+ {V4L2_AV1_FRAME_FLAG_ERROR_RESILIENT_MODE, "ERROR_RESILIENT_MODE"},
+ {V4L2_AV1_FRAME_FLAG_DISABLE_CDF_UPDATE, "DISABLE_CDF_UPDATE"},
+ {V4L2_AV1_FRAME_FLAG_ALLOW_SCREEN_CONTENT_TOOLS, "ALLOW_SCREEN_CONTENT_TOOLS"},
+ {V4L2_AV1_FRAME_FLAG_FORCE_INTEGER_MV, "FORCE_INTEGER_MV"},
+ {V4L2_AV1_FRAME_FLAG_ALLOW_INTRABC, "ALLOW_INTRABC"},
+ {V4L2_AV1_FRAME_FLAG_USE_SUPERRES, "USE_SUPERRES"},
+ {V4L2_AV1_FRAME_FLAG_ALLOW_HIGH_PRECISION_MV, "ALLOW_HIGH_PRECISION_MV"},
+ {V4L2_AV1_FRAME_FLAG_IS_MOTION_MODE_SWITCHABLE, "IS_MOTION_MODE_SWITCHABLE"},
+ {V4L2_AV1_FRAME_FLAG_USE_REF_FRAME_MVS, "USE_REF_FRAME_MVS"},
+ {V4L2_AV1_FRAME_FLAG_DISABLE_FRAME_END_UPDATE_CDF,
+ "DISABLE_FRAME_END_UPDATE_CDF"},
+ {V4L2_AV1_FRAME_FLAG_ALLOW_WARPED_MOTION, "ALLOW_WARPED_MOTION"},
+ {V4L2_AV1_FRAME_FLAG_REFERENCE_SELECT, "REFERENCE_SELECT"},
+ {V4L2_AV1_FRAME_FLAG_REDUCED_TX_SET, "REDUCED_TX_SET"},
+ {V4L2_AV1_FRAME_FLAG_SKIP_MODE_ALLOWED, "SKIP_MODE_ALLOWED"},
+ {V4L2_AV1_FRAME_FLAG_SKIP_MODE_PRESENT, "SKIP_MODE_PRESENT"},
+ {V4L2_AV1_FRAME_FLAG_FRAME_SIZE_OVERRIDE, "FRAME_SIZE_OVERRIDE"},
+ {V4L2_AV1_FRAME_FLAG_BUFFER_REMOVAL_TIME_PRESENT, "BUFFER_REMOVAL_TIME_PRESENT"},
+ {V4L2_AV1_FRAME_FLAG_FRAME_REFS_SHORT_SIGNALING, "FRAME_REFS_SHORT_SIGNALING"}),
+ __entry->f.order_hint,
+ __entry->f.upscaled_width,
+ __entry->f.frame_width_minus_1,
+ __entry->f.frame_height_minus_1,
+ __entry->f.render_width_minus_1,
+ __entry->f.render_height_minus_1,
+ __entry->f.current_frame_id,
+ __print_array(__entry->f.buffer_removal_time,
+ ARRAY_SIZE(__entry->f.buffer_removal_time),
+ sizeof(__entry->f.buffer_removal_time[0])),
+ __print_array(__entry->f.order_hints,
+ ARRAY_SIZE(__entry->f.order_hints),
+ sizeof(__entry->f.order_hints[0])),
+ __print_array(__entry->f.reference_frame_ts,
+ ARRAY_SIZE(__entry->f.reference_frame_ts),
+ sizeof(__entry->f.reference_frame_ts[0])),
+ __print_array(__entry->f.ref_frame_idx,
+ ARRAY_SIZE(__entry->f.ref_frame_idx),
+ sizeof(__entry->f.ref_frame_idx[0])),
+ __entry->f.refresh_frame_flags
+ )
+);
+
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
+ TP_ARGS(f),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_film_grain, f)),
+ TP_fast_assign(__entry->f = *f;),
+ TP_printk("\nflags %s\ncr_mult: %u\ngrain_seed: %u\n"
+ "film_grain_params_ref_idx: %u\nnum_y_points: %u\npoint_y_value: %s\n"
+ "point_y_scaling: %s\nnum_cb_points: %u\npoint_cb_value: %s\n"
+ "point_cb_scaling: %s\nnum_cr_points: %u\npoint_cr_value: %s\n"
+ "point_cr_scaling: %s\ngrain_scaling_minus_8: %u\nar_coeff_lag: %u\n"
+ "ar_coeffs_y_plus_128: %s\nar_coeffs_cb_plus_128: %s\n"
+ "ar_coeffs_cr_plus_128: %s\nar_coeff_shift_minus_6: %u\n"
+ "grain_scale_shift: %u\ncb_mult: %u\ncb_luma_mult: %u\ncr_luma_mult: %u\n"
+ "cb_offset: %u\ncr_offset: %u\n",
+ __print_flags(__entry->f.flags, "|",
+ {V4L2_AV1_FILM_GRAIN_FLAG_APPLY_GRAIN, "APPLY_GRAIN"},
+ {V4L2_AV1_FILM_GRAIN_FLAG_UPDATE_GRAIN, "UPDATE_GRAIN"},
+ {V4L2_AV1_FILM_GRAIN_FLAG_CHROMA_SCALING_FROM_LUMA, "CHROMA_SCALING_FROM_LUMA"},
+ {V4L2_AV1_FILM_GRAIN_FLAG_OVERLAP, "OVERLAP"},
+ {V4L2_AV1_FILM_GRAIN_FLAG_CLIP_TO_RESTRICTED_RANGE, "CLIP_TO_RESTRICTED_RANGE"}),
+ __entry->f.cr_mult,
+ __entry->f.grain_seed,
+ __entry->f.film_grain_params_ref_idx,
+ __entry->f.num_y_points,
+ __print_array(__entry->f.point_y_value,
+ ARRAY_SIZE(__entry->f.point_y_value),
+ sizeof(__entry->f.point_y_value[0])),
+ __print_array(__entry->f.point_y_scaling,
+ ARRAY_SIZE(__entry->f.point_y_scaling),
+ sizeof(__entry->f.point_y_scaling[0])),
+ __entry->f.num_cb_points,
+ __print_array(__entry->f.point_cb_value,
+ ARRAY_SIZE(__entry->f.point_cb_value),
+ sizeof(__entry->f.point_cb_value[0])),
+ __print_array(__entry->f.point_cb_scaling,
+ ARRAY_SIZE(__entry->f.point_cb_scaling),
+ sizeof(__entry->f.point_cb_scaling[0])),
+ __entry->f.num_cr_points,
+ __print_array(__entry->f.point_cr_value,
+ ARRAY_SIZE(__entry->f.point_cr_value),
+ sizeof(__entry->f.point_cr_value[0])),
+ __print_array(__entry->f.point_cr_scaling,
+ ARRAY_SIZE(__entry->f.point_cr_scaling),
+ sizeof(__entry->f.point_cr_scaling[0])),
+ __entry->f.grain_scaling_minus_8,
+ __entry->f.ar_coeff_lag,
+ __print_array(__entry->f.ar_coeffs_y_plus_128,
+ ARRAY_SIZE(__entry->f.ar_coeffs_y_plus_128),
+ sizeof(__entry->f.ar_coeffs_y_plus_128[0])),
+ __print_array(__entry->f.ar_coeffs_cb_plus_128,
+ ARRAY_SIZE(__entry->f.ar_coeffs_cb_plus_128),
+ sizeof(__entry->f.ar_coeffs_cb_plus_128[0])),
+ __print_array(__entry->f.ar_coeffs_cr_plus_128,
+ ARRAY_SIZE(__entry->f.ar_coeffs_cr_plus_128),
+ sizeof(__entry->f.ar_coeffs_cr_plus_128[0])),
+ __entry->f.ar_coeff_shift_minus_6,
+ __entry->f.grain_scale_shift,
+ __entry->f.cb_mult,
+ __entry->f.cb_luma_mult,
+ __entry->f.cr_luma_mult,
+ __entry->f.cb_offset,
+ __entry->f.cr_offset
+ )
+)
+
+DEFINE_EVENT(v4l2_ctrl_av1_seq_tmpl, v4l2_ctrl_av1_sequence,
+ TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_ctrl_av1_frame_tmpl, v4l2_ctrl_av1_frame,
+ TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
+ TP_ARGS(f)
+);
+
+DEFINE_EVENT(v4l2_ctrl_av1_tge_tmpl, v4l2_ctrl_av1_tile_group_entry,
+ TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
+ TP_ARGS(t)
+);
+
+DEFINE_EVENT(v4l2_ctrl_av1_film_grain_tmpl, v4l2_ctrl_av1_film_grain,
+ TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
+ TP_ARGS(f)
+);
+
+/* FWHT controls */
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_fwht_params *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(
+ __field(u64, backward_ref_ts)
+ __field(u32, version)
+ __field(u32, width)
+ __field(u32, height)
+ __field(u32, flags)
+ __field(u32, colorspace)
+ __field(u32, xfer_func)
+ __field(u32, ycbcr_enc)
+ __field(u32, quantization)
+ ),
+ TP_fast_assign(
+ __entry->backward_ref_ts = p->backward_ref_ts;
+ __entry->version = p->version;
+ __entry->width = p->width;
+ __entry->height = p->height;
+ __entry->flags = p->flags;
+ __entry->colorspace = p->colorspace;
+ __entry->xfer_func = p->xfer_func;
+ __entry->ycbcr_enc = p->ycbcr_enc;
+ __entry->quantization = p->quantization;
+ ),
+ TP_printk("backward_ref_ts %llu version %u width %u height %u flags %s colorspace %u xfer_func %u ycbcr_enc %u quantization %u",
+ __entry->backward_ref_ts, __entry->version, __entry->width, __entry->height,
+ __print_flags(__entry->flags, "|",
+ {V4L2_FWHT_FL_IS_INTERLACED, "IS_INTERLACED"},
+ {V4L2_FWHT_FL_IS_BOTTOM_FIRST, "IS_BOTTOM_FIRST"},
+ {V4L2_FWHT_FL_IS_ALTERNATE, "IS_ALTERNATE"},
+ {V4L2_FWHT_FL_IS_BOTTOM_FIELD, "IS_BOTTOM_FIELD"},
+ {V4L2_FWHT_FL_LUMA_IS_UNCOMPRESSED, "LUMA_IS_UNCOMPRESSED"},
+ {V4L2_FWHT_FL_CB_IS_UNCOMPRESSED, "CB_IS_UNCOMPRESSED"},
+ {V4L2_FWHT_FL_CR_IS_UNCOMPRESSED, "CR_IS_UNCOMPRESSED"},
+ {V4L2_FWHT_FL_ALPHA_IS_UNCOMPRESSED, "ALPHA_IS_UNCOMPRESSED"},
+ {V4L2_FWHT_FL_I_FRAME, "I_FRAME"},
+ {V4L2_FWHT_FL_PIXENC_HSV, "PIXENC_HSV"},
+ {V4L2_FWHT_FL_PIXENC_RGB, "PIXENC_RGB"},
+ {V4L2_FWHT_FL_PIXENC_YUV, "PIXENC_YUV"}),
+ __entry->colorspace, __entry->xfer_func, __entry->ycbcr_enc,
+ __entry->quantization)
+);
+
+DEFINE_EVENT(v4l2_ctrl_fwht_params_tmpl, v4l2_ctrl_fwht_params,
+ TP_PROTO(const struct v4l2_ctrl_fwht_params *p),
+ TP_ARGS(p)
+);
+
+/* H264 controls */
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_sps, s)),
+ TP_fast_assign(__entry->s = *s),
+ TP_printk("\nprofile_idc %u\n"
+ "constraint_set_flags %s\n"
+ "level_idc %u\n"
+ "seq_parameter_set_id %u\n"
+ "chroma_format_idc %u\n"
+ "bit_depth_luma_minus8 %u\n"
+ "bit_depth_chroma_minus8 %u\n"
+ "log2_max_frame_num_minus4 %u\n"
+ "pic_order_cnt_type %u\n"
+ "log2_max_pic_order_cnt_lsb_minus4 %u\n"
+ "max_num_ref_frames %u\n"
+ "num_ref_frames_in_pic_order_cnt_cycle %u\n"
+ "offset_for_ref_frame %s\n"
+ "offset_for_non_ref_pic %d\n"
+ "offset_for_top_to_bottom_field %d\n"
+ "pic_width_in_mbs_minus1 %u\n"
+ "pic_height_in_map_units_minus1 %u\n"
+ "flags %s",
+ __entry->s.profile_idc,
+ __print_flags(__entry->s.constraint_set_flags, "|",
+ {V4L2_H264_SPS_CONSTRAINT_SET0_FLAG, "CONSTRAINT_SET0_FLAG"},
+ {V4L2_H264_SPS_CONSTRAINT_SET1_FLAG, "CONSTRAINT_SET1_FLAG"},
+ {V4L2_H264_SPS_CONSTRAINT_SET2_FLAG, "CONSTRAINT_SET2_FLAG"},
+ {V4L2_H264_SPS_CONSTRAINT_SET3_FLAG, "CONSTRAINT_SET3_FLAG"},
+ {V4L2_H264_SPS_CONSTRAINT_SET4_FLAG, "CONSTRAINT_SET4_FLAG"},
+ {V4L2_H264_SPS_CONSTRAINT_SET5_FLAG, "CONSTRAINT_SET5_FLAG"}),
+ __entry->s.level_idc,
+ __entry->s.seq_parameter_set_id,
+ __entry->s.chroma_format_idc,
+ __entry->s.bit_depth_luma_minus8,
+ __entry->s.bit_depth_chroma_minus8,
+ __entry->s.log2_max_frame_num_minus4,
+ __entry->s.pic_order_cnt_type,
+ __entry->s.log2_max_pic_order_cnt_lsb_minus4,
+ __entry->s.max_num_ref_frames,
+ __entry->s.num_ref_frames_in_pic_order_cnt_cycle,
+ __print_array(__entry->s.offset_for_ref_frame,
+ ARRAY_SIZE(__entry->s.offset_for_ref_frame),
+ sizeof(__entry->s.offset_for_ref_frame[0])),
+ __entry->s.offset_for_non_ref_pic,
+ __entry->s.offset_for_top_to_bottom_field,
+ __entry->s.pic_width_in_mbs_minus1,
+ __entry->s.pic_height_in_map_units_minus1,
+ __print_flags(__entry->s.flags, "|",
+ {V4L2_H264_SPS_FLAG_SEPARATE_COLOUR_PLANE, "SEPARATE_COLOUR_PLANE"},
+ {V4L2_H264_SPS_FLAG_QPPRIME_Y_ZERO_TRANSFORM_BYPASS, "QPPRIME_Y_ZERO_TRANSFORM_BYPASS"},
+ {V4L2_H264_SPS_FLAG_DELTA_PIC_ORDER_ALWAYS_ZERO, "DELTA_PIC_ORDER_ALWAYS_ZERO"},
+ {V4L2_H264_SPS_FLAG_GAPS_IN_FRAME_NUM_VALUE_ALLOWED, "GAPS_IN_FRAME_NUM_VALUE_ALLOWED"},
+ {V4L2_H264_SPS_FLAG_FRAME_MBS_ONLY, "FRAME_MBS_ONLY"},
+ {V4L2_H264_SPS_FLAG_MB_ADAPTIVE_FRAME_FIELD, "MB_ADAPTIVE_FRAME_FIELD"},
+ {V4L2_H264_SPS_FLAG_DIRECT_8X8_INFERENCE, "DIRECT_8X8_INFERENCE"}
+ ))
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_pps, p)),
+ TP_fast_assign(__entry->p = *p),
+ TP_printk("\npic_parameter_set_id %u\n"
+ "seq_parameter_set_id %u\n"
+ "num_slice_groups_minus1 %u\n"
+ "num_ref_idx_l0_default_active_minus1 %u\n"
+ "num_ref_idx_l1_default_active_minus1 %u\n"
+ "weighted_bipred_idc %u\n"
+ "pic_init_qp_minus26 %d\n"
+ "pic_init_qs_minus26 %d\n"
+ "chroma_qp_index_offset %d\n"
+ "second_chroma_qp_index_offset %d\n"
+ "flags %s",
+ __entry->p.pic_parameter_set_id,
+ __entry->p.seq_parameter_set_id,
+ __entry->p.num_slice_groups_minus1,
+ __entry->p.num_ref_idx_l0_default_active_minus1,
+ __entry->p.num_ref_idx_l1_default_active_minus1,
+ __entry->p.weighted_bipred_idc,
+ __entry->p.pic_init_qp_minus26,
+ __entry->p.pic_init_qs_minus26,
+ __entry->p.chroma_qp_index_offset,
+ __entry->p.second_chroma_qp_index_offset,
+ __print_flags(__entry->p.flags, "|",
+ {V4L2_H264_PPS_FLAG_ENTROPY_CODING_MODE, "ENTROPY_CODING_MODE"},
+ {V4L2_H264_PPS_FLAG_BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT, "BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT"},
+ {V4L2_H264_PPS_FLAG_WEIGHTED_PRED, "WEIGHTED_PRED"},
+ {V4L2_H264_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT, "DEBLOCKING_FILTER_CONTROL_PRESENT"},
+ {V4L2_H264_PPS_FLAG_CONSTRAINED_INTRA_PRED, "CONSTRAINED_INTRA_PRED"},
+ {V4L2_H264_PPS_FLAG_REDUNDANT_PIC_CNT_PRESENT, "REDUNDANT_PIC_CNT_PRESENT"},
+ {V4L2_H264_PPS_FLAG_TRANSFORM_8X8_MODE, "TRANSFORM_8X8_MODE"},
+ {V4L2_H264_PPS_FLAG_SCALING_MATRIX_PRESENT, "SCALING_MATRIX_PRESENT"}
+ ))
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_h264_scaling_matrix_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_scaling_matrix, s)),
+ TP_fast_assign(__entry->s = *s),
+ TP_printk("\nscaling_list_4x4 {%s}\nscaling_list_8x8 {%s}",
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->s.scaling_list_4x4,
+ sizeof(__entry->s.scaling_list_4x4),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->s.scaling_list_8x8,
+ sizeof(__entry->s.scaling_list_8x8),
+ false)
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_pred_weights, p)),
+ TP_fast_assign(__entry->p = *p),
+ TP_printk("\nluma_log2_weight_denom %u\n"
+ "chroma_log2_weight_denom %u\n"
+ "weight_factor[0].luma_weight %s\n"
+ "weight_factor[0].luma_offset %s\n"
+ "weight_factor[0].chroma_weight {%s}\n"
+ "weight_factor[0].chroma_offset {%s}\n"
+ "weight_factor[1].luma_weight %s\n"
+ "weight_factor[1].luma_offset %s\n"
+ "weight_factor[1].chroma_weight {%s}\n"
+ "weight_factor[1].chroma_offset {%s}\n",
+ __entry->p.luma_log2_weight_denom,
+ __entry->p.chroma_log2_weight_denom,
+ __print_array(__entry->p.weight_factors[0].luma_weight,
+ ARRAY_SIZE(__entry->p.weight_factors[0].luma_weight),
+ sizeof(__entry->p.weight_factors[0].luma_weight[0])),
+ __print_array(__entry->p.weight_factors[0].luma_offset,
+ ARRAY_SIZE(__entry->p.weight_factors[0].luma_offset),
+ sizeof(__entry->p.weight_factors[0].luma_offset[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.weight_factors[0].chroma_weight,
+ sizeof(__entry->p.weight_factors[0].chroma_weight),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.weight_factors[0].chroma_offset,
+ sizeof(__entry->p.weight_factors[0].chroma_offset),
+ false),
+ __print_array(__entry->p.weight_factors[1].luma_weight,
+ ARRAY_SIZE(__entry->p.weight_factors[1].luma_weight),
+ sizeof(__entry->p.weight_factors[1].luma_weight[0])),
+ __print_array(__entry->p.weight_factors[1].luma_offset,
+ ARRAY_SIZE(__entry->p.weight_factors[1].luma_offset),
+ sizeof(__entry->p.weight_factors[1].luma_offset[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.weight_factors[1].chroma_weight,
+ sizeof(__entry->p.weight_factors[1].chroma_weight),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.weight_factors[1].chroma_offset,
+ sizeof(__entry->p.weight_factors[1].chroma_offset),
+ false)
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_slice_params, s)),
+ TP_fast_assign(__entry->s = *s),
+ TP_printk("\nheader_bit_size %u\n"
+ "first_mb_in_slice %u\n"
+ "slice_type %s\n"
+ "colour_plane_id %u\n"
+ "redundant_pic_cnt %u\n"
+ "cabac_init_idc %u\n"
+ "slice_qp_delta %d\n"
+ "slice_qs_delta %d\n"
+ "disable_deblocking_filter_idc %u\n"
+ "slice_alpha_c0_offset_div2 %u\n"
+ "slice_beta_offset_div2 %u\n"
+ "num_ref_idx_l0_active_minus1 %u\n"
+ "num_ref_idx_l1_active_minus1 %u\n"
+ "flags %s",
+ __entry->s.header_bit_size,
+ __entry->s.first_mb_in_slice,
+ __print_symbolic(__entry->s.slice_type,
+ {V4L2_H264_SLICE_TYPE_P, "P"},
+ {V4L2_H264_SLICE_TYPE_B, "B"},
+ {V4L2_H264_SLICE_TYPE_I, "I"},
+ {V4L2_H264_SLICE_TYPE_SP, "SP"},
+ {V4L2_H264_SLICE_TYPE_SI, "SI"}),
+ __entry->s.colour_plane_id,
+ __entry->s.redundant_pic_cnt,
+ __entry->s.cabac_init_idc,
+ __entry->s.slice_qp_delta,
+ __entry->s.slice_qs_delta,
+ __entry->s.disable_deblocking_filter_idc,
+ __entry->s.slice_alpha_c0_offset_div2,
+ __entry->s.slice_beta_offset_div2,
+ __entry->s.num_ref_idx_l0_active_minus1,
+ __entry->s.num_ref_idx_l1_active_minus1,
+ __print_flags(__entry->s.flags, "|",
+ {V4L2_H264_SLICE_FLAG_DIRECT_SPATIAL_MV_PRED, "DIRECT_SPATIAL_MV_PRED"},
+ {V4L2_H264_SLICE_FLAG_SP_FOR_SWITCH, "SP_FOR_SWITCH"})
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_h264_reference_tmpl,
+ TP_PROTO(const struct v4l2_h264_reference *r, int i),
+ TP_ARGS(r, i),
+ TP_STRUCT__entry(__field_struct(struct v4l2_h264_reference, r)
+ __field(int, i)),
+ TP_fast_assign(__entry->r = *r; __entry->i = i;),
+ TP_printk("[%d]: fields %s index %u",
+ __entry->i,
+ __print_flags(__entry->r.fields, "|",
+ {V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
+ {V4L2_H264_BOTTOM_FIELD_REF, "BOTTOM_FIELD_REF"},
+ {V4L2_H264_FRAME_REF, "FRAME_REF"}),
+ __entry->r.index
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
+ TP_ARGS(d),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_decode_params, d)),
+ TP_fast_assign(__entry->d = *d),
+ TP_printk("\nnal_ref_idc %u\n"
+ "frame_num %u\n"
+ "top_field_order_cnt %d\n"
+ "bottom_field_order_cnt %d\n"
+ "idr_pic_id %u\n"
+ "pic_order_cnt_lsb %u\n"
+ "delta_pic_order_cnt_bottom %d\n"
+ "delta_pic_order_cnt0 %d\n"
+ "delta_pic_order_cnt1 %d\n"
+ "dec_ref_pic_marking_bit_size %u\n"
+ "pic_order_cnt_bit_size %u\n"
+ "slice_group_change_cycle %u\n"
+ "flags %s\n",
+ __entry->d.nal_ref_idc,
+ __entry->d.frame_num,
+ __entry->d.top_field_order_cnt,
+ __entry->d.bottom_field_order_cnt,
+ __entry->d.idr_pic_id,
+ __entry->d.pic_order_cnt_lsb,
+ __entry->d.delta_pic_order_cnt_bottom,
+ __entry->d.delta_pic_order_cnt0,
+ __entry->d.delta_pic_order_cnt1,
+ __entry->d.dec_ref_pic_marking_bit_size,
+ __entry->d.pic_order_cnt_bit_size,
+ __entry->d.slice_group_change_cycle,
+ __print_flags(__entry->d.flags, "|",
+ {V4L2_H264_DECODE_PARAM_FLAG_IDR_PIC, "IDR_PIC"},
+ {V4L2_H264_DECODE_PARAM_FLAG_FIELD_PIC, "FIELD_PIC"},
+ {V4L2_H264_DECODE_PARAM_FLAG_BOTTOM_FIELD, "BOTTOM_FIELD"},
+ {V4L2_H264_DECODE_PARAM_FLAG_PFRAME, "PFRAME"},
+ {V4L2_H264_DECODE_PARAM_FLAG_BFRAME, "BFRAME"})
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
+ TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
+ TP_ARGS(e, i),
+ TP_STRUCT__entry(__field_struct(struct v4l2_h264_dpb_entry, e)
+ __field(int, i)),
+ TP_fast_assign(__entry->e = *e; __entry->i = i;),
+ TP_printk("[%d]: reference_ts %llu, pic_num %u frame_num %u fields %s "
+ "top_field_order_cnt %d bottom_field_order_cnt %d flags %s",
+ __entry->i,
+ __entry->e.reference_ts,
+ __entry->e.pic_num,
+ __entry->e.frame_num,
+ __print_flags(__entry->e.fields, "|",
+ {V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
+ {V4L2_H264_BOTTOM_FIELD_REF, "BOTTOM_FIELD_REF"},
+ {V4L2_H264_FRAME_REF, "FRAME_REF"}),
+ __entry->e.top_field_order_cnt,
+ __entry->e.bottom_field_order_cnt,
+ __print_flags(__entry->e.flags, "|",
+ {V4L2_H264_DPB_ENTRY_FLAG_VALID, "VALID"},
+ {V4L2_H264_DPB_ENTRY_FLAG_ACTIVE, "ACTIVE"},
+ {V4L2_H264_DPB_ENTRY_FLAG_LONG_TERM, "LONG_TERM"},
+ {V4L2_H264_DPB_ENTRY_FLAG_FIELD, "FIELD"})
+
+ )
+);
+
+DEFINE_EVENT(v4l2_ctrl_h264_sps_tmpl, v4l2_ctrl_h264_sps,
+ TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_ctrl_h264_pps_tmpl, v4l2_ctrl_h264_pps,
+ TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
+ TP_ARGS(p)
+);
+
+DEFINE_EVENT(v4l2_ctrl_h264_scaling_matrix_tmpl, v4l2_ctrl_h264_scaling_matrix,
+ TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_ctrl_h264_pred_weights_tmpl, v4l2_ctrl_h264_pred_weights,
+ TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
+ TP_ARGS(p)
+);
+
+DEFINE_EVENT(v4l2_ctrl_h264_slice_params_tmpl, v4l2_ctrl_h264_slice_params,
+ TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_h264_reference_tmpl, v4l2_h264_ref_pic_list0,
+ TP_PROTO(const struct v4l2_h264_reference *r, int i),
+ TP_ARGS(r, i)
+);
+
+DEFINE_EVENT(v4l2_h264_reference_tmpl, v4l2_h264_ref_pic_list1,
+ TP_PROTO(const struct v4l2_h264_reference *r, int i),
+ TP_ARGS(r, i)
+);
+
+DEFINE_EVENT(v4l2_ctrl_h264_decode_params_tmpl, v4l2_ctrl_h264_decode_params,
+ TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
+ TP_ARGS(d)
+);
+
+DEFINE_EVENT(v4l2_h264_dpb_entry_tmpl, v4l2_h264_dpb_entry,
+ TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
+ TP_ARGS(e, i)
+);
+
+/* HEVC controls */
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_sps, s)),
+ TP_fast_assign(__entry->s = *s),
+ TP_printk("\nvideo_parameter_set_id %u\n"
+ "seq_parameter_set_id %u\n"
+ "pic_width_in_luma_samples %u\n"
+ "pic_height_in_luma_samples %u\n"
+ "bit_depth_luma_minus8 %u\n"
+ "bit_depth_chroma_minus8 %u\n"
+ "log2_max_pic_order_cnt_lsb_minus4 %u\n"
+ "sps_max_dec_pic_buffering_minus1 %u\n"
+ "sps_max_num_reorder_pics %u\n"
+ "sps_max_latency_increase_plus1 %u\n"
+ "log2_min_luma_coding_block_size_minus3 %u\n"
+ "log2_diff_max_min_luma_coding_block_size %u\n"
+ "log2_min_luma_transform_block_size_minus2 %u\n"
+ "log2_diff_max_min_luma_transform_block_size %u\n"
+ "max_transform_hierarchy_depth_inter %u\n"
+ "max_transform_hierarchy_depth_intra %u\n"
+ "pcm_sample_bit_depth_luma_minus1 %u\n"
+ "pcm_sample_bit_depth_chroma_minus1 %u\n"
+ "log2_min_pcm_luma_coding_block_size_minus3 %u\n"
+ "log2_diff_max_min_pcm_luma_coding_block_size %u\n"
+ "num_short_term_ref_pic_sets %u\n"
+ "num_long_term_ref_pics_sps %u\n"
+ "chroma_format_idc %u\n"
+ "sps_max_sub_layers_minus1 %u\n"
+ "flags %s",
+ __entry->s.video_parameter_set_id,
+ __entry->s.seq_parameter_set_id,
+ __entry->s.pic_width_in_luma_samples,
+ __entry->s.pic_height_in_luma_samples,
+ __entry->s.bit_depth_luma_minus8,
+ __entry->s.bit_depth_chroma_minus8,
+ __entry->s.log2_max_pic_order_cnt_lsb_minus4,
+ __entry->s.sps_max_dec_pic_buffering_minus1,
+ __entry->s.sps_max_num_reorder_pics,
+ __entry->s.sps_max_latency_increase_plus1,
+ __entry->s.log2_min_luma_coding_block_size_minus3,
+ __entry->s.log2_diff_max_min_luma_coding_block_size,
+ __entry->s.log2_min_luma_transform_block_size_minus2,
+ __entry->s.log2_diff_max_min_luma_transform_block_size,
+ __entry->s.max_transform_hierarchy_depth_inter,
+ __entry->s.max_transform_hierarchy_depth_intra,
+ __entry->s.pcm_sample_bit_depth_luma_minus1,
+ __entry->s.pcm_sample_bit_depth_chroma_minus1,
+ __entry->s.log2_min_pcm_luma_coding_block_size_minus3,
+ __entry->s.log2_diff_max_min_pcm_luma_coding_block_size,
+ __entry->s.num_short_term_ref_pic_sets,
+ __entry->s.num_long_term_ref_pics_sps,
+ __entry->s.chroma_format_idc,
+ __entry->s.sps_max_sub_layers_minus1,
+ __print_flags(__entry->s.flags, "|",
+ {V4L2_HEVC_SPS_FLAG_SEPARATE_COLOUR_PLANE, "SEPARATE_COLOUR_PLANE"},
+ {V4L2_HEVC_SPS_FLAG_SCALING_LIST_ENABLED, "SCALING_LIST_ENABLED"},
+ {V4L2_HEVC_SPS_FLAG_AMP_ENABLED, "AMP_ENABLED"},
+ {V4L2_HEVC_SPS_FLAG_SAMPLE_ADAPTIVE_OFFSET, "SAMPLE_ADAPTIVE_OFFSET"},
+ {V4L2_HEVC_SPS_FLAG_PCM_ENABLED, "PCM_ENABLED"},
+ {V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED, "V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED"},
+ {V4L2_HEVC_SPS_FLAG_LONG_TERM_REF_PICS_PRESENT, "LONG_TERM_REF_PICS_PRESENT"},
+ {V4L2_HEVC_SPS_FLAG_SPS_TEMPORAL_MVP_ENABLED, "TEMPORAL_MVP_ENABLED"},
+ {V4L2_HEVC_SPS_FLAG_STRONG_INTRA_SMOOTHING_ENABLED, "STRONG_INTRA_SMOOTHING_ENABLED"}
+ ))
+
+);
+
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_pps, p)),
+ TP_fast_assign(__entry->p = *p),
+ TP_printk("\npic_parameter_set_id %u\n"
+ "num_extra_slice_header_bits %u\n"
+ "num_ref_idx_l0_default_active_minus1 %u\n"
+ "num_ref_idx_l1_default_active_minus1 %u\n"
+ "init_qp_minus26 %d\n"
+ "diff_cu_qp_delta_depth %u\n"
+ "pps_cb_qp_offset %d\n"
+ "pps_cr_qp_offset %d\n"
+ "num_tile_columns_minus1 %d\n"
+ "num_tile_rows_minus1 %d\n"
+ "column_width_minus1 %s\n"
+ "row_height_minus1 %s\n"
+ "pps_beta_offset_div2 %d\n"
+ "pps_tc_offset_div2 %d\n"
+ "log2_parallel_merge_level_minus2 %u\n"
+ "flags %s",
+ __entry->p.pic_parameter_set_id,
+ __entry->p.num_extra_slice_header_bits,
+ __entry->p.num_ref_idx_l0_default_active_minus1,
+ __entry->p.num_ref_idx_l1_default_active_minus1,
+ __entry->p.init_qp_minus26,
+ __entry->p.diff_cu_qp_delta_depth,
+ __entry->p.pps_cb_qp_offset,
+ __entry->p.pps_cr_qp_offset,
+ __entry->p.num_tile_columns_minus1,
+ __entry->p.num_tile_rows_minus1,
+ __print_array(__entry->p.column_width_minus1,
+ ARRAY_SIZE(__entry->p.column_width_minus1),
+ sizeof(__entry->p.column_width_minus1[0])),
+ __print_array(__entry->p.row_height_minus1,
+ ARRAY_SIZE(__entry->p.row_height_minus1),
+ sizeof(__entry->p.row_height_minus1[0])),
+ __entry->p.pps_beta_offset_div2,
+ __entry->p.pps_tc_offset_div2,
+ __entry->p.log2_parallel_merge_level_minus2,
+ __print_flags(__entry->p.flags, "|",
+ {V4L2_HEVC_PPS_FLAG_DEPENDENT_SLICE_SEGMENT_ENABLED, "DEPENDENT_SLICE_SEGMENT_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_OUTPUT_FLAG_PRESENT, "OUTPUT_FLAG_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_SIGN_DATA_HIDING_ENABLED, "SIGN_DATA_HIDING_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_CABAC_INIT_PRESENT, "CABAC_INIT_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_CONSTRAINED_INTRA_PRED, "CONSTRAINED_INTRA_PRED"},
+ {V4L2_HEVC_PPS_FLAG_CU_QP_DELTA_ENABLED, "CU_QP_DELTA_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT, "PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_WEIGHTED_PRED, "WEIGHTED_PRED"},
+ {V4L2_HEVC_PPS_FLAG_WEIGHTED_BIPRED, "WEIGHTED_BIPRED"},
+ {V4L2_HEVC_PPS_FLAG_TRANSQUANT_BYPASS_ENABLED, "TRANSQUANT_BYPASS_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_TILES_ENABLED, "TILES_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_ENTROPY_CODING_SYNC_ENABLED, "ENTROPY_CODING_SYNC_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_LOOP_FILTER_ACROSS_TILES_ENABLED, "LOOP_FILTER_ACROSS_TILES_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED, "PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_OVERRIDE_ENABLED, "DEBLOCKING_FILTER_OVERRIDE_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_PPS_DISABLE_DEBLOCKING_FILTER, "DISABLE_DEBLOCKING_FILTER"},
+ {V4L2_HEVC_PPS_FLAG_LISTS_MODIFICATION_PRESENT, "LISTS_MODIFICATION_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_SLICE_SEGMENT_HEADER_EXTENSION_PRESENT, "SLICE_SEGMENT_HEADER_EXTENSION_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT, "DEBLOCKING_FILTER_CONTROL_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_UNIFORM_SPACING, "UNIFORM_SPACING"}
+ ))
+
+);
+
+
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_slice_params, s)),
+ TP_fast_assign(__entry->s = *s),
+ TP_printk("\nbit_size %u\n"
+ "data_byte_offset %u\n"
+ "num_entry_point_offsets %u\n"
+ "nal_unit_type %u\n"
+ "nuh_temporal_id_plus1 %u\n"
+ "slice_type %u\n"
+ "colour_plane_id %u\n"
+ "slice_pic_order_cnt %d\n"
+ "num_ref_idx_l0_active_minus1 %u\n"
+ "num_ref_idx_l1_active_minus1 %u\n"
+ "collocated_ref_idx %u\n"
+ "five_minus_max_num_merge_cand %u\n"
+ "slice_qp_delta %d\n"
+ "slice_cb_qp_offset %d\n"
+ "slice_cr_qp_offset %d\n"
+ "slice_act_y_qp_offset %d\n"
+ "slice_act_cb_qp_offset %d\n"
+ "slice_act_cr_qp_offset %d\n"
+ "slice_beta_offset_div2 %d\n"
+ "slice_tc_offset_div2 %d\n"
+ "pic_struct %u\n"
+ "slice_segment_addr %u\n"
+ "ref_idx_l0 %s\n"
+ "ref_idx_l1 %s\n"
+ "short_term_ref_pic_set_size %u\n"
+ "long_term_ref_pic_set_size %u\n"
+ "flags %s",
+ __entry->s.bit_size,
+ __entry->s.data_byte_offset,
+ __entry->s.num_entry_point_offsets,
+ __entry->s.nal_unit_type,
+ __entry->s.nuh_temporal_id_plus1,
+ __entry->s.slice_type,
+ __entry->s.colour_plane_id,
+ __entry->s.slice_pic_order_cnt,
+ __entry->s.num_ref_idx_l0_active_minus1,
+ __entry->s.num_ref_idx_l1_active_minus1,
+ __entry->s.collocated_ref_idx,
+ __entry->s.five_minus_max_num_merge_cand,
+ __entry->s.slice_qp_delta,
+ __entry->s.slice_cb_qp_offset,
+ __entry->s.slice_cr_qp_offset,
+ __entry->s.slice_act_y_qp_offset,
+ __entry->s.slice_act_cb_qp_offset,
+ __entry->s.slice_act_cr_qp_offset,
+ __entry->s.slice_beta_offset_div2,
+ __entry->s.slice_tc_offset_div2,
+ __entry->s.pic_struct,
+ __entry->s.slice_segment_addr,
+ __print_array(__entry->s.ref_idx_l0,
+ ARRAY_SIZE(__entry->s.ref_idx_l0),
+ sizeof(__entry->s.ref_idx_l0[0])),
+ __print_array(__entry->s.ref_idx_l1,
+ ARRAY_SIZE(__entry->s.ref_idx_l1),
+ sizeof(__entry->s.ref_idx_l1[0])),
+ __entry->s.short_term_ref_pic_set_size,
+ __entry->s.long_term_ref_pic_set_size,
+ __print_flags(__entry->s.flags, "|",
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_LUMA, "SLICE_SAO_LUMA"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_CHROMA, "SLICE_SAO_CHROMA"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_TEMPORAL_MVP_ENABLED, "SLICE_TEMPORAL_MVP_ENABLED"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_MVD_L1_ZERO, "MVD_L1_ZERO"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_CABAC_INIT, "CABAC_INIT"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_COLLOCATED_FROM_L0, "COLLOCATED_FROM_L0"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_USE_INTEGER_MV, "USE_INTEGER_MV"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_DEBLOCKING_FILTER_DISABLED, "SLICE_DEBLOCKING_FILTER_DISABLED"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED, "SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_DEPENDENT_SLICE_SEGMENT, "DEPENDENT_SLICE_SEGMENT"}
+
+ ))
+);
+
+DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
+ TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(__field_struct(struct v4l2_hevc_pred_weight_table, p)),
+ TP_fast_assign(__entry->p = *p),
+ TP_printk("\ndelta_luma_weight_l0 %s\n"
+ "luma_offset_l0 %s\n"
+ "delta_chroma_weight_l0 {%s}\n"
+ "chroma_offset_l0 {%s}\n"
+ "delta_luma_weight_l1 %s\n"
+ "luma_offset_l1 %s\n"
+ "delta_chroma_weight_l1 {%s}\n"
+ "chroma_offset_l1 {%s}\n"
+ "luma_log2_weight_denom %d\n"
+ "delta_chroma_log2_weight_denom %d\n",
+ __print_array(__entry->p.delta_luma_weight_l0,
+ ARRAY_SIZE(__entry->p.delta_luma_weight_l0),
+ sizeof(__entry->p.delta_luma_weight_l0[0])),
+ __print_array(__entry->p.luma_offset_l0,
+ ARRAY_SIZE(__entry->p.luma_offset_l0),
+ sizeof(__entry->p.luma_offset_l0[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.delta_chroma_weight_l0,
+ sizeof(__entry->p.delta_chroma_weight_l0),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.chroma_offset_l0,
+ sizeof(__entry->p.chroma_offset_l0),
+ false),
+ __print_array(__entry->p.delta_luma_weight_l1,
+ ARRAY_SIZE(__entry->p.delta_luma_weight_l1),
+ sizeof(__entry->p.delta_luma_weight_l1[0])),
+ __print_array(__entry->p.luma_offset_l1,
+ ARRAY_SIZE(__entry->p.luma_offset_l1),
+ sizeof(__entry->p.luma_offset_l1[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.delta_chroma_weight_l1,
+ sizeof(__entry->p.delta_chroma_weight_l1),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.chroma_offset_l1,
+ sizeof(__entry->p.chroma_offset_l1),
+ false),
+ __entry->p.luma_log2_weight_denom,
+ __entry->p.delta_chroma_log2_weight_denom
+
+ ))
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_scaling_matrix, s)),
+ TP_fast_assign(__entry->s = *s),
+ TP_printk("\nscaling_list_4x4 {%s}\n"
+ "scaling_list_8x8 {%s}\n"
+ "scaling_list_16x16 {%s}\n"
+ "scaling_list_32x32 {%s}\n"
+ "scaling_list_dc_coef_16x16 %s\n"
+ "scaling_list_dc_coef_32x32 %s\n",
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->s.scaling_list_4x4,
+ sizeof(__entry->s.scaling_list_4x4),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->s.scaling_list_8x8,
+ sizeof(__entry->s.scaling_list_8x8),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->s.scaling_list_16x16,
+ sizeof(__entry->s.scaling_list_16x16),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->s.scaling_list_32x32,
+ sizeof(__entry->s.scaling_list_32x32),
+ false),
+ __print_array(__entry->s.scaling_list_dc_coef_16x16,
+ ARRAY_SIZE(__entry->s.scaling_list_dc_coef_16x16),
+ sizeof(__entry->s.scaling_list_dc_coef_16x16[0])),
+ __print_array(__entry->s.scaling_list_dc_coef_32x32,
+ ARRAY_SIZE(__entry->s.scaling_list_dc_coef_32x32),
+ sizeof(__entry->s.scaling_list_dc_coef_32x32[0]))
+ ))
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
+ TP_ARGS(d),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_decode_params, d)),
+ TP_fast_assign(__entry->d = *d),
+ TP_printk("\npic_order_cnt_val %d\n"
+ "short_term_ref_pic_set_size %u\n"
+ "long_term_ref_pic_set_size %u\n"
+ "num_active_dpb_entries %u\n"
+ "num_poc_st_curr_before %u\n"
+ "num_poc_st_curr_after %u\n"
+ "num_poc_lt_curr %u\n"
+ "poc_st_curr_before %s\n"
+ "poc_st_curr_after %s\n"
+ "poc_lt_curr %s\n"
+ "flags %s",
+ __entry->d.pic_order_cnt_val,
+ __entry->d.short_term_ref_pic_set_size,
+ __entry->d.long_term_ref_pic_set_size,
+ __entry->d.num_active_dpb_entries,
+ __entry->d.num_poc_st_curr_before,
+ __entry->d.num_poc_st_curr_after,
+ __entry->d.num_poc_lt_curr,
+ __print_array(__entry->d.poc_st_curr_before,
+ ARRAY_SIZE(__entry->d.poc_st_curr_before),
+ sizeof(__entry->d.poc_st_curr_before[0])),
+ __print_array(__entry->d.poc_st_curr_after,
+ ARRAY_SIZE(__entry->d.poc_st_curr_after),
+ sizeof(__entry->d.poc_st_curr_after[0])),
+ __print_array(__entry->d.poc_lt_curr,
+ ARRAY_SIZE(__entry->d.poc_lt_curr),
+ sizeof(__entry->d.poc_lt_curr[0])),
+ __print_flags(__entry->d.flags, "|",
+ {V4L2_HEVC_DECODE_PARAM_FLAG_IRAP_PIC, "IRAP_PIC"},
+ {V4L2_HEVC_DECODE_PARAM_FLAG_IDR_PIC, "IDR_PIC"},
+ {V4L2_HEVC_DECODE_PARAM_FLAG_NO_OUTPUT_OF_PRIOR, "NO_OUTPUT_OF_PRIOR"}
+ ))
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
+ TP_ARGS(lt),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_ext_sps_lt_rps, lt)),
+ TP_fast_assign(__entry->lt = *lt),
+ TP_printk("\nflags %s\n"
+ "lt_ref_pic_poc_lsb_sps %x\n",
+ __print_flags(__entry->lt.flags, "|",
+ {V4L2_HEVC_EXT_SPS_LT_RPS_FLAG_USED_LT, "USED_LT"}
+ ),
+ __entry->lt.lt_ref_pic_poc_lsb_sps
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
+ TP_ARGS(st),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_ext_sps_st_rps, st)),
+ TP_fast_assign(__entry->st = *st),
+ TP_printk("\nflags %s\n"
+ "delta_idx_minus1: %u\n"
+ "delta_rps_sign: %u\n"
+ "abs_delta_rps_minus1: %u\n"
+ "num_negative_pics: %u\n"
+ "num_positive_pics: %u\n"
+ "used_by_curr_pic: %08x\n"
+ "use_delta_flag: %08x\n"
+ "delta_poc_s0_minus1: %s\n"
+ "delta_poc_s1_minus1: %s\n",
+ __print_flags(__entry->st.flags, "|",
+ {V4L2_HEVC_EXT_SPS_ST_RPS_FLAG_INTER_REF_PIC_SET_PRED, "INTER_REF_PIC_SET_PRED"}
+ ),
+ __entry->st.delta_idx_minus1,
+ __entry->st.delta_rps_sign,
+ __entry->st.abs_delta_rps_minus1,
+ __entry->st.num_negative_pics,
+ __entry->st.num_positive_pics,
+ __entry->st.used_by_curr_pic,
+ __entry->st.use_delta_flag,
+ __print_array(__entry->st.delta_poc_s0_minus1,
+ ARRAY_SIZE(__entry->st.delta_poc_s0_minus1),
+ sizeof(__entry->st.delta_poc_s0_minus1[0])),
+ __print_array(__entry->st.delta_poc_s1_minus1,
+ ARRAY_SIZE(__entry->st.delta_poc_s1_minus1),
+ sizeof(__entry->st.delta_poc_s1_minus1[0]))
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_hevc_dpb_entry_tmpl,
+ TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
+ TP_ARGS(e),
+ TP_STRUCT__entry(__field_struct(struct v4l2_hevc_dpb_entry, e)),
+ TP_fast_assign(__entry->e = *e),
+ TP_printk("\ntimestamp %llu\n"
+ "flags %s\n"
+ "field_pic %u\n"
+ "pic_order_cnt_val %d\n",
+ __entry->e.timestamp,
+ __print_flags(__entry->e.flags, "|",
+ {V4L2_HEVC_DPB_ENTRY_LONG_TERM_REFERENCE, "LONG_TERM_REFERENCE"}
+ ),
+ __entry->e.field_pic,
+ __entry->e.pic_order_cnt_val
+ ))
+
+DEFINE_EVENT(v4l2_ctrl_hevc_sps_tmpl, v4l2_ctrl_hevc_sps,
+ TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_ctrl_hevc_pps_tmpl, v4l2_ctrl_hevc_pps,
+ TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
+ TP_ARGS(p)
+);
+
+DEFINE_EVENT(v4l2_ctrl_hevc_slice_params_tmpl, v4l2_ctrl_hevc_slice_params,
+ TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_hevc_pred_weight_table_tmpl, v4l2_hevc_pred_weight_table,
+ TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
+ TP_ARGS(p)
+);
+
+DEFINE_EVENT(v4l2_ctrl_hevc_scaling_matrix_tmpl, v4l2_ctrl_hevc_scaling_matrix,
+ TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_ctrl_hevc_decode_params_tmpl, v4l2_ctrl_hevc_decode_params,
+ TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
+ TP_ARGS(d)
+);
+
+DEFINE_EVENT(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl, v4l2_ctrl_hevc_ext_sps_lt_rps,
+ TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
+ TP_ARGS(lt)
+);
+
+DEFINE_EVENT(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl, v4l2_ctrl_hevc_ext_sps_st_rps,
+ TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
+ TP_ARGS(st)
+);
+
+DEFINE_EVENT(v4l2_hevc_dpb_entry_tmpl, v4l2_hevc_dpb_entry,
+ TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
+ TP_ARGS(e)
+);
+
+/* MPEG2 controls */
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_seq_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
+ TP_ARGS(s),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_sequence, s)),
+ TP_fast_assign(__entry->s = *s;),
+ TP_printk("\nhorizontal_size %u\nvertical_size %u\nvbv_buffer_size %u\n"
+ "profile_and_level_indication %u\nchroma_format %u\nflags %s\n",
+ __entry->s.horizontal_size,
+ __entry->s.vertical_size,
+ __entry->s.vbv_buffer_size,
+ __entry->s.profile_and_level_indication,
+ __entry->s.chroma_format,
+ __print_flags(__entry->s.flags, "|",
+ {V4L2_MPEG2_SEQ_FLAG_PROGRESSIVE, "PROGRESSIVE"})
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_pic_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_picture, p)),
+ TP_fast_assign(__entry->p = *p;),
+ TP_printk("\nbackward_ref_ts %llu\nforward_ref_ts %llu\nflags %s\nf_code {%s}\n"
+ "picture_coding_type: %u\npicture_structure %u\nintra_dc_precision %u\n",
+ __entry->p.backward_ref_ts,
+ __entry->p.forward_ref_ts,
+ __print_flags(__entry->p.flags, "|",
+ {V4L2_MPEG2_PIC_FLAG_TOP_FIELD_FIRST, "TOP_FIELD_FIRST"},
+ {V4L2_MPEG2_PIC_FLAG_FRAME_PRED_DCT, "FRAME_PRED_DCT"},
+ {V4L2_MPEG2_PIC_FLAG_CONCEALMENT_MV, "CONCEALMENT_MV"},
+ {V4L2_MPEG2_PIC_FLAG_Q_SCALE_TYPE, "Q_SCALE_TYPE"},
+ {V4L2_MPEG2_PIC_FLAG_INTRA_VLC, "INTA_VLC"},
+ {V4L2_MPEG2_PIC_FLAG_ALT_SCAN, "ALT_SCAN"},
+ {V4L2_MPEG2_PIC_FLAG_REPEAT_FIRST, "REPEAT_FIRST"},
+ {V4L2_MPEG2_PIC_FLAG_PROGRESSIVE, "PROGRESSIVE"}),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.f_code,
+ sizeof(__entry->p.f_code),
+ false),
+ __entry->p.picture_coding_type,
+ __entry->p.picture_structure,
+ __entry->p.intra_dc_precision
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_quant_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
+ TP_ARGS(q),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_quantisation, q)),
+ TP_fast_assign(__entry->q = *q;),
+ TP_printk("\nintra_quantiser_matrix %s\nnon_intra_quantiser_matrix %s\n"
+ "chroma_intra_quantiser_matrix %s\nchroma_non_intra_quantiser_matrix %s\n",
+ __print_array(__entry->q.intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->q.intra_quantiser_matrix),
+ sizeof(__entry->q.intra_quantiser_matrix[0])),
+ __print_array(__entry->q.non_intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->q.non_intra_quantiser_matrix),
+ sizeof(__entry->q.non_intra_quantiser_matrix[0])),
+ __print_array(__entry->q.chroma_intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->q.chroma_intra_quantiser_matrix),
+ sizeof(__entry->q.chroma_intra_quantiser_matrix[0])),
+ __print_array(__entry->q.chroma_non_intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->q.chroma_non_intra_quantiser_matrix),
+ sizeof(__entry->q.chroma_non_intra_quantiser_matrix[0]))
+ )
+)
+
+DEFINE_EVENT(v4l2_ctrl_mpeg2_seq_tmpl, v4l2_ctrl_mpeg2_sequence,
+ TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
+ TP_ARGS(s)
+);
+
+DEFINE_EVENT(v4l2_ctrl_mpeg2_pic_tmpl, v4l2_ctrl_mpeg2_picture,
+ TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
+ TP_ARGS(p)
+);
+
+DEFINE_EVENT(v4l2_ctrl_mpeg2_quant_tmpl, v4l2_ctrl_mpeg2_quantisation,
+ TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
+ TP_ARGS(q)
+);
+
+/* VP8 controls */
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(f),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp8_frame, f)),
+ TP_fast_assign(__entry->f = *f;),
+ TP_printk("\nentropy.coeff_probs {%s}\n"
+ "entropy.y_mode_probs %s\n"
+ "entropy.uv_mode_probs %s\n"
+ "entropy.mv_probs {%s}",
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->f.entropy.coeff_probs,
+ sizeof(__entry->f.entropy.coeff_probs),
+ false),
+ __print_array(__entry->f.entropy.y_mode_probs,
+ ARRAY_SIZE(__entry->f.entropy.y_mode_probs),
+ sizeof(__entry->f.entropy.y_mode_probs[0])),
+ __print_array(__entry->f.entropy.uv_mode_probs,
+ ARRAY_SIZE(__entry->f.entropy.uv_mode_probs),
+ sizeof(__entry->f.entropy.uv_mode_probs[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->f.entropy.mv_probs,
+ sizeof(__entry->f.entropy.mv_probs),
+ false)
+ )
+)
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(f),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp8_frame, f)),
+ TP_fast_assign(__entry->f = *f;),
+ TP_printk("\nsegment.quant_update %s\n"
+ "segment.lf_update %s\n"
+ "segment.segment_probs %s\n"
+ "segment.flags %s\n"
+ "lf.ref_frm_delta %s\n"
+ "lf.mb_mode_delta %s\n"
+ "lf.sharpness_level %u\n"
+ "lf.level %u\n"
+ "lf.flags %s\n"
+ "quant.y_ac_qi %u\n"
+ "quant.y_dc_delta %d\n"
+ "quant.y2_dc_delta %d\n"
+ "quant.y2_ac_delta %d\n"
+ "quant.uv_dc_delta %d\n"
+ "quant.uv_ac_delta %d\n"
+ "coder_state.range %u\n"
+ "coder_state.value %u\n"
+ "coder_state.bit_count %u\n"
+ "width %u\n"
+ "height %u\n"
+ "horizontal_scale %u\n"
+ "vertical_scale %u\n"
+ "version %u\n"
+ "prob_skip_false %u\n"
+ "prob_intra %u\n"
+ "prob_last %u\n"
+ "prob_gf %u\n"
+ "num_dct_parts %u\n"
+ "first_part_size %u\n"
+ "first_part_header_bits %u\n"
+ "dct_part_sizes %s\n"
+ "last_frame_ts %llu\n"
+ "golden_frame_ts %llu\n"
+ "alt_frame_ts %llu\n"
+ "flags %s",
+ __print_array(__entry->f.segment.quant_update,
+ ARRAY_SIZE(__entry->f.segment.quant_update),
+ sizeof(__entry->f.segment.quant_update[0])),
+ __print_array(__entry->f.segment.lf_update,
+ ARRAY_SIZE(__entry->f.segment.lf_update),
+ sizeof(__entry->f.segment.lf_update[0])),
+ __print_array(__entry->f.segment.segment_probs,
+ ARRAY_SIZE(__entry->f.segment.segment_probs),
+ sizeof(__entry->f.segment.segment_probs[0])),
+ __print_flags(__entry->f.segment.flags, "|",
+ {V4L2_VP8_SEGMENT_FLAG_ENABLED, "SEGMENT_ENABLED"},
+ {V4L2_VP8_SEGMENT_FLAG_UPDATE_MAP, "SEGMENT_UPDATE_MAP"},
+ {V4L2_VP8_SEGMENT_FLAG_UPDATE_FEATURE_DATA, "SEGMENT_UPDATE_FEATURE_DATA"},
+ {V4L2_VP8_SEGMENT_FLAG_DELTA_VALUE_MODE, "SEGMENT_DELTA_VALUE_MODE"}),
+ __print_array(__entry->f.lf.ref_frm_delta,
+ ARRAY_SIZE(__entry->f.lf.ref_frm_delta),
+ sizeof(__entry->f.lf.ref_frm_delta[0])),
+ __print_array(__entry->f.lf.mb_mode_delta,
+ ARRAY_SIZE(__entry->f.lf.mb_mode_delta),
+ sizeof(__entry->f.lf.mb_mode_delta[0])),
+ __entry->f.lf.sharpness_level,
+ __entry->f.lf.level,
+ __print_flags(__entry->f.lf.flags, "|",
+ {V4L2_VP8_LF_ADJ_ENABLE, "LF_ADJ_ENABLED"},
+ {V4L2_VP8_LF_DELTA_UPDATE, "LF_DELTA_UPDATE"},
+ {V4L2_VP8_LF_FILTER_TYPE_SIMPLE, "LF_FILTER_TYPE_SIMPLE"}),
+ __entry->f.quant.y_ac_qi,
+ __entry->f.quant.y_dc_delta,
+ __entry->f.quant.y2_dc_delta,
+ __entry->f.quant.y2_ac_delta,
+ __entry->f.quant.uv_dc_delta,
+ __entry->f.quant.uv_ac_delta,
+ __entry->f.coder_state.range,
+ __entry->f.coder_state.value,
+ __entry->f.coder_state.bit_count,
+ __entry->f.width,
+ __entry->f.height,
+ __entry->f.horizontal_scale,
+ __entry->f.vertical_scale,
+ __entry->f.version,
+ __entry->f.prob_skip_false,
+ __entry->f.prob_intra,
+ __entry->f.prob_last,
+ __entry->f.prob_gf,
+ __entry->f.num_dct_parts,
+ __entry->f.first_part_size,
+ __entry->f.first_part_header_bits,
+ __print_array(__entry->f.dct_part_sizes,
+ ARRAY_SIZE(__entry->f.dct_part_sizes),
+ sizeof(__entry->f.dct_part_sizes[0])),
+ __entry->f.last_frame_ts,
+ __entry->f.golden_frame_ts,
+ __entry->f.alt_frame_ts,
+ __print_flags(__entry->f.flags, "|",
+ {V4L2_VP8_FRAME_FLAG_KEY_FRAME, "KEY_FRAME"},
+ {V4L2_VP8_FRAME_FLAG_EXPERIMENTAL, "EXPERIMENTAL"},
+ {V4L2_VP8_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
+ {V4L2_VP8_FRAME_FLAG_MB_NO_SKIP_COEFF, "MB_NO_SKIP_COEFF"},
+ {V4L2_VP8_FRAME_FLAG_SIGN_BIAS_GOLDEN, "SIGN_BIAS_GOLDEN"},
+ {V4L2_VP8_FRAME_FLAG_SIGN_BIAS_ALT, "SIGN_BIAS_ALT"})
+ )
+);
+
+DEFINE_EVENT(v4l2_ctrl_vp8_frame_tmpl, v4l2_ctrl_vp8_frame,
+ TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(f)
+);
+
+DEFINE_EVENT(v4l2_ctrl_vp8_entropy_tmpl, v4l2_ctrl_vp8_entropy,
+ TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(f)
+);
+
+/* VP9 controls */
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
+ TP_ARGS(f),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_frame, f)),
+ TP_fast_assign(__entry->f = *f;),
+ TP_printk("\nlf.ref_deltas %s\n"
+ "lf.mode_deltas %s\n"
+ "lf.level %u\n"
+ "lf.sharpness %u\n"
+ "lf.flags %s\n"
+ "quant.base_q_idx %u\n"
+ "quant.delta_q_y_dc %d\n"
+ "quant.delta_q_uv_dc %d\n"
+ "quant.delta_q_uv_ac %d\n"
+ "seg.feature_data {%s}\n"
+ "seg.feature_enabled %s\n"
+ "seg.tree_probs %s\n"
+ "seg.pred_probs %s\n"
+ "seg.flags %s\n"
+ "flags %s\n"
+ "compressed_header_size %u\n"
+ "uncompressed_header_size %u\n"
+ "frame_width_minus_1 %u\n"
+ "frame_height_minus_1 %u\n"
+ "render_width_minus_1 %u\n"
+ "render_height_minus_1 %u\n"
+ "last_frame_ts %llu\n"
+ "golden_frame_ts %llu\n"
+ "alt_frame_ts %llu\n"
+ "ref_frame_sign_bias %s\n"
+ "reset_frame_context %s\n"
+ "frame_context_idx %u\n"
+ "profile %u\n"
+ "bit_depth %u\n"
+ "interpolation_filter %s\n"
+ "tile_cols_log2 %u\n"
+ "tile_rows_log_2 %u\n"
+ "reference_mode %s\n",
+ __print_array(__entry->f.lf.ref_deltas,
+ ARRAY_SIZE(__entry->f.lf.ref_deltas),
+ sizeof(__entry->f.lf.ref_deltas[0])),
+ __print_array(__entry->f.lf.mode_deltas,
+ ARRAY_SIZE(__entry->f.lf.mode_deltas),
+ sizeof(__entry->f.lf.mode_deltas[0])),
+ __entry->f.lf.level,
+ __entry->f.lf.sharpness,
+ __print_flags(__entry->f.lf.flags, "|",
+ {V4L2_VP9_LOOP_FILTER_FLAG_DELTA_ENABLED, "DELTA_ENABLED"},
+ {V4L2_VP9_LOOP_FILTER_FLAG_DELTA_UPDATE, "DELTA_UPDATE"}),
+ __entry->f.quant.base_q_idx,
+ __entry->f.quant.delta_q_y_dc,
+ __entry->f.quant.delta_q_uv_dc,
+ __entry->f.quant.delta_q_uv_ac,
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->f.seg.feature_data,
+ sizeof(__entry->f.seg.feature_data),
+ false),
+ __print_array(__entry->f.seg.feature_enabled,
+ ARRAY_SIZE(__entry->f.seg.feature_enabled),
+ sizeof(__entry->f.seg.feature_enabled[0])),
+ __print_array(__entry->f.seg.tree_probs,
+ ARRAY_SIZE(__entry->f.seg.tree_probs),
+ sizeof(__entry->f.seg.tree_probs[0])),
+ __print_array(__entry->f.seg.pred_probs,
+ ARRAY_SIZE(__entry->f.seg.pred_probs),
+ sizeof(__entry->f.seg.pred_probs[0])),
+ __print_flags(__entry->f.seg.flags, "|",
+ {V4L2_VP9_SEGMENTATION_FLAG_ENABLED, "ENABLED"},
+ {V4L2_VP9_SEGMENTATION_FLAG_UPDATE_MAP, "UPDATE_MAP"},
+ {V4L2_VP9_SEGMENTATION_FLAG_TEMPORAL_UPDATE, "TEMPORAL_UPDATE"},
+ {V4L2_VP9_SEGMENTATION_FLAG_UPDATE_DATA, "UPDATE_DATA"},
+ {V4L2_VP9_SEGMENTATION_FLAG_ABS_OR_DELTA_UPDATE, "ABS_OR_DELTA_UPDATE"}),
+ __print_flags(__entry->f.flags, "|",
+ {V4L2_VP9_FRAME_FLAG_KEY_FRAME, "KEY_FRAME"},
+ {V4L2_VP9_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
+ {V4L2_VP9_FRAME_FLAG_ERROR_RESILIENT, "ERROR_RESILIENT"},
+ {V4L2_VP9_FRAME_FLAG_INTRA_ONLY, "INTRA_ONLY"},
+ {V4L2_VP9_FRAME_FLAG_ALLOW_HIGH_PREC_MV, "ALLOW_HIGH_PREC_MV"},
+ {V4L2_VP9_FRAME_FLAG_REFRESH_FRAME_CTX, "REFRESH_FRAME_CTX"},
+ {V4L2_VP9_FRAME_FLAG_PARALLEL_DEC_MODE, "PARALLEL_DEC_MODE"},
+ {V4L2_VP9_FRAME_FLAG_X_SUBSAMPLING, "X_SUBSAMPLING"},
+ {V4L2_VP9_FRAME_FLAG_Y_SUBSAMPLING, "Y_SUBSAMPLING"},
+ {V4L2_VP9_FRAME_FLAG_COLOR_RANGE_FULL_SWING, "COLOR_RANGE_FULL_SWING"}),
+ __entry->f.compressed_header_size,
+ __entry->f.uncompressed_header_size,
+ __entry->f.frame_width_minus_1,
+ __entry->f.frame_height_minus_1,
+ __entry->f.render_width_minus_1,
+ __entry->f.render_height_minus_1,
+ __entry->f.last_frame_ts,
+ __entry->f.golden_frame_ts,
+ __entry->f.alt_frame_ts,
+ __print_symbolic(__entry->f.ref_frame_sign_bias,
+ {V4L2_VP9_SIGN_BIAS_LAST, "SIGN_BIAS_LAST"},
+ {V4L2_VP9_SIGN_BIAS_GOLDEN, "SIGN_BIAS_GOLDEN"},
+ {V4L2_VP9_SIGN_BIAS_ALT, "SIGN_BIAS_ALT"}),
+ __print_symbolic(__entry->f.reset_frame_context,
+ {V4L2_VP9_RESET_FRAME_CTX_NONE, "RESET_FRAME_CTX_NONE"},
+ {V4L2_VP9_RESET_FRAME_CTX_SPEC, "RESET_FRAME_CTX_SPEC"},
+ {V4L2_VP9_RESET_FRAME_CTX_ALL, "RESET_FRAME_CTX_ALL"}),
+ __entry->f.frame_context_idx,
+ __entry->f.profile,
+ __entry->f.bit_depth,
+ __print_symbolic(__entry->f.interpolation_filter,
+ {V4L2_VP9_INTERP_FILTER_EIGHTTAP, "INTERP_FILTER_EIGHTTAP"},
+ {V4L2_VP9_INTERP_FILTER_EIGHTTAP_SMOOTH, "INTERP_FILTER_EIGHTTAP_SMOOTH"},
+ {V4L2_VP9_INTERP_FILTER_EIGHTTAP_SHARP, "INTERP_FILTER_EIGHTTAP_SHARP"},
+ {V4L2_VP9_INTERP_FILTER_BILINEAR, "INTERP_FILTER_BILINEAR"},
+ {V4L2_VP9_INTERP_FILTER_SWITCHABLE, "INTERP_FILTER_SWITCHABLE"}),
+ __entry->f.tile_cols_log2,
+ __entry->f.tile_rows_log2,
+ __print_symbolic(__entry->f.reference_mode,
+ {V4L2_VP9_REFERENCE_MODE_SINGLE_REFERENCE, "REFERENCE_MODE_SINGLE_REFERENCE"},
+ {V4L2_VP9_REFERENCE_MODE_COMPOUND_REFERENCE, "REFERENCE_MODE_COMPOUND_REFERENCE"},
+ {V4L2_VP9_REFERENCE_MODE_SELECT, "REFERENCE_MODE_SELECT"}))
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(h),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_compressed_hdr, h)),
+ TP_fast_assign(__entry->h = *h;),
+ TP_printk("\ntx_mode %s\n"
+ "tx8 {%s}\n"
+ "tx16 {%s}\n"
+ "tx32 {%s}\n"
+ "skip %s\n"
+ "inter_mode {%s}\n"
+ "interp_filter {%s}\n"
+ "is_inter %s\n"
+ "comp_mode %s\n"
+ "single_ref {%s}\n"
+ "comp_ref %s\n"
+ "y_mode {%s}\n"
+ "uv_mode {%s}\n"
+ "partition {%s}\n",
+ __print_symbolic(__entry->h.tx_mode,
+ {V4L2_VP9_TX_MODE_ONLY_4X4, "TX_MODE_ONLY_4X4"},
+ {V4L2_VP9_TX_MODE_ALLOW_8X8, "TX_MODE_ALLOW_8X8"},
+ {V4L2_VP9_TX_MODE_ALLOW_16X16, "TX_MODE_ALLOW_16X16"},
+ {V4L2_VP9_TX_MODE_ALLOW_32X32, "TX_MODE_ALLOW_32X32"},
+ {V4L2_VP9_TX_MODE_SELECT, "TX_MODE_SELECT"}),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.tx8,
+ sizeof(__entry->h.tx8),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.tx16,
+ sizeof(__entry->h.tx16),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.tx32,
+ sizeof(__entry->h.tx32),
+ false),
+ __print_array(__entry->h.skip,
+ ARRAY_SIZE(__entry->h.skip),
+ sizeof(__entry->h.skip[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.inter_mode,
+ sizeof(__entry->h.inter_mode),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.interp_filter,
+ sizeof(__entry->h.interp_filter),
+ false),
+ __print_array(__entry->h.is_inter,
+ ARRAY_SIZE(__entry->h.is_inter),
+ sizeof(__entry->h.is_inter[0])),
+ __print_array(__entry->h.comp_mode,
+ ARRAY_SIZE(__entry->h.comp_mode),
+ sizeof(__entry->h.comp_mode[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.single_ref,
+ sizeof(__entry->h.single_ref),
+ false),
+ __print_array(__entry->h.comp_ref,
+ ARRAY_SIZE(__entry->h.comp_ref),
+ sizeof(__entry->h.comp_ref[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.y_mode,
+ sizeof(__entry->h.y_mode),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.uv_mode,
+ sizeof(__entry->h.uv_mode),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.partition,
+ sizeof(__entry->h.partition),
+ false)
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_coef_tmpl,
+ TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(h),
+ TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_compressed_hdr, h)),
+ TP_fast_assign(__entry->h = *h;),
+ TP_printk("\n coef {%s}",
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->h.coef,
+ sizeof(__entry->h.coef),
+ false)
+ )
+);
+
+DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
+ TP_PROTO(const struct v4l2_vp9_mv_probs *p),
+ TP_ARGS(p),
+ TP_STRUCT__entry(__field_struct(struct v4l2_vp9_mv_probs, p)),
+ TP_fast_assign(__entry->p = *p;),
+ TP_printk("\n joint %s\n"
+ "sign %s\n"
+ "classes {%s}\n"
+ "class0_bit %s\n"
+ "bits {%s}\n"
+ "class0_fr {%s}\n"
+ "fr {%s}\n"
+ "class0_hp %s\n"
+ "hp %s\n",
+ __print_array(__entry->p.joint,
+ ARRAY_SIZE(__entry->p.joint),
+ sizeof(__entry->p.joint[0])),
+ __print_array(__entry->p.sign,
+ ARRAY_SIZE(__entry->p.sign),
+ sizeof(__entry->p.sign[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.classes,
+ sizeof(__entry->p.classes),
+ false),
+ __print_array(__entry->p.class0_bit,
+ ARRAY_SIZE(__entry->p.class0_bit),
+ sizeof(__entry->p.class0_bit[0])),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.bits,
+ sizeof(__entry->p.bits),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.class0_fr,
+ sizeof(__entry->p.class0_fr),
+ false),
+ __print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
+ __entry->p.fr,
+ sizeof(__entry->p.fr),
+ false),
+ __print_array(__entry->p.class0_hp,
+ ARRAY_SIZE(__entry->p.class0_hp),
+ sizeof(__entry->p.class0_hp[0])),
+ __print_array(__entry->p.hp,
+ ARRAY_SIZE(__entry->p.hp),
+ sizeof(__entry->p.hp[0]))
+ )
+);
+
+DEFINE_EVENT(v4l2_ctrl_vp9_frame_tmpl, v4l2_ctrl_vp9_frame,
+ TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
+ TP_ARGS(f)
+);
+
+DEFINE_EVENT(v4l2_ctrl_vp9_compressed_hdr_tmpl, v4l2_ctrl_vp9_compressed_hdr,
+ TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(h)
+);
+
+DEFINE_EVENT(v4l2_ctrl_vp9_compressed_coef_tmpl, v4l2_ctrl_vp9_compressed_coeff,
+ TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(h)
+);
+
+
+DEFINE_EVENT(v4l2_vp9_mv_probs_tmpl, v4l2_vp9_mv_probs,
+ TP_PROTO(const struct v4l2_vp9_mv_probs *p),
+ TP_ARGS(p)
+);
+
+#endif /* if !defined(_TRACE_V4L2_CONTROLS_H_) || defined(TRACE_HEADER_MULTI_READ) */
+
+#include <trace/define_trace.h>
--
2.54.0
^ permalink raw reply related
* [PATCH v2 2/9] media: Map each struct field to its own trace field
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
The trace events, moved from the visl driver, are simply using the
passed struct pointer to print the event in the trace.
This approach doesn't allow userspace to filter on fields, but also only
exposes the value of the pointer when using libtraceevent, which can't
be used to retrieve the control fields, forcing userspace to parse the
trace output.
To avoid that, list all fields from each passed struct in the trace.
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
---
include/trace/events/v4l2_controls.h | 2171 ++++++++++++++++++++++++----------
1 file changed, 1522 insertions(+), 649 deletions(-)
diff --git a/include/trace/events/v4l2_controls.h b/include/trace/events/v4l2_controls.h
index 9c74309b31ef..3a9bc75752bf 100644
--- a/include/trace/events/v4l2_controls.h
+++ b/include/trace/events/v4l2_controls.h
@@ -8,15 +8,34 @@
#undef TRACE_SYSTEM
#define TRACE_SYSTEM v4l2_controls
+/* V4L2 controls tracing events.
+ *
+ * These events are used to trace each V4L2 control when they are set by userspace.
+ * They can be identified by the name of the event. All control fields are copied in a TP_STRUCT
+ * field so that they can be filtered separately in userspace.
+ *
+ * Currently only the codec controls are supported.
+ */
+
/* AV1 controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_seq_tmpl,
TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_sequence, s)),
- TP_fast_assign(__entry->s = *s;),
+ TP_STRUCT__entry(__field(__u32, flags)
+ __field(__u8, seq_profile)
+ __field(__u8, order_hint_bits)
+ __field(__u8, bit_depth)
+ __field(__u16, max_frame_width_minus_1)
+ __field(__u16, max_frame_height_minus_1)),
+ TP_fast_assign(__entry->flags = s->flags;
+ __entry->seq_profile = s->seq_profile;
+ __entry->order_hint_bits = s->order_hint_bits;
+ __entry->bit_depth = s->bit_depth;
+ __entry->max_frame_width_minus_1 = s->max_frame_width_minus_1;
+ __entry->max_frame_height_minus_1 = s->max_frame_height_minus_1;),
TP_printk("\nflags %s\nseq_profile: %u\norder_hint_bits: %u\nbit_depth: %u\n"
"max_frame_width_minus_1: %u\nmax_frame_height_minus_1: %u\n",
- __print_flags(__entry->s.flags, "|",
+ __print_flags(__entry->flags, "|",
{V4L2_AV1_SEQUENCE_FLAG_STILL_PICTURE, "STILL_PICTURE"},
{V4L2_AV1_SEQUENCE_FLAG_USE_128X128_SUPERBLOCK, "USE_128X128_SUPERBLOCK"},
{V4L2_AV1_SEQUENCE_FLAG_ENABLE_FILTER_INTRA, "ENABLE_FILTER_INTRA"},
@@ -37,32 +56,176 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_seq_tmpl,
{V4L2_AV1_SEQUENCE_FLAG_SUBSAMPLING_Y, "SUBSAMPLING_Y"},
{V4L2_AV1_SEQUENCE_FLAG_FILM_GRAIN_PARAMS_PRESENT, "FILM_GRAIN_PARAMS_PRESENT"},
{V4L2_AV1_SEQUENCE_FLAG_SEPARATE_UV_DELTA_Q, "SEPARATE_UV_DELTA_Q"}),
- __entry->s.seq_profile,
- __entry->s.order_hint_bits,
- __entry->s.bit_depth,
- __entry->s.max_frame_width_minus_1,
- __entry->s.max_frame_height_minus_1
+ __entry->seq_profile,
+ __entry->order_hint_bits,
+ __entry->bit_depth,
+ __entry->max_frame_width_minus_1,
+ __entry->max_frame_height_minus_1
)
);
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_tge_tmpl,
TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
TP_ARGS(t),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_tile_group_entry, t)),
- TP_fast_assign(__entry->t = *t;),
+ TP_STRUCT__entry(__field(__u32, tile_offset)
+ __field(__u32, tile_size)
+ __field(__u32, tile_row)
+ __field(__u32, tile_col)),
+ TP_fast_assign(__entry->tile_offset = t->tile_offset;
+ __entry->tile_size = t->tile_size;
+ __entry->tile_row = t->tile_row;
+ __entry->tile_col = t->tile_col;),
TP_printk("\ntile_offset: %u\n tile_size: %u\n tile_row: %u\ntile_col: %u\n",
- __entry->t.tile_offset,
- __entry->t.tile_size,
- __entry->t.tile_row,
- __entry->t.tile_col
+ __entry->tile_offset,
+ __entry->tile_size,
+ __entry->tile_row,
+ __entry->tile_col
)
);
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_frame, f)),
- TP_fast_assign(__entry->f = *f;),
+ TP_STRUCT__entry(__field(u8, tile_info_flags)
+ __field(u8, tile_info_context_update_tile_id)
+ __field(u8, tile_info_tile_cols)
+ __field(u8, tile_info_tile_rows)
+ __array(u32, tile_info_mi_col_starts, V4L2_AV1_MAX_TILE_COLS + 1)
+ __array(u32, tile_info_mi_row_starts, V4L2_AV1_MAX_TILE_ROWS + 1)
+ __array(u32, tile_info_width_in_sbs_minus_1, V4L2_AV1_MAX_TILE_COLS)
+ __array(u32, tile_info_height_in_sbs_minus_1, V4L2_AV1_MAX_TILE_ROWS)
+ __field(u8, tile_info_tile_size_bytes)
+ __field(u8, quantization_flags)
+ __field(u8, quantization_base_q_idx)
+ __field(s8, quantization_delta_q_y_dc)
+ __field(s8, quantization_delta_q_u_dc)
+ __field(s8, quantization_delta_q_u_ac)
+ __field(s8, quantization_delta_q_v_dc)
+ __field(s8, quantization_delta_q_v_ac)
+ __field(u8, quantization_qm_y)
+ __field(u8, quantization_qm_u)
+ __field(u8, quantization_qm_v)
+ __field(u8, quantization_delta_q_res)
+ __field(u8, superres_denom)
+ __field(u8, segmentation_flags)
+ __field(u8, segmentation_last_active_seg_id)
+ __array(u8, segmentation_feature_enabled, V4L2_AV1_MAX_SEGMENTS)
+ __field(u8, loop_filter_flags)
+ __array(u8, loop_filter_level, 4)
+ __field(u8, loop_filter_sharpness)
+ __array(s8, loop_filter_ref_deltas, V4L2_AV1_TOTAL_REFS_PER_FRAME)
+ __array(s8, loop_filter_mode_deltas, 2)
+ __field(u8, loop_filter_delta_lf_res)
+ __field(u8, cdef_damping_minus_3)
+ __field(u8, cdef_bits)
+ __array(u8, cdef_y_pri_strength, V4L2_AV1_CDEF_MAX)
+ __array(u8, cdef_y_sec_strength, V4L2_AV1_CDEF_MAX)
+ __array(u8, cdef_uv_pri_strength, V4L2_AV1_CDEF_MAX)
+ __array(u8, cdef_uv_sec_strength, V4L2_AV1_CDEF_MAX)
+ __array(u8, skip_mode_frame, 2)
+ __field(u8, primary_ref_frame)
+ __field(u8, loop_restoration_flags)
+ __field(u8, loop_restoration_lr_unit_shift)
+ __field(u8, loop_restoration_lr_uv_shift)
+ __array(int,
+ loop_restoration_frame_restoration_type, V4L2_AV1_NUM_PLANES_MAX)
+ __array(u32,
+ loop_restoration_loop_restoration_size, V4L2_AV1_MAX_NUM_PLANES)
+ __field(u32, flags)
+ __field(u32, order_hint)
+ __field(u32, upscaled_width)
+ __field(u32, frame_width_minus_1)
+ __field(u32, frame_height_minus_1)
+ __field(u16, render_width_minus_1)
+ __field(u16, render_height_minus_1)
+ __field(u32, current_frame_id)
+ __array(u32, buffer_removal_time, V4L2_AV1_MAX_OPERATING_POINTS)
+ __array(u32, order_hints, V4L2_AV1_TOTAL_REFS_PER_FRAME)
+ __array(u64, reference_frame_ts, V4L2_AV1_TOTAL_REFS_PER_FRAME)
+ __array(s8, ref_frame_idx, V4L2_AV1_REFS_PER_FRAME)
+ __field(u8, refresh_frame_flags)),
+ TP_fast_assign(__entry->tile_info_flags = f->tile_info.flags;
+ __entry->tile_info_context_update_tile_id =
+ f->tile_info.context_update_tile_id;
+ __entry->tile_info_tile_cols = f->tile_info.tile_cols;
+ __entry->tile_info_tile_rows = f->tile_info.tile_rows;
+ memcpy(__entry->tile_info_mi_col_starts, f->tile_info.mi_col_starts,
+ sizeof(__entry->tile_info_mi_col_starts));
+ memcpy(__entry->tile_info_mi_row_starts, f->tile_info.mi_row_starts,
+ sizeof(__entry->tile_info_mi_row_starts));
+ memcpy(__entry->tile_info_width_in_sbs_minus_1,
+ f->tile_info.width_in_sbs_minus_1,
+ sizeof(__entry->tile_info_width_in_sbs_minus_1));
+ memcpy(__entry->tile_info_height_in_sbs_minus_1,
+ f->tile_info.height_in_sbs_minus_1,
+ sizeof(__entry->tile_info_height_in_sbs_minus_1));
+ __entry->tile_info_tile_size_bytes = f->tile_info.tile_size_bytes;
+ __entry->quantization_flags = f->quantization.flags;
+ __entry->quantization_base_q_idx = f->quantization.base_q_idx;
+ __entry->quantization_delta_q_y_dc = f->quantization.delta_q_y_dc;
+ __entry->quantization_delta_q_u_dc = f->quantization.delta_q_u_dc;
+ __entry->quantization_delta_q_u_ac = f->quantization.delta_q_u_ac;
+ __entry->quantization_delta_q_v_dc = f->quantization.delta_q_v_dc;
+ __entry->quantization_delta_q_v_ac = f->quantization.delta_q_v_ac;
+ __entry->quantization_qm_y = f->quantization.qm_y;
+ __entry->quantization_qm_u = f->quantization.qm_u;
+ __entry->quantization_qm_v = f->quantization.qm_v;
+ __entry->quantization_delta_q_res = f->quantization.delta_q_res;
+ __entry->superres_denom = f->superres_denom;
+ __entry->segmentation_flags = f->segmentation.flags;
+ __entry->segmentation_last_active_seg_id =
+ f->segmentation.last_active_seg_id;
+ memcpy(__entry->segmentation_feature_enabled,
+ f->segmentation.feature_enabled,
+ sizeof(__entry->segmentation_feature_enabled));
+ __entry->loop_filter_flags = f->loop_filter.flags;
+ memcpy(__entry->loop_filter_level, f->loop_filter.level,
+ sizeof(__entry->loop_filter_level));
+ __entry->loop_filter_sharpness = f->loop_filter.sharpness;
+ memcpy(__entry->loop_filter_ref_deltas, f->loop_filter.ref_deltas,
+ sizeof(__entry->loop_filter_ref_deltas));
+ memcpy(__entry->loop_filter_mode_deltas, f->loop_filter.mode_deltas,
+ sizeof(__entry->loop_filter_mode_deltas));
+ __entry->loop_filter_delta_lf_res = f->loop_filter.delta_lf_res;
+ __entry->cdef_damping_minus_3 = f->cdef.damping_minus_3;
+ __entry->cdef_bits = f->cdef.bits;
+ memcpy(__entry->cdef_y_pri_strength, f->cdef.y_pri_strength,
+ sizeof(__entry->cdef_y_pri_strength));
+ memcpy(__entry->cdef_y_sec_strength, f->cdef.y_sec_strength,
+ sizeof(__entry->cdef_y_sec_strength));
+ memcpy(__entry->cdef_uv_pri_strength, f->cdef.uv_pri_strength,
+ sizeof(__entry->cdef_uv_pri_strength));
+ memcpy(__entry->cdef_uv_sec_strength, f->cdef.uv_sec_strength,
+ sizeof(__entry->cdef_uv_sec_strength));
+ memcpy(__entry->skip_mode_frame, f->skip_mode_frame,
+ sizeof(__entry->skip_mode_frame));
+ __entry->primary_ref_frame = f->primary_ref_frame;
+ __entry->loop_restoration_flags = f->loop_restoration.flags;
+ __entry->loop_restoration_lr_unit_shift = f->loop_restoration.lr_unit_shift;
+ __entry->loop_restoration_lr_uv_shift = f->loop_restoration.lr_uv_shift;
+ memcpy(__entry->loop_restoration_frame_restoration_type,
+ f->loop_restoration.frame_restoration_type,
+ sizeof(__entry->loop_restoration_frame_restoration_type));
+ memcpy(__entry->loop_restoration_loop_restoration_size,
+ f->loop_restoration.loop_restoration_size,
+ sizeof(__entry->loop_restoration_loop_restoration_size));
+ __entry->flags = f->flags;
+ __entry->order_hint = f->order_hint;
+ __entry->upscaled_width = f->upscaled_width;
+ __entry->frame_width_minus_1 = f->frame_width_minus_1;
+ __entry->frame_height_minus_1 = f->frame_height_minus_1;
+ __entry->render_width_minus_1 = f->render_width_minus_1;
+ __entry->render_height_minus_1 = f->render_height_minus_1;
+ __entry->current_frame_id = f->current_frame_id;
+ memcpy(__entry->buffer_removal_time, f->buffer_removal_time,
+ sizeof(__entry->buffer_removal_time));
+ memcpy(__entry->order_hints, f->order_hints,
+ sizeof(__entry->order_hints));
+ memcpy(__entry->reference_frame_ts, f->reference_frame_ts,
+ sizeof(__entry->reference_frame_ts));
+ memcpy(__entry->ref_frame_idx, f->ref_frame_idx,
+ sizeof(__entry->ref_frame_idx));
+ __entry->refresh_frame_flags = f->refresh_frame_flags;),
TP_printk("\ntile_info.flags: %s\ntile_info.context_update_tile_id: %u\n"
"tile_info.tile_cols: %u\ntile_info.tile_rows: %u\n"
"tile_info.mi_col_starts: %s\ntile_info.mi_row_starts: %s\n"
@@ -87,95 +250,95 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
"render_width_minus_1: %u\nrender_height_minus_1: %u\ncurrent_frame_id: %u\n"
"buffer_removal_time: %s\norder_hints: %s\nreference_frame_ts: %s\n"
"ref_frame_idx: %s\nrefresh_frame_flags: %u\n",
- __print_flags(__entry->f.tile_info.flags, "|",
+ __print_flags(__entry->tile_info_flags, "|",
{V4L2_AV1_TILE_INFO_FLAG_UNIFORM_TILE_SPACING, "UNIFORM_TILE_SPACING"}),
- __entry->f.tile_info.context_update_tile_id,
- __entry->f.tile_info.tile_cols,
- __entry->f.tile_info.tile_rows,
- __print_array(__entry->f.tile_info.mi_col_starts,
- ARRAY_SIZE(__entry->f.tile_info.mi_col_starts),
- sizeof(__entry->f.tile_info.mi_col_starts[0])),
- __print_array(__entry->f.tile_info.mi_row_starts,
- ARRAY_SIZE(__entry->f.tile_info.mi_row_starts),
- sizeof(__entry->f.tile_info.mi_row_starts[0])),
- __print_array(__entry->f.tile_info.width_in_sbs_minus_1,
- ARRAY_SIZE(__entry->f.tile_info.width_in_sbs_minus_1),
- sizeof(__entry->f.tile_info.width_in_sbs_minus_1[0])),
- __print_array(__entry->f.tile_info.height_in_sbs_minus_1,
- ARRAY_SIZE(__entry->f.tile_info.height_in_sbs_minus_1),
- sizeof(__entry->f.tile_info.height_in_sbs_minus_1[0])),
- __entry->f.tile_info.tile_size_bytes,
- __print_flags(__entry->f.quantization.flags, "|",
+ __entry->tile_info_context_update_tile_id,
+ __entry->tile_info_tile_cols,
+ __entry->tile_info_tile_rows,
+ __print_array(__entry->tile_info_mi_col_starts,
+ ARRAY_SIZE(__entry->tile_info_mi_col_starts),
+ sizeof(__entry->tile_info_mi_col_starts[0])),
+ __print_array(__entry->tile_info_mi_row_starts,
+ ARRAY_SIZE(__entry->tile_info_mi_row_starts),
+ sizeof(__entry->tile_info_mi_row_starts[0])),
+ __print_array(__entry->tile_info_width_in_sbs_minus_1,
+ ARRAY_SIZE(__entry->tile_info_width_in_sbs_minus_1),
+ sizeof(__entry->tile_info_width_in_sbs_minus_1[0])),
+ __print_array(__entry->tile_info_height_in_sbs_minus_1,
+ ARRAY_SIZE(__entry->tile_info_height_in_sbs_minus_1),
+ sizeof(__entry->tile_info_height_in_sbs_minus_1[0])),
+ __entry->tile_info_tile_size_bytes,
+ __print_flags(__entry->quantization_flags, "|",
{V4L2_AV1_QUANTIZATION_FLAG_DIFF_UV_DELTA, "DIFF_UV_DELTA"},
{V4L2_AV1_QUANTIZATION_FLAG_USING_QMATRIX, "USING_QMATRIX"},
{V4L2_AV1_QUANTIZATION_FLAG_DELTA_Q_PRESENT, "DELTA_Q_PRESENT"}),
- __entry->f.quantization.base_q_idx,
- __entry->f.quantization.delta_q_y_dc,
- __entry->f.quantization.delta_q_u_dc,
- __entry->f.quantization.delta_q_u_ac,
- __entry->f.quantization.delta_q_v_dc,
- __entry->f.quantization.delta_q_v_ac,
- __entry->f.quantization.qm_y,
- __entry->f.quantization.qm_u,
- __entry->f.quantization.qm_v,
- __entry->f.quantization.delta_q_res,
- __entry->f.superres_denom,
- __print_flags(__entry->f.segmentation.flags, "|",
+ __entry->quantization_base_q_idx,
+ __entry->quantization_delta_q_y_dc,
+ __entry->quantization_delta_q_u_dc,
+ __entry->quantization_delta_q_u_ac,
+ __entry->quantization_delta_q_v_dc,
+ __entry->quantization_delta_q_v_ac,
+ __entry->quantization_qm_y,
+ __entry->quantization_qm_u,
+ __entry->quantization_qm_v,
+ __entry->quantization_delta_q_res,
+ __entry->superres_denom,
+ __print_flags(__entry->segmentation_flags, "|",
{V4L2_AV1_SEGMENTATION_FLAG_ENABLED, "ENABLED"},
{V4L2_AV1_SEGMENTATION_FLAG_UPDATE_MAP, "UPDATE_MAP"},
{V4L2_AV1_SEGMENTATION_FLAG_TEMPORAL_UPDATE, "TEMPORAL_UPDATE"},
{V4L2_AV1_SEGMENTATION_FLAG_UPDATE_DATA, "UPDATE_DATA"},
{V4L2_AV1_SEGMENTATION_FLAG_SEG_ID_PRE_SKIP, "SEG_ID_PRE_SKIP"}),
- __entry->f.segmentation.last_active_seg_id,
- __print_array(__entry->f.segmentation.feature_enabled,
- ARRAY_SIZE(__entry->f.segmentation.feature_enabled),
- sizeof(__entry->f.segmentation.feature_enabled[0])),
- __print_flags(__entry->f.loop_filter.flags, "|",
+ __entry->segmentation_last_active_seg_id,
+ __print_array(__entry->segmentation_feature_enabled,
+ ARRAY_SIZE(__entry->segmentation_feature_enabled),
+ sizeof(__entry->segmentation_feature_enabled[0])),
+ __print_flags(__entry->loop_filter_flags, "|",
{V4L2_AV1_LOOP_FILTER_FLAG_DELTA_ENABLED, "DELTA_ENABLED"},
{V4L2_AV1_LOOP_FILTER_FLAG_DELTA_UPDATE, "DELTA_UPDATE"},
{V4L2_AV1_LOOP_FILTER_FLAG_DELTA_LF_PRESENT, "DELTA_LF_PRESENT"},
{V4L2_AV1_LOOP_FILTER_FLAG_DELTA_LF_MULTI, "DELTA_LF_MULTI"}),
- __print_array(__entry->f.loop_filter.level,
- ARRAY_SIZE(__entry->f.loop_filter.level),
- sizeof(__entry->f.loop_filter.level[0])),
- __entry->f.loop_filter.sharpness,
- __print_array(__entry->f.loop_filter.ref_deltas,
- ARRAY_SIZE(__entry->f.loop_filter.ref_deltas),
- sizeof(__entry->f.loop_filter.ref_deltas[0])),
- __print_array(__entry->f.loop_filter.mode_deltas,
- ARRAY_SIZE(__entry->f.loop_filter.mode_deltas),
- sizeof(__entry->f.loop_filter.mode_deltas[0])),
- __entry->f.loop_filter.delta_lf_res,
- __entry->f.cdef.damping_minus_3,
- __entry->f.cdef.bits,
- __print_array(__entry->f.cdef.y_pri_strength,
- ARRAY_SIZE(__entry->f.cdef.y_pri_strength),
- sizeof(__entry->f.cdef.y_pri_strength[0])),
- __print_array(__entry->f.cdef.y_sec_strength,
- ARRAY_SIZE(__entry->f.cdef.y_sec_strength),
- sizeof(__entry->f.cdef.y_sec_strength[0])),
- __print_array(__entry->f.cdef.uv_pri_strength,
- ARRAY_SIZE(__entry->f.cdef.uv_pri_strength),
- sizeof(__entry->f.cdef.uv_pri_strength[0])),
- __print_array(__entry->f.cdef.uv_sec_strength,
- ARRAY_SIZE(__entry->f.cdef.uv_sec_strength),
- sizeof(__entry->f.cdef.uv_sec_strength[0])),
- __print_array(__entry->f.skip_mode_frame,
- ARRAY_SIZE(__entry->f.skip_mode_frame),
- sizeof(__entry->f.skip_mode_frame[0])),
- __entry->f.primary_ref_frame,
- __print_flags(__entry->f.loop_restoration.flags, "|",
+ __print_array(__entry->loop_filter_level,
+ ARRAY_SIZE(__entry->loop_filter_level),
+ sizeof(__entry->loop_filter_level[0])),
+ __entry->loop_filter_sharpness,
+ __print_array(__entry->loop_filter_ref_deltas,
+ ARRAY_SIZE(__entry->loop_filter_ref_deltas),
+ sizeof(__entry->loop_filter_ref_deltas[0])),
+ __print_array(__entry->loop_filter_mode_deltas,
+ ARRAY_SIZE(__entry->loop_filter_mode_deltas),
+ sizeof(__entry->loop_filter_mode_deltas[0])),
+ __entry->loop_filter_delta_lf_res,
+ __entry->cdef_damping_minus_3,
+ __entry->cdef_bits,
+ __print_array(__entry->cdef_y_pri_strength,
+ ARRAY_SIZE(__entry->cdef_y_pri_strength),
+ sizeof(__entry->cdef_y_pri_strength[0])),
+ __print_array(__entry->cdef_y_sec_strength,
+ ARRAY_SIZE(__entry->cdef_y_sec_strength),
+ sizeof(__entry->cdef_y_sec_strength[0])),
+ __print_array(__entry->cdef_uv_pri_strength,
+ ARRAY_SIZE(__entry->cdef_uv_pri_strength),
+ sizeof(__entry->cdef_uv_pri_strength[0])),
+ __print_array(__entry->cdef_uv_sec_strength,
+ ARRAY_SIZE(__entry->cdef_uv_sec_strength),
+ sizeof(__entry->cdef_uv_sec_strength[0])),
+ __print_array(__entry->skip_mode_frame,
+ ARRAY_SIZE(__entry->skip_mode_frame),
+ sizeof(__entry->skip_mode_frame[0])),
+ __entry->primary_ref_frame,
+ __print_flags(__entry->loop_restoration_flags, "|",
{V4L2_AV1_LOOP_RESTORATION_FLAG_USES_LR, "USES_LR"},
{V4L2_AV1_LOOP_RESTORATION_FLAG_USES_CHROMA_LR, "USES_CHROMA_LR"}),
- __entry->f.loop_restoration.lr_unit_shift,
- __entry->f.loop_restoration.lr_uv_shift,
- __print_array(__entry->f.loop_restoration.frame_restoration_type,
- ARRAY_SIZE(__entry->f.loop_restoration.frame_restoration_type),
- sizeof(__entry->f.loop_restoration.frame_restoration_type[0])),
- __print_array(__entry->f.loop_restoration.loop_restoration_size,
- ARRAY_SIZE(__entry->f.loop_restoration.loop_restoration_size),
- sizeof(__entry->f.loop_restoration.loop_restoration_size[0])),
- __print_flags(__entry->f.flags, "|",
+ __entry->loop_restoration_lr_unit_shift,
+ __entry->loop_restoration_lr_uv_shift,
+ __print_array(__entry->loop_restoration_frame_restoration_type,
+ ARRAY_SIZE(__entry->loop_restoration_frame_restoration_type),
+ sizeof(__entry->loop_restoration_frame_restoration_type[0])),
+ __print_array(__entry->loop_restoration_loop_restoration_size,
+ ARRAY_SIZE(__entry->loop_restoration_loop_restoration_size),
+ sizeof(__entry->loop_restoration_loop_restoration_size[0])),
+ __print_flags(__entry->flags, "|",
{V4L2_AV1_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
{V4L2_AV1_FRAME_FLAG_SHOWABLE_FRAME, "SHOWABLE_FRAME"},
{V4L2_AV1_FRAME_FLAG_ERROR_RESILIENT_MODE, "ERROR_RESILIENT_MODE"},
@@ -197,26 +360,26 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
{V4L2_AV1_FRAME_FLAG_FRAME_SIZE_OVERRIDE, "FRAME_SIZE_OVERRIDE"},
{V4L2_AV1_FRAME_FLAG_BUFFER_REMOVAL_TIME_PRESENT, "BUFFER_REMOVAL_TIME_PRESENT"},
{V4L2_AV1_FRAME_FLAG_FRAME_REFS_SHORT_SIGNALING, "FRAME_REFS_SHORT_SIGNALING"}),
- __entry->f.order_hint,
- __entry->f.upscaled_width,
- __entry->f.frame_width_minus_1,
- __entry->f.frame_height_minus_1,
- __entry->f.render_width_minus_1,
- __entry->f.render_height_minus_1,
- __entry->f.current_frame_id,
- __print_array(__entry->f.buffer_removal_time,
- ARRAY_SIZE(__entry->f.buffer_removal_time),
- sizeof(__entry->f.buffer_removal_time[0])),
- __print_array(__entry->f.order_hints,
- ARRAY_SIZE(__entry->f.order_hints),
- sizeof(__entry->f.order_hints[0])),
- __print_array(__entry->f.reference_frame_ts,
- ARRAY_SIZE(__entry->f.reference_frame_ts),
- sizeof(__entry->f.reference_frame_ts[0])),
- __print_array(__entry->f.ref_frame_idx,
- ARRAY_SIZE(__entry->f.ref_frame_idx),
- sizeof(__entry->f.ref_frame_idx[0])),
- __entry->f.refresh_frame_flags
+ __entry->order_hint,
+ __entry->upscaled_width,
+ __entry->frame_width_minus_1,
+ __entry->frame_height_minus_1,
+ __entry->render_width_minus_1,
+ __entry->render_height_minus_1,
+ __entry->current_frame_id,
+ __print_array(__entry->buffer_removal_time,
+ ARRAY_SIZE(__entry->buffer_removal_time),
+ sizeof(__entry->buffer_removal_time[0])),
+ __print_array(__entry->order_hints,
+ ARRAY_SIZE(__entry->order_hints),
+ sizeof(__entry->order_hints[0])),
+ __print_array(__entry->reference_frame_ts,
+ ARRAY_SIZE(__entry->reference_frame_ts),
+ sizeof(__entry->reference_frame_ts[0])),
+ __print_array(__entry->ref_frame_idx,
+ ARRAY_SIZE(__entry->ref_frame_idx),
+ sizeof(__entry->ref_frame_idx[0])),
+ __entry->refresh_frame_flags
)
);
@@ -224,8 +387,65 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_av1_film_grain, f)),
- TP_fast_assign(__entry->f = *f;),
+ TP_STRUCT__entry(__field(__u8, flags)
+ __field(__u8, cr_mult)
+ __field(__u16, grain_seed)
+ __field(__u8, film_grain_params_ref_idx)
+ __field(__u8, num_y_points)
+ __array(__u8, point_y_value, V4L2_AV1_MAX_NUM_Y_POINTS)
+ __array(__u8, point_y_scaling, V4L2_AV1_MAX_NUM_Y_POINTS)
+ __field(__u8, num_cb_points)
+ __array(__u8, point_cb_value, V4L2_AV1_MAX_NUM_CB_POINTS)
+ __array(__u8, point_cb_scaling, V4L2_AV1_MAX_NUM_CB_POINTS)
+ __field(__u8, num_cr_points)
+ __array(__u8, point_cr_value, V4L2_AV1_MAX_NUM_CR_POINTS)
+ __array(__u8, point_cr_scaling, V4L2_AV1_MAX_NUM_CR_POINTS)
+ __field(__u8, grain_scaling_minus_8)
+ __field(__u8, ar_coeff_lag)
+ __array(__u8, ar_coeffs_y_plus_128, V4L2_AV1_AR_COEFFS_SIZE)
+ __array(__u8, ar_coeffs_cb_plus_128, V4L2_AV1_AR_COEFFS_SIZE)
+ __array(__u8, ar_coeffs_cr_plus_128, V4L2_AV1_AR_COEFFS_SIZE)
+ __field(__u8, ar_coeff_shift_minus_6)
+ __field(__u8, grain_scale_shift)
+ __field(__u8, cb_mult)
+ __field(__u8, cb_luma_mult)
+ __field(__u8, cr_luma_mult)
+ __field(__u16, cb_offset)
+ __field(__u16, cr_offset)),
+ TP_fast_assign(__entry->flags = f->flags;
+ __entry->cr_mult = f->cr_mult;
+ __entry->grain_seed = f->grain_seed;
+ __entry->film_grain_params_ref_idx = f->film_grain_params_ref_idx;
+ __entry->num_y_points = f->num_y_points;
+ memcpy(__entry->point_y_value, f->point_y_value,
+ sizeof(__entry->point_y_value));
+ memcpy(__entry->point_y_scaling, f->point_y_scaling,
+ sizeof(__entry->point_y_scaling));
+ __entry->num_cb_points = f->num_cb_points;
+ memcpy(__entry->point_cb_value, f->point_cb_value,
+ sizeof(__entry->point_cb_value));
+ memcpy(__entry->point_cb_scaling, f->point_cb_scaling,
+ sizeof(__entry->point_cb_scaling));
+ __entry->num_cr_points = f->num_cr_points;
+ memcpy(__entry->point_cr_value, f->point_cr_value,
+ sizeof(__entry->point_cr_value));
+ memcpy(__entry->point_cr_scaling, f->point_cr_scaling,
+ sizeof(__entry->point_cr_scaling));
+ __entry->grain_scaling_minus_8 = f->grain_scaling_minus_8;
+ __entry->ar_coeff_lag = f->ar_coeff_lag;
+ memcpy(__entry->ar_coeffs_y_plus_128, f->ar_coeffs_y_plus_128,
+ sizeof(__entry->ar_coeffs_y_plus_128));
+ memcpy(__entry->ar_coeffs_cb_plus_128, f->ar_coeffs_cb_plus_128,
+ sizeof(__entry->ar_coeffs_cb_plus_128));
+ memcpy(__entry->ar_coeffs_cr_plus_128, f->ar_coeffs_cr_plus_128,
+ sizeof(__entry->ar_coeffs_cr_plus_128));
+ __entry->ar_coeff_shift_minus_6 = f->ar_coeff_shift_minus_6;
+ __entry->grain_scale_shift = f->grain_scale_shift;
+ __entry->cb_mult = f->cb_mult;
+ __entry->cb_luma_mult = f->cb_luma_mult;
+ __entry->cr_luma_mult = f->cr_luma_mult;
+ __entry->cb_offset = f->cb_offset;
+ __entry->cr_offset = f->cr_offset;),
TP_printk("\nflags %s\ncr_mult: %u\ngrain_seed: %u\n"
"film_grain_params_ref_idx: %u\nnum_y_points: %u\npoint_y_value: %s\n"
"point_y_scaling: %s\nnum_cb_points: %u\npoint_cb_value: %s\n"
@@ -235,54 +455,54 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
"ar_coeffs_cr_plus_128: %s\nar_coeff_shift_minus_6: %u\n"
"grain_scale_shift: %u\ncb_mult: %u\ncb_luma_mult: %u\ncr_luma_mult: %u\n"
"cb_offset: %u\ncr_offset: %u\n",
- __print_flags(__entry->f.flags, "|",
+ __print_flags(__entry->flags, "|",
{V4L2_AV1_FILM_GRAIN_FLAG_APPLY_GRAIN, "APPLY_GRAIN"},
{V4L2_AV1_FILM_GRAIN_FLAG_UPDATE_GRAIN, "UPDATE_GRAIN"},
{V4L2_AV1_FILM_GRAIN_FLAG_CHROMA_SCALING_FROM_LUMA, "CHROMA_SCALING_FROM_LUMA"},
{V4L2_AV1_FILM_GRAIN_FLAG_OVERLAP, "OVERLAP"},
{V4L2_AV1_FILM_GRAIN_FLAG_CLIP_TO_RESTRICTED_RANGE, "CLIP_TO_RESTRICTED_RANGE"}),
- __entry->f.cr_mult,
- __entry->f.grain_seed,
- __entry->f.film_grain_params_ref_idx,
- __entry->f.num_y_points,
- __print_array(__entry->f.point_y_value,
- ARRAY_SIZE(__entry->f.point_y_value),
- sizeof(__entry->f.point_y_value[0])),
- __print_array(__entry->f.point_y_scaling,
- ARRAY_SIZE(__entry->f.point_y_scaling),
- sizeof(__entry->f.point_y_scaling[0])),
- __entry->f.num_cb_points,
- __print_array(__entry->f.point_cb_value,
- ARRAY_SIZE(__entry->f.point_cb_value),
- sizeof(__entry->f.point_cb_value[0])),
- __print_array(__entry->f.point_cb_scaling,
- ARRAY_SIZE(__entry->f.point_cb_scaling),
- sizeof(__entry->f.point_cb_scaling[0])),
- __entry->f.num_cr_points,
- __print_array(__entry->f.point_cr_value,
- ARRAY_SIZE(__entry->f.point_cr_value),
- sizeof(__entry->f.point_cr_value[0])),
- __print_array(__entry->f.point_cr_scaling,
- ARRAY_SIZE(__entry->f.point_cr_scaling),
- sizeof(__entry->f.point_cr_scaling[0])),
- __entry->f.grain_scaling_minus_8,
- __entry->f.ar_coeff_lag,
- __print_array(__entry->f.ar_coeffs_y_plus_128,
- ARRAY_SIZE(__entry->f.ar_coeffs_y_plus_128),
- sizeof(__entry->f.ar_coeffs_y_plus_128[0])),
- __print_array(__entry->f.ar_coeffs_cb_plus_128,
- ARRAY_SIZE(__entry->f.ar_coeffs_cb_plus_128),
- sizeof(__entry->f.ar_coeffs_cb_plus_128[0])),
- __print_array(__entry->f.ar_coeffs_cr_plus_128,
- ARRAY_SIZE(__entry->f.ar_coeffs_cr_plus_128),
- sizeof(__entry->f.ar_coeffs_cr_plus_128[0])),
- __entry->f.ar_coeff_shift_minus_6,
- __entry->f.grain_scale_shift,
- __entry->f.cb_mult,
- __entry->f.cb_luma_mult,
- __entry->f.cr_luma_mult,
- __entry->f.cb_offset,
- __entry->f.cr_offset
+ __entry->cr_mult,
+ __entry->grain_seed,
+ __entry->film_grain_params_ref_idx,
+ __entry->num_y_points,
+ __print_array(__entry->point_y_value,
+ ARRAY_SIZE(__entry->point_y_value),
+ sizeof(__entry->point_y_value[0])),
+ __print_array(__entry->point_y_scaling,
+ ARRAY_SIZE(__entry->point_y_scaling),
+ sizeof(__entry->point_y_scaling[0])),
+ __entry->num_cb_points,
+ __print_array(__entry->point_cb_value,
+ ARRAY_SIZE(__entry->point_cb_value),
+ sizeof(__entry->point_cb_value[0])),
+ __print_array(__entry->point_cb_scaling,
+ ARRAY_SIZE(__entry->point_cb_scaling),
+ sizeof(__entry->point_cb_scaling[0])),
+ __entry->num_cr_points,
+ __print_array(__entry->point_cr_value,
+ ARRAY_SIZE(__entry->point_cr_value),
+ sizeof(__entry->point_cr_value[0])),
+ __print_array(__entry->point_cr_scaling,
+ ARRAY_SIZE(__entry->point_cr_scaling),
+ sizeof(__entry->point_cr_scaling[0])),
+ __entry->grain_scaling_minus_8,
+ __entry->ar_coeff_lag,
+ __print_array(__entry->ar_coeffs_y_plus_128,
+ ARRAY_SIZE(__entry->ar_coeffs_y_plus_128),
+ sizeof(__entry->ar_coeffs_y_plus_128[0])),
+ __print_array(__entry->ar_coeffs_cb_plus_128,
+ ARRAY_SIZE(__entry->ar_coeffs_cb_plus_128),
+ sizeof(__entry->ar_coeffs_cb_plus_128[0])),
+ __print_array(__entry->ar_coeffs_cr_plus_128,
+ ARRAY_SIZE(__entry->ar_coeffs_cr_plus_128),
+ sizeof(__entry->ar_coeffs_cr_plus_128[0])),
+ __entry->ar_coeff_shift_minus_6,
+ __entry->grain_scale_shift,
+ __entry->cb_mult,
+ __entry->cb_luma_mult,
+ __entry->cr_luma_mult,
+ __entry->cb_offset,
+ __entry->cr_offset
)
)
@@ -333,7 +553,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
__entry->ycbcr_enc = p->ycbcr_enc;
__entry->quantization = p->quantization;
),
- TP_printk("backward_ref_ts %llu version %u width %u height %u flags %s colorspace %u xfer_func %u ycbcr_enc %u quantization %u",
+ TP_printk("backward_ref_ts %llu version %u width %u height %u flags %s colorspace %u "
+ "xfer_func %u ycbcr_enc %u quantization %u",
__entry->backward_ref_ts, __entry->version, __entry->width, __entry->height,
__print_flags(__entry->flags, "|",
{V4L2_FWHT_FL_IS_INTERLACED, "IS_INTERLACED"},
@@ -362,8 +583,45 @@ DEFINE_EVENT(v4l2_ctrl_fwht_params_tmpl, v4l2_ctrl_fwht_params,
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_sps, s)),
- TP_fast_assign(__entry->s = *s),
+ TP_STRUCT__entry(__field(u8, profile_idc)
+ __field(u8, constraint_set_flags)
+ __field(u8, level_idc)
+ __field(u8, seq_parameter_set_id)
+ __field(u8, chroma_format_idc)
+ __field(u8, bit_depth_luma_minus8)
+ __field(u8, bit_depth_chroma_minus8)
+ __field(u8, log2_max_frame_num_minus4)
+ __field(u8, pic_order_cnt_type)
+ __field(u8, log2_max_pic_order_cnt_lsb_minus4)
+ __field(u8, max_num_ref_frames)
+ __field(u8, num_ref_frames_in_pic_order_cnt_cycle)
+ __array(__s32, offset_for_ref_frame, 255)
+ __field(__s32, offset_for_non_ref_pic)
+ __field(__s32, offset_for_top_to_bottom_field)
+ __field(u16, pic_width_in_mbs_minus1)
+ __field(u16, pic_height_in_map_units_minus1)
+ __field(u32, flags)),
+ TP_fast_assign(__entry->profile_idc = s->profile_idc;
+ __entry->constraint_set_flags = s->constraint_set_flags;
+ __entry->level_idc = s->level_idc;
+ __entry->seq_parameter_set_id = s->seq_parameter_set_id;
+ __entry->chroma_format_idc = s->chroma_format_idc;
+ __entry->bit_depth_luma_minus8 = s->bit_depth_luma_minus8;
+ __entry->bit_depth_chroma_minus8 = s->bit_depth_chroma_minus8;
+ __entry->log2_max_frame_num_minus4 = s->log2_max_frame_num_minus4;
+ __entry->pic_order_cnt_type = s->pic_order_cnt_type;
+ __entry->log2_max_pic_order_cnt_lsb_minus4 =
+ s->log2_max_pic_order_cnt_lsb_minus4;
+ __entry->max_num_ref_frames = s->max_num_ref_frames;
+ __entry->num_ref_frames_in_pic_order_cnt_cycle =
+ s->num_ref_frames_in_pic_order_cnt_cycle;
+ memcpy(__entry->offset_for_ref_frame, s->offset_for_ref_frame,
+ sizeof(__entry->offset_for_ref_frame));
+ __entry->offset_for_non_ref_pic = s->offset_for_non_ref_pic;
+ __entry->offset_for_top_to_bottom_field = s->offset_for_top_to_bottom_field;
+ __entry->pic_width_in_mbs_minus1 = s->pic_width_in_mbs_minus1;
+ __entry->pic_height_in_map_units_minus1 = s->pic_height_in_map_units_minus1;
+ __entry->flags = s->flags),
TP_printk("\nprofile_idc %u\n"
"constraint_set_flags %s\n"
"level_idc %u\n"
@@ -382,36 +640,38 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
"pic_width_in_mbs_minus1 %u\n"
"pic_height_in_map_units_minus1 %u\n"
"flags %s",
- __entry->s.profile_idc,
- __print_flags(__entry->s.constraint_set_flags, "|",
+ __entry->profile_idc,
+ __print_flags(__entry->constraint_set_flags, "|",
{V4L2_H264_SPS_CONSTRAINT_SET0_FLAG, "CONSTRAINT_SET0_FLAG"},
{V4L2_H264_SPS_CONSTRAINT_SET1_FLAG, "CONSTRAINT_SET1_FLAG"},
{V4L2_H264_SPS_CONSTRAINT_SET2_FLAG, "CONSTRAINT_SET2_FLAG"},
{V4L2_H264_SPS_CONSTRAINT_SET3_FLAG, "CONSTRAINT_SET3_FLAG"},
{V4L2_H264_SPS_CONSTRAINT_SET4_FLAG, "CONSTRAINT_SET4_FLAG"},
{V4L2_H264_SPS_CONSTRAINT_SET5_FLAG, "CONSTRAINT_SET5_FLAG"}),
- __entry->s.level_idc,
- __entry->s.seq_parameter_set_id,
- __entry->s.chroma_format_idc,
- __entry->s.bit_depth_luma_minus8,
- __entry->s.bit_depth_chroma_minus8,
- __entry->s.log2_max_frame_num_minus4,
- __entry->s.pic_order_cnt_type,
- __entry->s.log2_max_pic_order_cnt_lsb_minus4,
- __entry->s.max_num_ref_frames,
- __entry->s.num_ref_frames_in_pic_order_cnt_cycle,
- __print_array(__entry->s.offset_for_ref_frame,
- ARRAY_SIZE(__entry->s.offset_for_ref_frame),
- sizeof(__entry->s.offset_for_ref_frame[0])),
- __entry->s.offset_for_non_ref_pic,
- __entry->s.offset_for_top_to_bottom_field,
- __entry->s.pic_width_in_mbs_minus1,
- __entry->s.pic_height_in_map_units_minus1,
- __print_flags(__entry->s.flags, "|",
+ __entry->level_idc,
+ __entry->seq_parameter_set_id,
+ __entry->chroma_format_idc,
+ __entry->bit_depth_luma_minus8,
+ __entry->bit_depth_chroma_minus8,
+ __entry->log2_max_frame_num_minus4,
+ __entry->pic_order_cnt_type,
+ __entry->log2_max_pic_order_cnt_lsb_minus4,
+ __entry->max_num_ref_frames,
+ __entry->num_ref_frames_in_pic_order_cnt_cycle,
+ __print_array(__entry->offset_for_ref_frame,
+ ARRAY_SIZE(__entry->offset_for_ref_frame),
+ sizeof(__entry->offset_for_ref_frame[0])),
+ __entry->offset_for_non_ref_pic,
+ __entry->offset_for_top_to_bottom_field,
+ __entry->pic_width_in_mbs_minus1,
+ __entry->pic_height_in_map_units_minus1,
+ __print_flags(__entry->flags, "|",
{V4L2_H264_SPS_FLAG_SEPARATE_COLOUR_PLANE, "SEPARATE_COLOUR_PLANE"},
- {V4L2_H264_SPS_FLAG_QPPRIME_Y_ZERO_TRANSFORM_BYPASS, "QPPRIME_Y_ZERO_TRANSFORM_BYPASS"},
+ {V4L2_H264_SPS_FLAG_QPPRIME_Y_ZERO_TRANSFORM_BYPASS,
+ "QPPRIME_Y_ZERO_TRANSFORM_BYPASS"},
{V4L2_H264_SPS_FLAG_DELTA_PIC_ORDER_ALWAYS_ZERO, "DELTA_PIC_ORDER_ALWAYS_ZERO"},
- {V4L2_H264_SPS_FLAG_GAPS_IN_FRAME_NUM_VALUE_ALLOWED, "GAPS_IN_FRAME_NUM_VALUE_ALLOWED"},
+ {V4L2_H264_SPS_FLAG_GAPS_IN_FRAME_NUM_VALUE_ALLOWED,
+ "GAPS_IN_FRAME_NUM_VALUE_ALLOWED"},
{V4L2_H264_SPS_FLAG_FRAME_MBS_ONLY, "FRAME_MBS_ONLY"},
{V4L2_H264_SPS_FLAG_MB_ADAPTIVE_FRAME_FIELD, "MB_ADAPTIVE_FRAME_FIELD"},
{V4L2_H264_SPS_FLAG_DIRECT_8X8_INFERENCE, "DIRECT_8X8_INFERENCE"}
@@ -421,8 +681,30 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_pps, p)),
- TP_fast_assign(__entry->p = *p),
+ TP_STRUCT__entry(__field(u8, pic_parameter_set_id)
+ __field(u8, seq_parameter_set_id)
+ __field(u8, num_slice_groups_minus1)
+ __field(u8, num_ref_idx_l0_default_active_minus1)
+ __field(u8, num_ref_idx_l1_default_active_minus1)
+ __field(u8, weighted_bipred_idc)
+ __field(__s8, pic_init_qp_minus26)
+ __field(__s8, pic_init_qs_minus26)
+ __field(__s8, chroma_qp_index_offset)
+ __field(__s8, second_chroma_qp_index_offset)
+ __field(u16, flags)),
+ TP_fast_assign(__entry->pic_parameter_set_id = p->pic_parameter_set_id;
+ __entry->seq_parameter_set_id = p->seq_parameter_set_id;
+ __entry->num_slice_groups_minus1 = p->num_slice_groups_minus1;
+ __entry->num_ref_idx_l0_default_active_minus1 =
+ p->num_ref_idx_l0_default_active_minus1;
+ __entry->num_ref_idx_l1_default_active_minus1 =
+ p->num_ref_idx_l1_default_active_minus1;
+ __entry->weighted_bipred_idc = p->weighted_bipred_idc;
+ __entry->pic_init_qp_minus26 = p->pic_init_qp_minus26;
+ __entry->pic_init_qs_minus26 = p->pic_init_qs_minus26;
+ __entry->chroma_qp_index_offset = p->chroma_qp_index_offset;
+ __entry->second_chroma_qp_index_offset = p->second_chroma_qp_index_offset;
+ __entry->flags = p->flags),
TP_printk("\npic_parameter_set_id %u\n"
"seq_parameter_set_id %u\n"
"num_slice_groups_minus1 %u\n"
@@ -434,21 +716,23 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
"chroma_qp_index_offset %d\n"
"second_chroma_qp_index_offset %d\n"
"flags %s",
- __entry->p.pic_parameter_set_id,
- __entry->p.seq_parameter_set_id,
- __entry->p.num_slice_groups_minus1,
- __entry->p.num_ref_idx_l0_default_active_minus1,
- __entry->p.num_ref_idx_l1_default_active_minus1,
- __entry->p.weighted_bipred_idc,
- __entry->p.pic_init_qp_minus26,
- __entry->p.pic_init_qs_minus26,
- __entry->p.chroma_qp_index_offset,
- __entry->p.second_chroma_qp_index_offset,
- __print_flags(__entry->p.flags, "|",
+ __entry->pic_parameter_set_id,
+ __entry->seq_parameter_set_id,
+ __entry->num_slice_groups_minus1,
+ __entry->num_ref_idx_l0_default_active_minus1,
+ __entry->num_ref_idx_l1_default_active_minus1,
+ __entry->weighted_bipred_idc,
+ __entry->pic_init_qp_minus26,
+ __entry->pic_init_qs_minus26,
+ __entry->chroma_qp_index_offset,
+ __entry->second_chroma_qp_index_offset,
+ __print_flags(__entry->flags, "|",
{V4L2_H264_PPS_FLAG_ENTROPY_CODING_MODE, "ENTROPY_CODING_MODE"},
- {V4L2_H264_PPS_FLAG_BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT, "BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT"},
+ {V4L2_H264_PPS_FLAG_BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT,
+ "BOTTOM_FIELD_PIC_ORDER_IN_FRAME_PRESENT"},
{V4L2_H264_PPS_FLAG_WEIGHTED_PRED, "WEIGHTED_PRED"},
- {V4L2_H264_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT, "DEBLOCKING_FILTER_CONTROL_PRESENT"},
+ {V4L2_H264_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT,
+ "DEBLOCKING_FILTER_CONTROL_PRESENT"},
{V4L2_H264_PPS_FLAG_CONSTRAINED_INTRA_PRED, "CONSTRAINED_INTRA_PRED"},
{V4L2_H264_PPS_FLAG_REDUNDANT_PIC_CNT_PRESENT, "REDUNDANT_PIC_CNT_PRESENT"},
{V4L2_H264_PPS_FLAG_TRANSFORM_8X8_MODE, "TRANSFORM_8X8_MODE"},
@@ -459,16 +743,20 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_scaling_matrix_tmpl,
TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_scaling_matrix, s)),
- TP_fast_assign(__entry->s = *s),
+ TP_STRUCT__entry(__array(u8, scaling_list_4x4, 6 * 16)
+ __array(u8, scaling_list_8x8, 6 * 64)),
+ TP_fast_assign(memcpy(__entry->scaling_list_4x4, s->scaling_list_4x4,
+ sizeof(__entry->scaling_list_4x4));
+ memcpy(__entry->scaling_list_8x8, s->scaling_list_8x8,
+ sizeof(__entry->scaling_list_8x8))),
TP_printk("\nscaling_list_4x4 {%s}\nscaling_list_8x8 {%s}",
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_4x4,
- sizeof(__entry->s.scaling_list_4x4),
+ __entry->scaling_list_4x4,
+ sizeof(__entry->scaling_list_4x4),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_8x8,
- sizeof(__entry->s.scaling_list_8x8),
+ __entry->scaling_list_8x8,
+ sizeof(__entry->scaling_list_8x8),
false)
)
);
@@ -476,8 +764,42 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_scaling_matrix_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_pred_weights, p)),
- TP_fast_assign(__entry->p = *p),
+ TP_STRUCT__entry(__field(u16, luma_log2_weight_denom)
+ __field(u16, chroma_log2_weight_denom)
+ __array(__s16, weight_factors_0_luma_weight, 32)
+ __array(__s16, weight_factors_0_luma_offset, 32)
+ __array(__s16, weight_factors_0_chroma_weight, 32 * 2)
+ __array(__s16, weight_factors_0_chroma_offset, 32 * 2)
+ __array(__s16, weight_factors_1_luma_weight, 32)
+ __array(__s16, weight_factors_1_luma_offset, 32)
+ __array(__s16, weight_factors_1_chroma_weight, 32 * 2)
+ __array(__s16, weight_factors_1_chroma_offset, 32 * 2)),
+ TP_fast_assign(__entry->luma_log2_weight_denom = p->luma_log2_weight_denom;
+ __entry->chroma_log2_weight_denom = p->chroma_log2_weight_denom;
+ memcpy(__entry->weight_factors_0_luma_weight,
+ p->weight_factors[0].luma_weight,
+ sizeof(__entry->weight_factors_0_luma_weight));
+ memcpy(__entry->weight_factors_0_luma_offset,
+ p->weight_factors[0].luma_offset,
+ sizeof(__entry->weight_factors_0_luma_offset));
+ memcpy(__entry->weight_factors_0_chroma_weight,
+ p->weight_factors[0].chroma_weight,
+ sizeof(__entry->weight_factors_0_chroma_weight));
+ memcpy(__entry->weight_factors_0_chroma_offset,
+ p->weight_factors[0].chroma_offset,
+ sizeof(__entry->weight_factors_0_chroma_offset));
+ memcpy(__entry->weight_factors_1_luma_weight,
+ p->weight_factors[1].luma_weight,
+ sizeof(__entry->weight_factors_1_luma_weight));
+ memcpy(__entry->weight_factors_1_luma_offset,
+ p->weight_factors[1].luma_offset,
+ sizeof(__entry->weight_factors_1_luma_offset));
+ memcpy(__entry->weight_factors_1_chroma_weight,
+ p->weight_factors[1].chroma_weight,
+ sizeof(__entry->weight_factors_1_chroma_weight));
+ memcpy(__entry->weight_factors_1_chroma_offset,
+ p->weight_factors[1].chroma_offset,
+ sizeof(__entry->weight_factors_1_chroma_offset))),
TP_printk("\nluma_log2_weight_denom %u\n"
"chroma_log2_weight_denom %u\n"
"weight_factor[0].luma_weight %s\n"
@@ -488,35 +810,35 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
"weight_factor[1].luma_offset %s\n"
"weight_factor[1].chroma_weight {%s}\n"
"weight_factor[1].chroma_offset {%s}\n",
- __entry->p.luma_log2_weight_denom,
- __entry->p.chroma_log2_weight_denom,
- __print_array(__entry->p.weight_factors[0].luma_weight,
- ARRAY_SIZE(__entry->p.weight_factors[0].luma_weight),
- sizeof(__entry->p.weight_factors[0].luma_weight[0])),
- __print_array(__entry->p.weight_factors[0].luma_offset,
- ARRAY_SIZE(__entry->p.weight_factors[0].luma_offset),
- sizeof(__entry->p.weight_factors[0].luma_offset[0])),
+ __entry->luma_log2_weight_denom,
+ __entry->chroma_log2_weight_denom,
+ __print_array(__entry->weight_factors_0_luma_weight,
+ ARRAY_SIZE(__entry->weight_factors_0_luma_weight),
+ sizeof(__entry->weight_factors_0_luma_weight[0])),
+ __print_array(__entry->weight_factors_0_luma_offset,
+ ARRAY_SIZE(__entry->weight_factors_0_luma_offset),
+ sizeof(__entry->weight_factors_0_luma_offset[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[0].chroma_weight,
- sizeof(__entry->p.weight_factors[0].chroma_weight),
+ __entry->weight_factors_0_chroma_weight,
+ sizeof(__entry->weight_factors_0_chroma_weight),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[0].chroma_offset,
- sizeof(__entry->p.weight_factors[0].chroma_offset),
+ __entry->weight_factors_0_chroma_offset,
+ sizeof(__entry->weight_factors_0_chroma_offset),
false),
- __print_array(__entry->p.weight_factors[1].luma_weight,
- ARRAY_SIZE(__entry->p.weight_factors[1].luma_weight),
- sizeof(__entry->p.weight_factors[1].luma_weight[0])),
- __print_array(__entry->p.weight_factors[1].luma_offset,
- ARRAY_SIZE(__entry->p.weight_factors[1].luma_offset),
- sizeof(__entry->p.weight_factors[1].luma_offset[0])),
+ __print_array(__entry->weight_factors_1_luma_weight,
+ ARRAY_SIZE(__entry->weight_factors_1_luma_weight),
+ sizeof(__entry->weight_factors_1_luma_weight[0])),
+ __print_array(__entry->weight_factors_1_luma_offset,
+ ARRAY_SIZE(__entry->weight_factors_1_luma_offset),
+ sizeof(__entry->weight_factors_1_luma_offset[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[1].chroma_weight,
- sizeof(__entry->p.weight_factors[1].chroma_weight),
+ __entry->weight_factors_1_chroma_weight,
+ sizeof(__entry->weight_factors_1_chroma_weight),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.weight_factors[1].chroma_offset,
- sizeof(__entry->p.weight_factors[1].chroma_offset),
+ __entry->weight_factors_1_chroma_offset,
+ sizeof(__entry->weight_factors_1_chroma_offset),
false)
)
);
@@ -524,8 +846,34 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_slice_params, s)),
- TP_fast_assign(__entry->s = *s),
+ TP_STRUCT__entry(__field(u32, header_bit_size)
+ __field(u32, first_mb_in_slice)
+ __field(u8, slice_type)
+ __field(u8, colour_plane_id)
+ __field(u8, redundant_pic_cnt)
+ __field(u8, cabac_init_idc)
+ __field(__s8, slice_qp_delta)
+ __field(__s8, slice_qs_delta)
+ __field(u8, disable_deblocking_filter_idc)
+ __field(__s8, slice_alpha_c0_offset_div2)
+ __field(__s8, slice_beta_offset_div2)
+ __field(u8, num_ref_idx_l0_active_minus1)
+ __field(u8, num_ref_idx_l1_active_minus1)
+ __field(u32, flags)),
+ TP_fast_assign(__entry->header_bit_size = s->header_bit_size;
+ __entry->first_mb_in_slice = s->first_mb_in_slice;
+ __entry->slice_type = s->slice_type;
+ __entry->colour_plane_id = s->colour_plane_id;
+ __entry->redundant_pic_cnt = s->redundant_pic_cnt;
+ __entry->cabac_init_idc = s->cabac_init_idc;
+ __entry->slice_qp_delta = s->slice_qp_delta;
+ __entry->slice_qs_delta = s->slice_qs_delta;
+ __entry->disable_deblocking_filter_idc = s->disable_deblocking_filter_idc;
+ __entry->slice_alpha_c0_offset_div2 = s->slice_alpha_c0_offset_div2;
+ __entry->slice_beta_offset_div2 = s->slice_beta_offset_div2;
+ __entry->num_ref_idx_l0_active_minus1 = s->num_ref_idx_l0_active_minus1;
+ __entry->num_ref_idx_l1_active_minus1 = s->num_ref_idx_l1_active_minus1;
+ __entry->flags = s->flags),
TP_printk("\nheader_bit_size %u\n"
"first_mb_in_slice %u\n"
"slice_type %s\n"
@@ -540,25 +888,25 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
"num_ref_idx_l0_active_minus1 %u\n"
"num_ref_idx_l1_active_minus1 %u\n"
"flags %s",
- __entry->s.header_bit_size,
- __entry->s.first_mb_in_slice,
- __print_symbolic(__entry->s.slice_type,
+ __entry->header_bit_size,
+ __entry->first_mb_in_slice,
+ __print_symbolic(__entry->slice_type,
{V4L2_H264_SLICE_TYPE_P, "P"},
{V4L2_H264_SLICE_TYPE_B, "B"},
{V4L2_H264_SLICE_TYPE_I, "I"},
{V4L2_H264_SLICE_TYPE_SP, "SP"},
{V4L2_H264_SLICE_TYPE_SI, "SI"}),
- __entry->s.colour_plane_id,
- __entry->s.redundant_pic_cnt,
- __entry->s.cabac_init_idc,
- __entry->s.slice_qp_delta,
- __entry->s.slice_qs_delta,
- __entry->s.disable_deblocking_filter_idc,
- __entry->s.slice_alpha_c0_offset_div2,
- __entry->s.slice_beta_offset_div2,
- __entry->s.num_ref_idx_l0_active_minus1,
- __entry->s.num_ref_idx_l1_active_minus1,
- __print_flags(__entry->s.flags, "|",
+ __entry->colour_plane_id,
+ __entry->redundant_pic_cnt,
+ __entry->cabac_init_idc,
+ __entry->slice_qp_delta,
+ __entry->slice_qs_delta,
+ __entry->disable_deblocking_filter_idc,
+ __entry->slice_alpha_c0_offset_div2,
+ __entry->slice_beta_offset_div2,
+ __entry->num_ref_idx_l0_active_minus1,
+ __entry->num_ref_idx_l1_active_minus1,
+ __print_flags(__entry->flags, "|",
{V4L2_H264_SLICE_FLAG_DIRECT_SPATIAL_MV_PRED, "DIRECT_SPATIAL_MV_PRED"},
{V4L2_H264_SLICE_FLAG_SP_FOR_SWITCH, "SP_FOR_SWITCH"})
)
@@ -567,24 +915,51 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
DECLARE_EVENT_CLASS(v4l2_h264_reference_tmpl,
TP_PROTO(const struct v4l2_h264_reference *r, int i),
TP_ARGS(r, i),
- TP_STRUCT__entry(__field_struct(struct v4l2_h264_reference, r)
+ TP_STRUCT__entry(__field(u8, fields)
+ __field(u8, index)
__field(int, i)),
- TP_fast_assign(__entry->r = *r; __entry->i = i;),
+ TP_fast_assign(__entry->fields = r->fields;
+ __entry->index = r->index;
+ __entry->i = i;),
TP_printk("[%d]: fields %s index %u",
__entry->i,
- __print_flags(__entry->r.fields, "|",
+ __print_flags(__entry->fields, "|",
{V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
{V4L2_H264_BOTTOM_FIELD_REF, "BOTTOM_FIELD_REF"},
{V4L2_H264_FRAME_REF, "FRAME_REF"}),
- __entry->r.index
+ __entry->index
)
);
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
TP_ARGS(d),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_h264_decode_params, d)),
- TP_fast_assign(__entry->d = *d),
+ TP_STRUCT__entry(__field(u16, nal_ref_idc)
+ __field(u16, frame_num)
+ __field(__s32, top_field_order_cnt)
+ __field(__s32, bottom_field_order_cnt)
+ __field(u16, idr_pic_id)
+ __field(u16, pic_order_cnt_lsb)
+ __field(__s32, delta_pic_order_cnt_bottom)
+ __field(__s32, delta_pic_order_cnt0)
+ __field(__s32, delta_pic_order_cnt1)
+ __field(u32, dec_ref_pic_marking_bit_size)
+ __field(u32, pic_order_cnt_bit_size)
+ __field(u32, slice_group_change_cycle)
+ __field(u32, flags)),
+ TP_fast_assign(__entry->nal_ref_idc = d->nal_ref_idc;
+ __entry->frame_num = d->frame_num;
+ __entry->top_field_order_cnt = d->top_field_order_cnt;
+ __entry->bottom_field_order_cnt = d->bottom_field_order_cnt;
+ __entry->idr_pic_id = d->idr_pic_id;
+ __entry->pic_order_cnt_lsb = d->pic_order_cnt_lsb;
+ __entry->delta_pic_order_cnt_bottom = d->delta_pic_order_cnt_bottom;
+ __entry->delta_pic_order_cnt0 = d->delta_pic_order_cnt0;
+ __entry->delta_pic_order_cnt1 = d->delta_pic_order_cnt1;
+ __entry->dec_ref_pic_marking_bit_size = d->dec_ref_pic_marking_bit_size;
+ __entry->pic_order_cnt_bit_size = d->pic_order_cnt_bit_size;
+ __entry->slice_group_change_cycle = d->slice_group_change_cycle;
+ __entry->flags = d->flags),
TP_printk("\nnal_ref_idc %u\n"
"frame_num %u\n"
"top_field_order_cnt %d\n"
@@ -598,19 +973,19 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
"pic_order_cnt_bit_size %u\n"
"slice_group_change_cycle %u\n"
"flags %s\n",
- __entry->d.nal_ref_idc,
- __entry->d.frame_num,
- __entry->d.top_field_order_cnt,
- __entry->d.bottom_field_order_cnt,
- __entry->d.idr_pic_id,
- __entry->d.pic_order_cnt_lsb,
- __entry->d.delta_pic_order_cnt_bottom,
- __entry->d.delta_pic_order_cnt0,
- __entry->d.delta_pic_order_cnt1,
- __entry->d.dec_ref_pic_marking_bit_size,
- __entry->d.pic_order_cnt_bit_size,
- __entry->d.slice_group_change_cycle,
- __print_flags(__entry->d.flags, "|",
+ __entry->nal_ref_idc,
+ __entry->frame_num,
+ __entry->top_field_order_cnt,
+ __entry->bottom_field_order_cnt,
+ __entry->idr_pic_id,
+ __entry->pic_order_cnt_lsb,
+ __entry->delta_pic_order_cnt_bottom,
+ __entry->delta_pic_order_cnt0,
+ __entry->delta_pic_order_cnt1,
+ __entry->dec_ref_pic_marking_bit_size,
+ __entry->pic_order_cnt_bit_size,
+ __entry->slice_group_change_cycle,
+ __print_flags(__entry->flags, "|",
{V4L2_H264_DECODE_PARAM_FLAG_IDR_PIC, "IDR_PIC"},
{V4L2_H264_DECODE_PARAM_FLAG_FIELD_PIC, "FIELD_PIC"},
{V4L2_H264_DECODE_PARAM_FLAG_BOTTOM_FIELD, "BOTTOM_FIELD"},
@@ -622,22 +997,35 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
TP_ARGS(e, i),
- TP_STRUCT__entry(__field_struct(struct v4l2_h264_dpb_entry, e)
+ TP_STRUCT__entry(__field(u64, reference_ts)
+ __field(u32, pic_num)
+ __field(u16, frame_num)
+ __field(u8, fields)
+ __field(__s32, top_field_order_cnt)
+ __field(__s32, bottom_field_order_cnt)
+ __field(u32, flags)
__field(int, i)),
- TP_fast_assign(__entry->e = *e; __entry->i = i;),
+ TP_fast_assign(__entry->reference_ts = e->reference_ts;
+ __entry->pic_num = e->pic_num;
+ __entry->frame_num = e->frame_num;
+ __entry->fields = e->fields;
+ __entry->top_field_order_cnt = e->top_field_order_cnt;
+ __entry->bottom_field_order_cnt = e->bottom_field_order_cnt;
+ __entry->flags = e->flags;
+ __entry->i = i;),
TP_printk("[%d]: reference_ts %llu, pic_num %u frame_num %u fields %s "
"top_field_order_cnt %d bottom_field_order_cnt %d flags %s",
__entry->i,
- __entry->e.reference_ts,
- __entry->e.pic_num,
- __entry->e.frame_num,
- __print_flags(__entry->e.fields, "|",
+ __entry->reference_ts,
+ __entry->pic_num,
+ __entry->frame_num,
+ __print_flags(__entry->fields, "|",
{V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
{V4L2_H264_BOTTOM_FIELD_REF, "BOTTOM_FIELD_REF"},
{V4L2_H264_FRAME_REF, "FRAME_REF"}),
- __entry->e.top_field_order_cnt,
- __entry->e.bottom_field_order_cnt,
- __print_flags(__entry->e.flags, "|",
+ __entry->top_field_order_cnt,
+ __entry->bottom_field_order_cnt,
+ __print_flags(__entry->flags, "|",
{V4L2_H264_DPB_ENTRY_FLAG_VALID, "VALID"},
{V4L2_H264_DPB_ENTRY_FLAG_ACTIVE, "ACTIVE"},
{V4L2_H264_DPB_ENTRY_FLAG_LONG_TERM, "LONG_TERM"},
@@ -696,8 +1084,68 @@ DEFINE_EVENT(v4l2_h264_dpb_entry_tmpl, v4l2_h264_dpb_entry,
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_sps, s)),
- TP_fast_assign(__entry->s = *s),
+ TP_STRUCT__entry(__field(__u8, video_parameter_set_id)
+ __field(__u8, seq_parameter_set_id)
+ __field(__u16, pic_width_in_luma_samples)
+ __field(__u16, pic_height_in_luma_samples)
+ __field(__u8, bit_depth_luma_minus8)
+ __field(__u8, bit_depth_chroma_minus8)
+ __field(__u8, log2_max_pic_order_cnt_lsb_minus4)
+ __field(__u8, sps_max_dec_pic_buffering_minus1)
+ __field(__u8, sps_max_num_reorder_pics)
+ __field(__u8, sps_max_latency_increase_plus1)
+ __field(__u8, log2_min_luma_coding_block_size_minus3)
+ __field(__u8, log2_diff_max_min_luma_coding_block_size)
+ __field(__u8, log2_min_luma_transform_block_size_minus2)
+ __field(__u8, log2_diff_max_min_luma_transform_block_size)
+ __field(__u8, max_transform_hierarchy_depth_inter)
+ __field(__u8, max_transform_hierarchy_depth_intra)
+ __field(__u8, pcm_sample_bit_depth_luma_minus1)
+ __field(__u8, pcm_sample_bit_depth_chroma_minus1)
+ __field(__u8, log2_min_pcm_luma_coding_block_size_minus3)
+ __field(__u8, log2_diff_max_min_pcm_luma_coding_block_size)
+ __field(__u8, num_short_term_ref_pic_sets)
+ __field(__u8, num_long_term_ref_pics_sps)
+ __field(__u8, chroma_format_idc)
+ __field(__u8, sps_max_sub_layers_minus1)
+ __field(__u64, flags)),
+ TP_fast_assign(__entry->video_parameter_set_id = s->video_parameter_set_id;
+ __entry->seq_parameter_set_id = s->seq_parameter_set_id;
+ __entry->pic_width_in_luma_samples = s->pic_width_in_luma_samples;
+ __entry->pic_height_in_luma_samples = s->pic_height_in_luma_samples;
+ __entry->bit_depth_luma_minus8 = s->bit_depth_luma_minus8;
+ __entry->bit_depth_chroma_minus8 = s->bit_depth_chroma_minus8;
+ __entry->log2_max_pic_order_cnt_lsb_minus4 =
+ s->log2_max_pic_order_cnt_lsb_minus4;
+ __entry->sps_max_dec_pic_buffering_minus1 =
+ s->sps_max_dec_pic_buffering_minus1;
+ __entry->sps_max_num_reorder_pics = s->sps_max_num_reorder_pics;
+ __entry->sps_max_latency_increase_plus1 = s->sps_max_latency_increase_plus1;
+ __entry->log2_min_luma_coding_block_size_minus3 =
+ s->log2_min_luma_coding_block_size_minus3;
+ __entry->log2_diff_max_min_luma_coding_block_size =
+ s->log2_diff_max_min_luma_coding_block_size;
+ __entry->log2_min_luma_transform_block_size_minus2 =
+ s->log2_min_luma_transform_block_size_minus2;
+ __entry->log2_diff_max_min_luma_transform_block_size =
+ s->log2_diff_max_min_luma_transform_block_size;
+ __entry->max_transform_hierarchy_depth_inter =
+ s->max_transform_hierarchy_depth_inter;
+ __entry->max_transform_hierarchy_depth_intra =
+ s->max_transform_hierarchy_depth_intra;
+ __entry->pcm_sample_bit_depth_luma_minus1 =
+ s->pcm_sample_bit_depth_luma_minus1;
+ __entry->pcm_sample_bit_depth_chroma_minus1 =
+ s->pcm_sample_bit_depth_chroma_minus1;
+ __entry->log2_min_pcm_luma_coding_block_size_minus3 =
+ s->log2_min_pcm_luma_coding_block_size_minus3;
+ __entry->log2_diff_max_min_pcm_luma_coding_block_size =
+ s->log2_diff_max_min_pcm_luma_coding_block_size;
+ __entry->num_short_term_ref_pic_sets = s->num_short_term_ref_pic_sets;
+ __entry->num_long_term_ref_pics_sps = s->num_long_term_ref_pics_sps;
+ __entry->chroma_format_idc = s->chroma_format_idc;
+ __entry->sps_max_sub_layers_minus1 = s->sps_max_sub_layers_minus1;
+ __entry->flags = s->flags;),
TP_printk("\nvideo_parameter_set_id %u\n"
"seq_parameter_set_id %u\n"
"pic_width_in_luma_samples %u\n"
@@ -723,40 +1171,42 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
"chroma_format_idc %u\n"
"sps_max_sub_layers_minus1 %u\n"
"flags %s",
- __entry->s.video_parameter_set_id,
- __entry->s.seq_parameter_set_id,
- __entry->s.pic_width_in_luma_samples,
- __entry->s.pic_height_in_luma_samples,
- __entry->s.bit_depth_luma_minus8,
- __entry->s.bit_depth_chroma_minus8,
- __entry->s.log2_max_pic_order_cnt_lsb_minus4,
- __entry->s.sps_max_dec_pic_buffering_minus1,
- __entry->s.sps_max_num_reorder_pics,
- __entry->s.sps_max_latency_increase_plus1,
- __entry->s.log2_min_luma_coding_block_size_minus3,
- __entry->s.log2_diff_max_min_luma_coding_block_size,
- __entry->s.log2_min_luma_transform_block_size_minus2,
- __entry->s.log2_diff_max_min_luma_transform_block_size,
- __entry->s.max_transform_hierarchy_depth_inter,
- __entry->s.max_transform_hierarchy_depth_intra,
- __entry->s.pcm_sample_bit_depth_luma_minus1,
- __entry->s.pcm_sample_bit_depth_chroma_minus1,
- __entry->s.log2_min_pcm_luma_coding_block_size_minus3,
- __entry->s.log2_diff_max_min_pcm_luma_coding_block_size,
- __entry->s.num_short_term_ref_pic_sets,
- __entry->s.num_long_term_ref_pics_sps,
- __entry->s.chroma_format_idc,
- __entry->s.sps_max_sub_layers_minus1,
- __print_flags(__entry->s.flags, "|",
+ __entry->video_parameter_set_id,
+ __entry->seq_parameter_set_id,
+ __entry->pic_width_in_luma_samples,
+ __entry->pic_height_in_luma_samples,
+ __entry->bit_depth_luma_minus8,
+ __entry->bit_depth_chroma_minus8,
+ __entry->log2_max_pic_order_cnt_lsb_minus4,
+ __entry->sps_max_dec_pic_buffering_minus1,
+ __entry->sps_max_num_reorder_pics,
+ __entry->sps_max_latency_increase_plus1,
+ __entry->log2_min_luma_coding_block_size_minus3,
+ __entry->log2_diff_max_min_luma_coding_block_size,
+ __entry->log2_min_luma_transform_block_size_minus2,
+ __entry->log2_diff_max_min_luma_transform_block_size,
+ __entry->max_transform_hierarchy_depth_inter,
+ __entry->max_transform_hierarchy_depth_intra,
+ __entry->pcm_sample_bit_depth_luma_minus1,
+ __entry->pcm_sample_bit_depth_chroma_minus1,
+ __entry->log2_min_pcm_luma_coding_block_size_minus3,
+ __entry->log2_diff_max_min_pcm_luma_coding_block_size,
+ __entry->num_short_term_ref_pic_sets,
+ __entry->num_long_term_ref_pics_sps,
+ __entry->chroma_format_idc,
+ __entry->sps_max_sub_layers_minus1,
+ __print_flags(__entry->flags, "|",
{V4L2_HEVC_SPS_FLAG_SEPARATE_COLOUR_PLANE, "SEPARATE_COLOUR_PLANE"},
{V4L2_HEVC_SPS_FLAG_SCALING_LIST_ENABLED, "SCALING_LIST_ENABLED"},
{V4L2_HEVC_SPS_FLAG_AMP_ENABLED, "AMP_ENABLED"},
{V4L2_HEVC_SPS_FLAG_SAMPLE_ADAPTIVE_OFFSET, "SAMPLE_ADAPTIVE_OFFSET"},
{V4L2_HEVC_SPS_FLAG_PCM_ENABLED, "PCM_ENABLED"},
- {V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED, "V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED"},
+ {V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED,
+ "V4L2_HEVC_SPS_FLAG_PCM_LOOP_FILTER_DISABLED"},
{V4L2_HEVC_SPS_FLAG_LONG_TERM_REF_PICS_PRESENT, "LONG_TERM_REF_PICS_PRESENT"},
{V4L2_HEVC_SPS_FLAG_SPS_TEMPORAL_MVP_ENABLED, "TEMPORAL_MVP_ENABLED"},
- {V4L2_HEVC_SPS_FLAG_STRONG_INTRA_SMOOTHING_ENABLED, "STRONG_INTRA_SMOOTHING_ENABLED"}
+ {V4L2_HEVC_SPS_FLAG_STRONG_INTRA_SMOOTHING_ENABLED,
+ "STRONG_INTRA_SMOOTHING_ENABLED"}
))
);
@@ -765,8 +1215,43 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_pps, p)),
- TP_fast_assign(__entry->p = *p),
+ TP_STRUCT__entry(__field(__u8, pic_parameter_set_id)
+ __field(__u8, num_extra_slice_header_bits)
+ __field(__u8, num_ref_idx_l0_default_active_minus1)
+ __field(__u8, num_ref_idx_l1_default_active_minus1)
+ __field(__s8, init_qp_minus26)
+ __field(__u8, diff_cu_qp_delta_depth)
+ __field(__s8, pps_cb_qp_offset)
+ __field(__s8, pps_cr_qp_offset)
+ __field(__u8, num_tile_columns_minus1)
+ __field(__u8, num_tile_rows_minus1)
+ __array(__u8, column_width_minus1, 20)
+ __array(__u8, row_height_minus1, 22)
+ __field(__s8, pps_beta_offset_div2)
+ __field(__s8, pps_tc_offset_div2)
+ __field(__u8, log2_parallel_merge_level_minus2)
+ __field(__u64, flags)),
+ TP_fast_assign(__entry->pic_parameter_set_id = p->pic_parameter_set_id;
+ __entry->num_extra_slice_header_bits = p->num_extra_slice_header_bits;
+ __entry->num_ref_idx_l0_default_active_minus1 =
+ p->num_ref_idx_l0_default_active_minus1;
+ __entry->num_ref_idx_l1_default_active_minus1 =
+ p->num_ref_idx_l1_default_active_minus1;
+ __entry->init_qp_minus26 = p->init_qp_minus26;
+ __entry->diff_cu_qp_delta_depth = p->diff_cu_qp_delta_depth;
+ __entry->pps_cb_qp_offset = p->pps_cb_qp_offset;
+ __entry->pps_cr_qp_offset = p->pps_cr_qp_offset;
+ __entry->num_tile_columns_minus1 = p->num_tile_columns_minus1;
+ __entry->num_tile_rows_minus1 = p->num_tile_rows_minus1;
+ memcpy(__entry->column_width_minus1, p->column_width_minus1,
+ sizeof(__entry->column_width_minus1));
+ memcpy(__entry->row_height_minus1, p->row_height_minus1,
+ sizeof(__entry->row_height_minus1));
+ __entry->pps_beta_offset_div2 = p->pps_beta_offset_div2;
+ __entry->pps_tc_offset_div2 = p->pps_tc_offset_div2;
+ __entry->log2_parallel_merge_level_minus2 =
+ p->log2_parallel_merge_level_minus2;
+ __entry->flags = p->flags;),
TP_printk("\npic_parameter_set_id %u\n"
"num_extra_slice_header_bits %u\n"
"num_ref_idx_l0_default_active_minus1 %u\n"
@@ -783,45 +1268,52 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
"pps_tc_offset_div2 %d\n"
"log2_parallel_merge_level_minus2 %u\n"
"flags %s",
- __entry->p.pic_parameter_set_id,
- __entry->p.num_extra_slice_header_bits,
- __entry->p.num_ref_idx_l0_default_active_minus1,
- __entry->p.num_ref_idx_l1_default_active_minus1,
- __entry->p.init_qp_minus26,
- __entry->p.diff_cu_qp_delta_depth,
- __entry->p.pps_cb_qp_offset,
- __entry->p.pps_cr_qp_offset,
- __entry->p.num_tile_columns_minus1,
- __entry->p.num_tile_rows_minus1,
- __print_array(__entry->p.column_width_minus1,
- ARRAY_SIZE(__entry->p.column_width_minus1),
- sizeof(__entry->p.column_width_minus1[0])),
- __print_array(__entry->p.row_height_minus1,
- ARRAY_SIZE(__entry->p.row_height_minus1),
- sizeof(__entry->p.row_height_minus1[0])),
- __entry->p.pps_beta_offset_div2,
- __entry->p.pps_tc_offset_div2,
- __entry->p.log2_parallel_merge_level_minus2,
- __print_flags(__entry->p.flags, "|",
- {V4L2_HEVC_PPS_FLAG_DEPENDENT_SLICE_SEGMENT_ENABLED, "DEPENDENT_SLICE_SEGMENT_ENABLED"},
+ __entry->pic_parameter_set_id,
+ __entry->num_extra_slice_header_bits,
+ __entry->num_ref_idx_l0_default_active_minus1,
+ __entry->num_ref_idx_l1_default_active_minus1,
+ __entry->init_qp_minus26,
+ __entry->diff_cu_qp_delta_depth,
+ __entry->pps_cb_qp_offset,
+ __entry->pps_cr_qp_offset,
+ __entry->num_tile_columns_minus1,
+ __entry->num_tile_rows_minus1,
+ __print_array(__entry->column_width_minus1,
+ ARRAY_SIZE(__entry->column_width_minus1),
+ sizeof(__entry->column_width_minus1[0])),
+ __print_array(__entry->row_height_minus1,
+ ARRAY_SIZE(__entry->row_height_minus1),
+ sizeof(__entry->row_height_minus1[0])),
+ __entry->pps_beta_offset_div2,
+ __entry->pps_tc_offset_div2,
+ __entry->log2_parallel_merge_level_minus2,
+ __print_flags(__entry->flags, "|",
+ {V4L2_HEVC_PPS_FLAG_DEPENDENT_SLICE_SEGMENT_ENABLED,
+ "DEPENDENT_SLICE_SEGMENT_ENABLED"},
{V4L2_HEVC_PPS_FLAG_OUTPUT_FLAG_PRESENT, "OUTPUT_FLAG_PRESENT"},
{V4L2_HEVC_PPS_FLAG_SIGN_DATA_HIDING_ENABLED, "SIGN_DATA_HIDING_ENABLED"},
{V4L2_HEVC_PPS_FLAG_CABAC_INIT_PRESENT, "CABAC_INIT_PRESENT"},
{V4L2_HEVC_PPS_FLAG_CONSTRAINED_INTRA_PRED, "CONSTRAINED_INTRA_PRED"},
{V4L2_HEVC_PPS_FLAG_CU_QP_DELTA_ENABLED, "CU_QP_DELTA_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT, "PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT,
+ "PPS_SLICE_CHROMA_QP_OFFSETS_PRESENT"},
{V4L2_HEVC_PPS_FLAG_WEIGHTED_PRED, "WEIGHTED_PRED"},
{V4L2_HEVC_PPS_FLAG_WEIGHTED_BIPRED, "WEIGHTED_BIPRED"},
{V4L2_HEVC_PPS_FLAG_TRANSQUANT_BYPASS_ENABLED, "TRANSQUANT_BYPASS_ENABLED"},
{V4L2_HEVC_PPS_FLAG_TILES_ENABLED, "TILES_ENABLED"},
{V4L2_HEVC_PPS_FLAG_ENTROPY_CODING_SYNC_ENABLED, "ENTROPY_CODING_SYNC_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_LOOP_FILTER_ACROSS_TILES_ENABLED, "LOOP_FILTER_ACROSS_TILES_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED, "PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
- {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_OVERRIDE_ENABLED, "DEBLOCKING_FILTER_OVERRIDE_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_LOOP_FILTER_ACROSS_TILES_ENABLED,
+ "LOOP_FILTER_ACROSS_TILES_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED,
+ "PPS_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
+ {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_OVERRIDE_ENABLED,
+ "DEBLOCKING_FILTER_OVERRIDE_ENABLED"},
{V4L2_HEVC_PPS_FLAG_PPS_DISABLE_DEBLOCKING_FILTER, "DISABLE_DEBLOCKING_FILTER"},
{V4L2_HEVC_PPS_FLAG_LISTS_MODIFICATION_PRESENT, "LISTS_MODIFICATION_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_SLICE_SEGMENT_HEADER_EXTENSION_PRESENT, "SLICE_SEGMENT_HEADER_EXTENSION_PRESENT"},
- {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT, "DEBLOCKING_FILTER_CONTROL_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_SLICE_SEGMENT_HEADER_EXTENSION_PRESENT,
+ "SLICE_SEGMENT_HEADER_EXTENSION_PRESENT"},
+ {V4L2_HEVC_PPS_FLAG_DEBLOCKING_FILTER_CONTROL_PRESENT,
+ "DEBLOCKING_FILTER_CONTROL_PRESENT"},
{V4L2_HEVC_PPS_FLAG_UNIFORM_SPACING, "UNIFORM_SPACING"}
))
@@ -832,8 +1324,60 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_slice_params, s)),
- TP_fast_assign(__entry->s = *s),
+ TP_STRUCT__entry(__field(__u32, bit_size)
+ __field(__u32, data_byte_offset)
+ __field(__u32, num_entry_point_offsets)
+ __field(__u8, nal_unit_type)
+ __field(__u8, nuh_temporal_id_plus1)
+ __field(__u8, slice_type)
+ __field(__u8, colour_plane_id)
+ __field(__s32, slice_pic_order_cnt)
+ __field(__u8, num_ref_idx_l0_active_minus1)
+ __field(__u8, num_ref_idx_l1_active_minus1)
+ __field(__u8, collocated_ref_idx)
+ __field(__u8, five_minus_max_num_merge_cand)
+ __field(__s8, slice_qp_delta)
+ __field(__s8, slice_cb_qp_offset)
+ __field(__s8, slice_cr_qp_offset)
+ __field(__s8, slice_act_y_qp_offset)
+ __field(__s8, slice_act_cb_qp_offset)
+ __field(__s8, slice_act_cr_qp_offset)
+ __field(__s8, slice_beta_offset_div2)
+ __field(__s8, slice_tc_offset_div2)
+ __field(__u8, pic_struct)
+ __field(__u32, slice_segment_addr)
+ __array(__u8, ref_idx_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__u8, ref_idx_l1, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __field(__u16, short_term_ref_pic_set_size)
+ __field(__u16, long_term_ref_pic_set_size)
+ __field(__u64, flags)),
+ TP_fast_assign(__entry->bit_size = s->bit_size;
+ __entry->data_byte_offset = s->data_byte_offset;
+ __entry->num_entry_point_offsets = s->num_entry_point_offsets;
+ __entry->nal_unit_type = s->nal_unit_type;
+ __entry->nuh_temporal_id_plus1 = s->nuh_temporal_id_plus1;
+ __entry->slice_type = s->slice_type;
+ __entry->colour_plane_id = s->colour_plane_id;
+ __entry->slice_pic_order_cnt = s->slice_pic_order_cnt;
+ __entry->num_ref_idx_l0_active_minus1 = s->num_ref_idx_l0_active_minus1;
+ __entry->num_ref_idx_l1_active_minus1 = s->num_ref_idx_l1_active_minus1;
+ __entry->collocated_ref_idx = s->collocated_ref_idx;
+ __entry->five_minus_max_num_merge_cand = s->five_minus_max_num_merge_cand;
+ __entry->slice_qp_delta = s->slice_qp_delta;
+ __entry->slice_cb_qp_offset = s->slice_cb_qp_offset;
+ __entry->slice_cr_qp_offset = s->slice_cr_qp_offset;
+ __entry->slice_act_y_qp_offset = s->slice_act_y_qp_offset;
+ __entry->slice_act_cb_qp_offset = s->slice_act_cb_qp_offset;
+ __entry->slice_act_cr_qp_offset = s->slice_act_cr_qp_offset;
+ __entry->slice_beta_offset_div2 = s->slice_beta_offset_div2;
+ __entry->slice_tc_offset_div2 = s->slice_tc_offset_div2;
+ __entry->pic_struct = s->pic_struct;
+ __entry->slice_segment_addr = s->slice_segment_addr;
+ memcpy(__entry->ref_idx_l0, s->ref_idx_l0, sizeof(__entry->ref_idx_l0));
+ memcpy(__entry->ref_idx_l1, s->ref_idx_l1, sizeof(__entry->ref_idx_l1));
+ __entry->short_term_ref_pic_set_size = s->short_term_ref_pic_set_size;
+ __entry->long_term_ref_pic_set_size = s->long_term_ref_pic_set_size;
+ __entry->flags = s->flags;),
TP_printk("\nbit_size %u\n"
"data_byte_offset %u\n"
"num_entry_point_offsets %u\n"
@@ -861,46 +1405,49 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
"short_term_ref_pic_set_size %u\n"
"long_term_ref_pic_set_size %u\n"
"flags %s",
- __entry->s.bit_size,
- __entry->s.data_byte_offset,
- __entry->s.num_entry_point_offsets,
- __entry->s.nal_unit_type,
- __entry->s.nuh_temporal_id_plus1,
- __entry->s.slice_type,
- __entry->s.colour_plane_id,
- __entry->s.slice_pic_order_cnt,
- __entry->s.num_ref_idx_l0_active_minus1,
- __entry->s.num_ref_idx_l1_active_minus1,
- __entry->s.collocated_ref_idx,
- __entry->s.five_minus_max_num_merge_cand,
- __entry->s.slice_qp_delta,
- __entry->s.slice_cb_qp_offset,
- __entry->s.slice_cr_qp_offset,
- __entry->s.slice_act_y_qp_offset,
- __entry->s.slice_act_cb_qp_offset,
- __entry->s.slice_act_cr_qp_offset,
- __entry->s.slice_beta_offset_div2,
- __entry->s.slice_tc_offset_div2,
- __entry->s.pic_struct,
- __entry->s.slice_segment_addr,
- __print_array(__entry->s.ref_idx_l0,
- ARRAY_SIZE(__entry->s.ref_idx_l0),
- sizeof(__entry->s.ref_idx_l0[0])),
- __print_array(__entry->s.ref_idx_l1,
- ARRAY_SIZE(__entry->s.ref_idx_l1),
- sizeof(__entry->s.ref_idx_l1[0])),
- __entry->s.short_term_ref_pic_set_size,
- __entry->s.long_term_ref_pic_set_size,
- __print_flags(__entry->s.flags, "|",
+ __entry->bit_size,
+ __entry->data_byte_offset,
+ __entry->num_entry_point_offsets,
+ __entry->nal_unit_type,
+ __entry->nuh_temporal_id_plus1,
+ __entry->slice_type,
+ __entry->colour_plane_id,
+ __entry->slice_pic_order_cnt,
+ __entry->num_ref_idx_l0_active_minus1,
+ __entry->num_ref_idx_l1_active_minus1,
+ __entry->collocated_ref_idx,
+ __entry->five_minus_max_num_merge_cand,
+ __entry->slice_qp_delta,
+ __entry->slice_cb_qp_offset,
+ __entry->slice_cr_qp_offset,
+ __entry->slice_act_y_qp_offset,
+ __entry->slice_act_cb_qp_offset,
+ __entry->slice_act_cr_qp_offset,
+ __entry->slice_beta_offset_div2,
+ __entry->slice_tc_offset_div2,
+ __entry->pic_struct,
+ __entry->slice_segment_addr,
+ __print_array(__entry->ref_idx_l0,
+ ARRAY_SIZE(__entry->ref_idx_l0),
+ sizeof(__entry->ref_idx_l0[0])),
+ __print_array(__entry->ref_idx_l1,
+ ARRAY_SIZE(__entry->ref_idx_l1),
+ sizeof(__entry->ref_idx_l1[0])),
+ __entry->short_term_ref_pic_set_size,
+ __entry->long_term_ref_pic_set_size,
+ __print_flags(__entry->flags, "|",
{V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_LUMA, "SLICE_SAO_LUMA"},
{V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_SAO_CHROMA, "SLICE_SAO_CHROMA"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_TEMPORAL_MVP_ENABLED, "SLICE_TEMPORAL_MVP_ENABLED"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_TEMPORAL_MVP_ENABLED,
+ "SLICE_TEMPORAL_MVP_ENABLED"},
{V4L2_HEVC_SLICE_PARAMS_FLAG_MVD_L1_ZERO, "MVD_L1_ZERO"},
{V4L2_HEVC_SLICE_PARAMS_FLAG_CABAC_INIT, "CABAC_INIT"},
{V4L2_HEVC_SLICE_PARAMS_FLAG_COLLOCATED_FROM_L0, "COLLOCATED_FROM_L0"},
{V4L2_HEVC_SLICE_PARAMS_FLAG_USE_INTEGER_MV, "USE_INTEGER_MV"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_DEBLOCKING_FILTER_DISABLED, "SLICE_DEBLOCKING_FILTER_DISABLED"},
- {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED, "SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_DEBLOCKING_FILTER_DISABLED,
+ "SLICE_DEBLOCKING_FILTER_DISABLED"},
+ {V4L2_HEVC_SLICE_PARAMS_FLAG_SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED,
+ "SLICE_LOOP_FILTER_ACROSS_SLICES_ENABLED"},
{V4L2_HEVC_SLICE_PARAMS_FLAG_DEPENDENT_SLICE_SEGMENT, "DEPENDENT_SLICE_SEGMENT"}
))
@@ -909,8 +1456,35 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_hevc_pred_weight_table, p)),
- TP_fast_assign(__entry->p = *p),
+ TP_STRUCT__entry(__array(__s8, delta_luma_weight_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__s8, luma_offset_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__s8, delta_chroma_weight_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
+ __array(__s8, chroma_offset_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
+ __array(__s8, delta_luma_weight_l1, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__s8, luma_offset_l1, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__s8, delta_chroma_weight_l1, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
+ __array(__s8, chroma_offset_l1, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
+ __field(__u8, luma_log2_weight_denom)
+ __field(__s8, delta_chroma_log2_weight_denom)),
+ TP_fast_assign(memcpy(__entry->delta_luma_weight_l0, p->delta_luma_weight_l0,
+ sizeof(__entry->delta_luma_weight_l0));
+ memcpy(__entry->luma_offset_l0, p->luma_offset_l0,
+ sizeof(__entry->luma_offset_l0));
+ memcpy(__entry->delta_chroma_weight_l0, p->delta_chroma_weight_l0,
+ sizeof(__entry->delta_chroma_weight_l0));
+ memcpy(__entry->chroma_offset_l0, p->chroma_offset_l0,
+ sizeof(__entry->chroma_offset_l0));
+ memcpy(__entry->delta_luma_weight_l1, p->delta_luma_weight_l1,
+ sizeof(__entry->delta_luma_weight_l1));
+ memcpy(__entry->luma_offset_l1, p->luma_offset_l1,
+ sizeof(__entry->luma_offset_l1));
+ memcpy(__entry->delta_chroma_weight_l1, p->delta_chroma_weight_l1,
+ sizeof(__entry->delta_chroma_weight_l1));
+ memcpy(__entry->chroma_offset_l1, p->chroma_offset_l1,
+ sizeof(__entry->chroma_offset_l1));
+ __entry->luma_log2_weight_denom = p->luma_log2_weight_denom;
+ __entry->delta_chroma_log2_weight_denom =
+ p->delta_chroma_log2_weight_denom;),
TP_printk("\ndelta_luma_weight_l0 %s\n"
"luma_offset_l0 %s\n"
"delta_chroma_weight_l0 {%s}\n"
@@ -921,44 +1495,62 @@ DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
"chroma_offset_l1 {%s}\n"
"luma_log2_weight_denom %d\n"
"delta_chroma_log2_weight_denom %d\n",
- __print_array(__entry->p.delta_luma_weight_l0,
- ARRAY_SIZE(__entry->p.delta_luma_weight_l0),
- sizeof(__entry->p.delta_luma_weight_l0[0])),
- __print_array(__entry->p.luma_offset_l0,
- ARRAY_SIZE(__entry->p.luma_offset_l0),
- sizeof(__entry->p.luma_offset_l0[0])),
+ __print_array(__entry->delta_luma_weight_l0,
+ ARRAY_SIZE(__entry->delta_luma_weight_l0),
+ sizeof(__entry->delta_luma_weight_l0[0])),
+ __print_array(__entry->luma_offset_l0,
+ ARRAY_SIZE(__entry->luma_offset_l0),
+ sizeof(__entry->luma_offset_l0[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.delta_chroma_weight_l0,
- sizeof(__entry->p.delta_chroma_weight_l0),
+ __entry->delta_chroma_weight_l0,
+ sizeof(__entry->delta_chroma_weight_l0),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.chroma_offset_l0,
- sizeof(__entry->p.chroma_offset_l0),
+ __entry->chroma_offset_l0,
+ sizeof(__entry->chroma_offset_l0),
false),
- __print_array(__entry->p.delta_luma_weight_l1,
- ARRAY_SIZE(__entry->p.delta_luma_weight_l1),
- sizeof(__entry->p.delta_luma_weight_l1[0])),
- __print_array(__entry->p.luma_offset_l1,
- ARRAY_SIZE(__entry->p.luma_offset_l1),
- sizeof(__entry->p.luma_offset_l1[0])),
+ __print_array(__entry->delta_luma_weight_l1,
+ ARRAY_SIZE(__entry->delta_luma_weight_l1),
+ sizeof(__entry->delta_luma_weight_l1[0])),
+ __print_array(__entry->luma_offset_l1,
+ ARRAY_SIZE(__entry->luma_offset_l1),
+ sizeof(__entry->luma_offset_l1[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.delta_chroma_weight_l1,
- sizeof(__entry->p.delta_chroma_weight_l1),
+ __entry->delta_chroma_weight_l1,
+ sizeof(__entry->delta_chroma_weight_l1),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.chroma_offset_l1,
- sizeof(__entry->p.chroma_offset_l1),
+ __entry->chroma_offset_l1,
+ sizeof(__entry->chroma_offset_l1),
false),
- __entry->p.luma_log2_weight_denom,
- __entry->p.delta_chroma_log2_weight_denom
+ __entry->luma_log2_weight_denom,
+ __entry->delta_chroma_log2_weight_denom
))
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_scaling_matrix, s)),
- TP_fast_assign(__entry->s = *s),
+ TP_STRUCT__entry(__array(__u8, scaling_list_4x4, 6 * 16)
+ __array(__u8, scaling_list_8x8, 6 * 64)
+ __array(__u8, scaling_list_16x16, 6 * 64)
+ __array(__u8, scaling_list_32x32, 2 * 64)
+ __array(__u8, scaling_list_dc_coef_16x16, 6)
+ __array(__u8, scaling_list_dc_coef_32x32, 2)),
+ TP_fast_assign(memcpy(__entry->scaling_list_4x4,
+ s->scaling_list_4x4, sizeof(__entry->scaling_list_4x4));
+ memcpy(__entry->scaling_list_8x8,
+ s->scaling_list_8x8, sizeof(__entry->scaling_list_8x8));
+ memcpy(__entry->scaling_list_16x16,
+ s->scaling_list_16x16, sizeof(__entry->scaling_list_16x16));
+ memcpy(__entry->scaling_list_32x32,
+ s->scaling_list_32x32, sizeof(__entry->scaling_list_32x32));
+ memcpy(__entry->scaling_list_dc_coef_16x16,
+ s->scaling_list_dc_coef_16x16,
+ sizeof(__entry->scaling_list_dc_coef_16x16));
+ memcpy(__entry->scaling_list_dc_coef_32x32,
+ s->scaling_list_dc_coef_32x32,
+ sizeof(__entry->scaling_list_dc_coef_32x32));),
TP_printk("\nscaling_list_4x4 {%s}\n"
"scaling_list_8x8 {%s}\n"
"scaling_list_16x16 {%s}\n"
@@ -966,34 +1558,56 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
"scaling_list_dc_coef_16x16 %s\n"
"scaling_list_dc_coef_32x32 %s\n",
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_4x4,
- sizeof(__entry->s.scaling_list_4x4),
+ __entry->scaling_list_4x4,
+ sizeof(__entry->scaling_list_4x4),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_8x8,
- sizeof(__entry->s.scaling_list_8x8),
+ __entry->scaling_list_8x8,
+ sizeof(__entry->scaling_list_8x8),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_16x16,
- sizeof(__entry->s.scaling_list_16x16),
+ __entry->scaling_list_16x16,
+ sizeof(__entry->scaling_list_16x16),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->s.scaling_list_32x32,
- sizeof(__entry->s.scaling_list_32x32),
+ __entry->scaling_list_32x32,
+ sizeof(__entry->scaling_list_32x32),
false),
- __print_array(__entry->s.scaling_list_dc_coef_16x16,
- ARRAY_SIZE(__entry->s.scaling_list_dc_coef_16x16),
- sizeof(__entry->s.scaling_list_dc_coef_16x16[0])),
- __print_array(__entry->s.scaling_list_dc_coef_32x32,
- ARRAY_SIZE(__entry->s.scaling_list_dc_coef_32x32),
- sizeof(__entry->s.scaling_list_dc_coef_32x32[0]))
+ __print_array(__entry->scaling_list_dc_coef_16x16,
+ ARRAY_SIZE(__entry->scaling_list_dc_coef_16x16),
+ sizeof(__entry->scaling_list_dc_coef_16x16[0])),
+ __print_array(__entry->scaling_list_dc_coef_32x32,
+ ARRAY_SIZE(__entry->scaling_list_dc_coef_32x32),
+ sizeof(__entry->scaling_list_dc_coef_32x32[0]))
))
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
TP_ARGS(d),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_decode_params, d)),
- TP_fast_assign(__entry->d = *d),
+ TP_STRUCT__entry(__field(__s32, pic_order_cnt_val)
+ __field(__u16, short_term_ref_pic_set_size)
+ __field(__u16, long_term_ref_pic_set_size)
+ __field(__u8, num_active_dpb_entries)
+ __field(__u8, num_poc_st_curr_before)
+ __field(__u8, num_poc_st_curr_after)
+ __field(__u8, num_poc_lt_curr)
+ __array(__u8, poc_st_curr_before, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__u8, poc_st_curr_after, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __array(__u8, poc_lt_curr, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ __field(__u64, flags)),
+ TP_fast_assign(__entry->pic_order_cnt_val = d->pic_order_cnt_val;
+ __entry->short_term_ref_pic_set_size = d->short_term_ref_pic_set_size;
+ __entry->long_term_ref_pic_set_size = d->long_term_ref_pic_set_size;
+ __entry->num_active_dpb_entries = d->num_active_dpb_entries;
+ __entry->num_poc_st_curr_before = d->num_poc_st_curr_before;
+ __entry->num_poc_st_curr_after = d->num_poc_st_curr_after;
+ __entry->num_poc_lt_curr = d->num_poc_lt_curr;
+ memcpy(__entry->poc_st_curr_before, d->poc_st_curr_before,
+ sizeof(__entry->poc_st_curr_before));
+ memcpy(__entry->poc_st_curr_after, d->poc_st_curr_after,
+ sizeof(__entry->poc_st_curr_after));
+ memcpy(__entry->poc_lt_curr, d->poc_lt_curr, sizeof(__entry->poc_lt_curr));
+ __entry->flags = d->flags;),
TP_printk("\npic_order_cnt_val %d\n"
"short_term_ref_pic_set_size %u\n"
"long_term_ref_pic_set_size %u\n"
@@ -1005,23 +1619,23 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
"poc_st_curr_after %s\n"
"poc_lt_curr %s\n"
"flags %s",
- __entry->d.pic_order_cnt_val,
- __entry->d.short_term_ref_pic_set_size,
- __entry->d.long_term_ref_pic_set_size,
- __entry->d.num_active_dpb_entries,
- __entry->d.num_poc_st_curr_before,
- __entry->d.num_poc_st_curr_after,
- __entry->d.num_poc_lt_curr,
- __print_array(__entry->d.poc_st_curr_before,
- ARRAY_SIZE(__entry->d.poc_st_curr_before),
- sizeof(__entry->d.poc_st_curr_before[0])),
- __print_array(__entry->d.poc_st_curr_after,
- ARRAY_SIZE(__entry->d.poc_st_curr_after),
- sizeof(__entry->d.poc_st_curr_after[0])),
- __print_array(__entry->d.poc_lt_curr,
- ARRAY_SIZE(__entry->d.poc_lt_curr),
- sizeof(__entry->d.poc_lt_curr[0])),
- __print_flags(__entry->d.flags, "|",
+ __entry->pic_order_cnt_val,
+ __entry->short_term_ref_pic_set_size,
+ __entry->long_term_ref_pic_set_size,
+ __entry->num_active_dpb_entries,
+ __entry->num_poc_st_curr_before,
+ __entry->num_poc_st_curr_after,
+ __entry->num_poc_lt_curr,
+ __print_array(__entry->poc_st_curr_before,
+ ARRAY_SIZE(__entry->poc_st_curr_before),
+ sizeof(__entry->poc_st_curr_before[0])),
+ __print_array(__entry->poc_st_curr_after,
+ ARRAY_SIZE(__entry->poc_st_curr_after),
+ sizeof(__entry->poc_st_curr_after[0])),
+ __print_array(__entry->poc_lt_curr,
+ ARRAY_SIZE(__entry->poc_lt_curr),
+ sizeof(__entry->poc_lt_curr[0])),
+ __print_flags(__entry->flags, "|",
{V4L2_HEVC_DECODE_PARAM_FLAG_IRAP_PIC, "IRAP_PIC"},
{V4L2_HEVC_DECODE_PARAM_FLAG_IDR_PIC, "IDR_PIC"},
{V4L2_HEVC_DECODE_PARAM_FLAG_NO_OUTPUT_OF_PRIOR, "NO_OUTPUT_OF_PRIOR"}
@@ -1031,22 +1645,44 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
TP_ARGS(lt),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_ext_sps_lt_rps, lt)),
- TP_fast_assign(__entry->lt = *lt),
+ TP_STRUCT__entry(__field(__u8, flags)
+ __field(__u32, lt_ref_pic_poc_lsb_sps)),
+ TP_fast_assign(__entry->flags = lt->flags;
+ __entry->lt_ref_pic_poc_lsb_sps = lt->lt_ref_pic_poc_lsb_sps;),
TP_printk("\nflags %s\n"
"lt_ref_pic_poc_lsb_sps %x\n",
- __print_flags(__entry->lt.flags, "|",
+ __print_flags(__entry->flags, "|",
{V4L2_HEVC_EXT_SPS_LT_RPS_FLAG_USED_LT, "USED_LT"}
),
- __entry->lt.lt_ref_pic_poc_lsb_sps
+ __entry->lt_ref_pic_poc_lsb_sps
)
);
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
TP_ARGS(st),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_hevc_ext_sps_st_rps, st)),
- TP_fast_assign(__entry->st = *st),
+ TP_STRUCT__entry(__field(__u8, flags)
+ __field(__u8, delta_idx_minus1)
+ __field(__u8, delta_rps_sign)
+ __field(__u16, abs_delta_rps_minus1)
+ __field(__u8, num_negative_pics)
+ __field(__u8, num_positive_pics)
+ __field(__u32, used_by_curr_pic)
+ __field(__u32, use_delta_flag)
+ __array(__u32, delta_poc_s0_minus1, 16)
+ __array(__u32, delta_poc_s1_minus1, 16)),
+ TP_fast_assign(__entry->flags = st->flags;
+ __entry->delta_idx_minus1 = st->delta_idx_minus1;
+ __entry->delta_rps_sign = st->delta_rps_sign;
+ __entry->abs_delta_rps_minus1 = st->abs_delta_rps_minus1;
+ __entry->num_negative_pics = st->num_negative_pics;
+ __entry->num_positive_pics = st->num_positive_pics;
+ __entry->used_by_curr_pic = st->used_by_curr_pic;
+ __entry->use_delta_flag = st->use_delta_flag;
+ memcpy(__entry->delta_poc_s0_minus1, st->delta_poc_s0_minus1,
+ sizeof(__entry->delta_poc_s0_minus1));
+ memcpy(__entry->delta_poc_s1_minus1, st->delta_poc_s1_minus1,
+ sizeof(__entry->delta_poc_s1_minus1));),
TP_printk("\nflags %s\n"
"delta_idx_minus1: %u\n"
"delta_rps_sign: %u\n"
@@ -1057,40 +1693,46 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
"use_delta_flag: %08x\n"
"delta_poc_s0_minus1: %s\n"
"delta_poc_s1_minus1: %s\n",
- __print_flags(__entry->st.flags, "|",
+ __print_flags(__entry->flags, "|",
{V4L2_HEVC_EXT_SPS_ST_RPS_FLAG_INTER_REF_PIC_SET_PRED, "INTER_REF_PIC_SET_PRED"}
),
- __entry->st.delta_idx_minus1,
- __entry->st.delta_rps_sign,
- __entry->st.abs_delta_rps_minus1,
- __entry->st.num_negative_pics,
- __entry->st.num_positive_pics,
- __entry->st.used_by_curr_pic,
- __entry->st.use_delta_flag,
- __print_array(__entry->st.delta_poc_s0_minus1,
- ARRAY_SIZE(__entry->st.delta_poc_s0_minus1),
- sizeof(__entry->st.delta_poc_s0_minus1[0])),
- __print_array(__entry->st.delta_poc_s1_minus1,
- ARRAY_SIZE(__entry->st.delta_poc_s1_minus1),
- sizeof(__entry->st.delta_poc_s1_minus1[0]))
+ __entry->delta_idx_minus1,
+ __entry->delta_rps_sign,
+ __entry->abs_delta_rps_minus1,
+ __entry->num_negative_pics,
+ __entry->num_positive_pics,
+ __entry->used_by_curr_pic,
+ __entry->use_delta_flag,
+ __print_array(__entry->delta_poc_s0_minus1,
+ ARRAY_SIZE(__entry->delta_poc_s0_minus1),
+ sizeof(__entry->delta_poc_s0_minus1[0])),
+ __print_array(__entry->delta_poc_s1_minus1,
+ ARRAY_SIZE(__entry->delta_poc_s1_minus1),
+ sizeof(__entry->delta_poc_s1_minus1[0]))
)
);
DECLARE_EVENT_CLASS(v4l2_hevc_dpb_entry_tmpl,
TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
TP_ARGS(e),
- TP_STRUCT__entry(__field_struct(struct v4l2_hevc_dpb_entry, e)),
- TP_fast_assign(__entry->e = *e),
+ TP_STRUCT__entry(__field(__u64, timestamp)
+ __field(__u8, flags)
+ __field(__u8, field_pic)
+ __field(__s32, pic_order_cnt_val)),
+ TP_fast_assign(__entry->timestamp = e->timestamp;
+ __entry->flags = e->flags;
+ __entry->field_pic = e->field_pic;
+ __entry->pic_order_cnt_val = e->pic_order_cnt_val;),
TP_printk("\ntimestamp %llu\n"
"flags %s\n"
"field_pic %u\n"
"pic_order_cnt_val %d\n",
- __entry->e.timestamp,
- __print_flags(__entry->e.flags, "|",
+ __entry->timestamp,
+ __print_flags(__entry->flags, "|",
{V4L2_HEVC_DPB_ENTRY_LONG_TERM_REFERENCE, "LONG_TERM_REFERENCE"}
),
- __entry->e.field_pic,
- __entry->e.pic_order_cnt_val
+ __entry->field_pic,
+ __entry->pic_order_cnt_val
))
DEFINE_EVENT(v4l2_ctrl_hevc_sps_tmpl, v4l2_ctrl_hevc_sps,
@@ -1143,16 +1785,26 @@ DEFINE_EVENT(v4l2_hevc_dpb_entry_tmpl, v4l2_hevc_dpb_entry,
DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_seq_tmpl,
TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
TP_ARGS(s),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_sequence, s)),
- TP_fast_assign(__entry->s = *s;),
+ TP_STRUCT__entry(__field(__u16, horizontal_size)
+ __field(__u16, vertical_size)
+ __field(__u32, vbv_buffer_size)
+ __field(__u16, profile_and_level_indication)
+ __field(__u8, chroma_format)
+ __field(__u8, flags)),
+ TP_fast_assign(__entry->horizontal_size = s->horizontal_size;
+ __entry->vertical_size = s->vertical_size;
+ __entry->vbv_buffer_size = s->vbv_buffer_size;
+ __entry->profile_and_level_indication = s->profile_and_level_indication;
+ __entry->chroma_format = s->chroma_format;
+ __entry->flags = s->flags;),
TP_printk("\nhorizontal_size %u\nvertical_size %u\nvbv_buffer_size %u\n"
"profile_and_level_indication %u\nchroma_format %u\nflags %s\n",
- __entry->s.horizontal_size,
- __entry->s.vertical_size,
- __entry->s.vbv_buffer_size,
- __entry->s.profile_and_level_indication,
- __entry->s.chroma_format,
- __print_flags(__entry->s.flags, "|",
+ __entry->horizontal_size,
+ __entry->vertical_size,
+ __entry->vbv_buffer_size,
+ __entry->profile_and_level_indication,
+ __entry->chroma_format,
+ __print_flags(__entry->flags, "|",
{V4L2_MPEG2_SEQ_FLAG_PROGRESSIVE, "PROGRESSIVE"})
)
);
@@ -1160,13 +1812,25 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_seq_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_pic_tmpl,
TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_picture, p)),
- TP_fast_assign(__entry->p = *p;),
+ TP_STRUCT__entry(__field(__u64, backward_ref_ts)
+ __field(__u64, forward_ref_ts)
+ __field(__u32, flags)
+ __array(__u8, f_code, 4)
+ __field(__u8, picture_coding_type)
+ __field(__u8, picture_structure)
+ __field(__u8, intra_dc_precision)),
+ TP_fast_assign(__entry->backward_ref_ts = p->backward_ref_ts;
+ __entry->forward_ref_ts = p->forward_ref_ts;
+ __entry->flags = p->flags;
+ memcpy(__entry->f_code, p->f_code, sizeof(__entry->f_code));
+ __entry->picture_coding_type = p->picture_coding_type;
+ __entry->picture_structure = p->picture_structure;
+ __entry->intra_dc_precision = p->intra_dc_precision;),
TP_printk("\nbackward_ref_ts %llu\nforward_ref_ts %llu\nflags %s\nf_code {%s}\n"
"picture_coding_type: %u\npicture_structure %u\nintra_dc_precision %u\n",
- __entry->p.backward_ref_ts,
- __entry->p.forward_ref_ts,
- __print_flags(__entry->p.flags, "|",
+ __entry->backward_ref_ts,
+ __entry->forward_ref_ts,
+ __print_flags(__entry->flags, "|",
{V4L2_MPEG2_PIC_FLAG_TOP_FIELD_FIRST, "TOP_FIELD_FIRST"},
{V4L2_MPEG2_PIC_FLAG_FRAME_PRED_DCT, "FRAME_PRED_DCT"},
{V4L2_MPEG2_PIC_FLAG_CONCEALMENT_MV, "CONCEALMENT_MV"},
@@ -1176,34 +1840,46 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_pic_tmpl,
{V4L2_MPEG2_PIC_FLAG_REPEAT_FIRST, "REPEAT_FIRST"},
{V4L2_MPEG2_PIC_FLAG_PROGRESSIVE, "PROGRESSIVE"}),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.f_code,
- sizeof(__entry->p.f_code),
+ __entry->f_code,
+ sizeof(__entry->f_code),
false),
- __entry->p.picture_coding_type,
- __entry->p.picture_structure,
- __entry->p.intra_dc_precision
+ __entry->picture_coding_type,
+ __entry->picture_structure,
+ __entry->intra_dc_precision
)
);
DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_quant_tmpl,
TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
TP_ARGS(q),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_mpeg2_quantisation, q)),
- TP_fast_assign(__entry->q = *q;),
+ TP_STRUCT__entry(__array(__u8, intra_quantiser_matrix, 64)
+ __array(__u8, non_intra_quantiser_matrix, 64)
+ __array(__u8, chroma_intra_quantiser_matrix, 64)
+ __array(__u8, chroma_non_intra_quantiser_matrix, 64)),
+ TP_fast_assign(memcpy(__entry->intra_quantiser_matrix, q->intra_quantiser_matrix,
+ sizeof(__entry->intra_quantiser_matrix));
+ memcpy(__entry->non_intra_quantiser_matrix, q->non_intra_quantiser_matrix,
+ sizeof(__entry->non_intra_quantiser_matrix));
+ memcpy(__entry->chroma_intra_quantiser_matrix,
+ q->chroma_intra_quantiser_matrix,
+ sizeof(__entry->chroma_intra_quantiser_matrix));
+ memcpy(__entry->chroma_non_intra_quantiser_matrix,
+ q->chroma_non_intra_quantiser_matrix,
+ sizeof(__entry->chroma_non_intra_quantiser_matrix));),
TP_printk("\nintra_quantiser_matrix %s\nnon_intra_quantiser_matrix %s\n"
"chroma_intra_quantiser_matrix %s\nchroma_non_intra_quantiser_matrix %s\n",
- __print_array(__entry->q.intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.intra_quantiser_matrix),
- sizeof(__entry->q.intra_quantiser_matrix[0])),
- __print_array(__entry->q.non_intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.non_intra_quantiser_matrix),
- sizeof(__entry->q.non_intra_quantiser_matrix[0])),
- __print_array(__entry->q.chroma_intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.chroma_intra_quantiser_matrix),
- sizeof(__entry->q.chroma_intra_quantiser_matrix[0])),
- __print_array(__entry->q.chroma_non_intra_quantiser_matrix,
- ARRAY_SIZE(__entry->q.chroma_non_intra_quantiser_matrix),
- sizeof(__entry->q.chroma_non_intra_quantiser_matrix[0]))
+ __print_array(__entry->intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->intra_quantiser_matrix),
+ sizeof(__entry->intra_quantiser_matrix[0])),
+ __print_array(__entry->non_intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->non_intra_quantiser_matrix),
+ sizeof(__entry->non_intra_quantiser_matrix[0])),
+ __print_array(__entry->chroma_intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->chroma_intra_quantiser_matrix),
+ sizeof(__entry->chroma_intra_quantiser_matrix[0])),
+ __print_array(__entry->chroma_non_intra_quantiser_matrix,
+ ARRAY_SIZE(__entry->chroma_non_intra_quantiser_matrix),
+ sizeof(__entry->chroma_non_intra_quantiser_matrix[0]))
)
)
@@ -1227,25 +1903,35 @@ DEFINE_EVENT(v4l2_ctrl_mpeg2_quant_tmpl, v4l2_ctrl_mpeg2_quantisation,
DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp8_frame, f)),
- TP_fast_assign(__entry->f = *f;),
+ TP_STRUCT__entry(__array(__u8, entropy_coeff_probs, 4 * 8 * 3 * V4L2_VP8_COEFF_PROB_CNT)
+ __array(__u8, entropy_y_mode_probs, 4)
+ __array(__u8, entropy_uv_mode_probs, 3)
+ __array(__u8, entropy_mv_probs, 2 * 19)),
+ TP_fast_assign(memcpy(__entry->entropy_coeff_probs, f->entropy.coeff_probs,
+ sizeof(__entry->entropy_coeff_probs));
+ memcpy(__entry->entropy_y_mode_probs, f->entropy.y_mode_probs,
+ sizeof(__entry->entropy_y_mode_probs));
+ memcpy(__entry->entropy_uv_mode_probs, f->entropy.uv_mode_probs,
+ sizeof(__entry->entropy_uv_mode_probs));
+ memcpy(__entry->entropy_mv_probs, f->entropy.mv_probs,
+ sizeof(__entry->entropy_mv_probs));),
TP_printk("\nentropy.coeff_probs {%s}\n"
"entropy.y_mode_probs %s\n"
"entropy.uv_mode_probs %s\n"
"entropy.mv_probs {%s}",
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->f.entropy.coeff_probs,
- sizeof(__entry->f.entropy.coeff_probs),
+ __entry->entropy_coeff_probs,
+ sizeof(__entry->entropy_coeff_probs),
false),
- __print_array(__entry->f.entropy.y_mode_probs,
- ARRAY_SIZE(__entry->f.entropy.y_mode_probs),
- sizeof(__entry->f.entropy.y_mode_probs[0])),
- __print_array(__entry->f.entropy.uv_mode_probs,
- ARRAY_SIZE(__entry->f.entropy.uv_mode_probs),
- sizeof(__entry->f.entropy.uv_mode_probs[0])),
+ __print_array(__entry->entropy_y_mode_probs,
+ ARRAY_SIZE(__entry->entropy_y_mode_probs),
+ sizeof(__entry->entropy_y_mode_probs[0])),
+ __print_array(__entry->entropy_uv_mode_probs,
+ ARRAY_SIZE(__entry->entropy_uv_mode_probs),
+ sizeof(__entry->entropy_uv_mode_probs[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->f.entropy.mv_probs,
- sizeof(__entry->f.entropy.mv_probs),
+ __entry->entropy_mv_probs,
+ sizeof(__entry->entropy_mv_probs),
false)
)
)
@@ -1253,8 +1939,82 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp8_frame, f)),
- TP_fast_assign(__entry->f = *f;),
+ TP_STRUCT__entry(__array(__s8, segment_quant_update, 4)
+ __array(__s8, segment_lf_update, 4)
+ __array(__u8, segment_segment_probs, 3)
+ __field(__u32, segment_flags)
+ __array(__s8, lf_ref_frm_delta, 4)
+ __array(__s8, lf_mb_mode_delta, 4)
+ __field(__u8, lf_sharpness_level)
+ __field(__u8, lf_level)
+ __field(__u32, lf_flags)
+ __field(__u8, quant_y_ac_qi)
+ __field(__s8, quant_y_dc_delta)
+ __field(__s8, quant_y2_dc_delta)
+ __field(__s8, quant_y2_ac_delta)
+ __field(__s8, quant_uv_dc_delta)
+ __field(__s8, quant_uv_ac_delta)
+ __field(__u8, coder_state_range)
+ __field(__u8, coder_state_value)
+ __field(__u8, coder_state_bit_count)
+ __field(__u16, width)
+ __field(__u16, height)
+ __field(__u8, horizontal_scale)
+ __field(__u8, vertical_scale)
+ __field(__u8, version)
+ __field(__u8, prob_skip_false)
+ __field(__u8, prob_intra)
+ __field(__u8, prob_last)
+ __field(__u8, prob_gf)
+ __field(__u8, num_dct_parts)
+ __field(__u32, first_part_size)
+ __field(__u32, first_part_header_bits)
+ __array(__u32, dct_part_sizes, 8)
+ __field(__u64, last_frame_ts)
+ __field(__u64, golden_frame_ts)
+ __field(__u64, alt_frame_ts)
+ __field(__u64, flags)),
+ TP_fast_assign(memcpy(__entry->segment_quant_update, f->segment.quant_update,
+ sizeof(__entry->segment_quant_update));
+ memcpy(__entry->segment_lf_update, f->segment.lf_update,
+ sizeof(__entry->segment_lf_update));
+ memcpy(__entry->segment_segment_probs, f->segment.segment_probs,
+ sizeof(__entry->segment_segment_probs));
+ __entry->segment_flags = f->segment.flags;
+ memcpy(__entry->lf_ref_frm_delta, f->lf.ref_frm_delta,
+ sizeof(__entry->lf_ref_frm_delta));
+ memcpy(__entry->lf_mb_mode_delta, f->lf.mb_mode_delta,
+ sizeof(__entry->lf_mb_mode_delta));
+ __entry->lf_sharpness_level = f->lf.sharpness_level;
+ __entry->lf_level = f->lf.level;
+ __entry->lf_flags = f->lf.flags;
+ __entry->quant_y_ac_qi = f->quant.y_ac_qi;
+ __entry->quant_y_dc_delta = f->quant.y_dc_delta;
+ __entry->quant_y2_dc_delta = f->quant.y2_dc_delta;
+ __entry->quant_y2_ac_delta = f->quant.y2_ac_delta;
+ __entry->quant_uv_dc_delta = f->quant.uv_dc_delta;
+ __entry->quant_uv_ac_delta = f->quant.uv_ac_delta;
+ __entry->coder_state_range = f->coder_state.range;
+ __entry->coder_state_value = f->coder_state.value;
+ __entry->coder_state_bit_count = f->coder_state.bit_count;
+ __entry->width = f->width;
+ __entry->height = f->height;
+ __entry->horizontal_scale = f->horizontal_scale;
+ __entry->vertical_scale = f->vertical_scale;
+ __entry->version = f->version;
+ __entry->prob_skip_false = f->prob_skip_false;
+ __entry->prob_intra = f->prob_intra;
+ __entry->prob_last = f->prob_last;
+ __entry->prob_gf = f->prob_gf;
+ __entry->num_dct_parts = f->num_dct_parts;
+ __entry->first_part_size = f->first_part_size;
+ __entry->first_part_header_bits = f->first_part_header_bits;
+ memcpy(__entry->dct_part_sizes, f->dct_part_sizes,
+ sizeof(__entry->dct_part_sizes));
+ __entry->last_frame_ts = f->last_frame_ts;
+ __entry->golden_frame_ts = f->golden_frame_ts;
+ __entry->alt_frame_ts = f->alt_frame_ts;
+ __entry->flags = f->flags;),
TP_printk("\nsegment.quant_update %s\n"
"segment.lf_update %s\n"
"segment.segment_probs %s\n"
@@ -1290,60 +2050,60 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
"golden_frame_ts %llu\n"
"alt_frame_ts %llu\n"
"flags %s",
- __print_array(__entry->f.segment.quant_update,
- ARRAY_SIZE(__entry->f.segment.quant_update),
- sizeof(__entry->f.segment.quant_update[0])),
- __print_array(__entry->f.segment.lf_update,
- ARRAY_SIZE(__entry->f.segment.lf_update),
- sizeof(__entry->f.segment.lf_update[0])),
- __print_array(__entry->f.segment.segment_probs,
- ARRAY_SIZE(__entry->f.segment.segment_probs),
- sizeof(__entry->f.segment.segment_probs[0])),
- __print_flags(__entry->f.segment.flags, "|",
+ __print_array(__entry->segment_quant_update,
+ ARRAY_SIZE(__entry->segment_quant_update),
+ sizeof(__entry->segment_quant_update[0])),
+ __print_array(__entry->segment_lf_update,
+ ARRAY_SIZE(__entry->segment_lf_update),
+ sizeof(__entry->segment_lf_update[0])),
+ __print_array(__entry->segment_segment_probs,
+ ARRAY_SIZE(__entry->segment_segment_probs),
+ sizeof(__entry->segment_segment_probs[0])),
+ __print_flags(__entry->segment_flags, "|",
{V4L2_VP8_SEGMENT_FLAG_ENABLED, "SEGMENT_ENABLED"},
{V4L2_VP8_SEGMENT_FLAG_UPDATE_MAP, "SEGMENT_UPDATE_MAP"},
{V4L2_VP8_SEGMENT_FLAG_UPDATE_FEATURE_DATA, "SEGMENT_UPDATE_FEATURE_DATA"},
{V4L2_VP8_SEGMENT_FLAG_DELTA_VALUE_MODE, "SEGMENT_DELTA_VALUE_MODE"}),
- __print_array(__entry->f.lf.ref_frm_delta,
- ARRAY_SIZE(__entry->f.lf.ref_frm_delta),
- sizeof(__entry->f.lf.ref_frm_delta[0])),
- __print_array(__entry->f.lf.mb_mode_delta,
- ARRAY_SIZE(__entry->f.lf.mb_mode_delta),
- sizeof(__entry->f.lf.mb_mode_delta[0])),
- __entry->f.lf.sharpness_level,
- __entry->f.lf.level,
- __print_flags(__entry->f.lf.flags, "|",
+ __print_array(__entry->lf_ref_frm_delta,
+ ARRAY_SIZE(__entry->lf_ref_frm_delta),
+ sizeof(__entry->lf_ref_frm_delta[0])),
+ __print_array(__entry->lf_mb_mode_delta,
+ ARRAY_SIZE(__entry->lf_mb_mode_delta),
+ sizeof(__entry->lf_mb_mode_delta[0])),
+ __entry->lf_sharpness_level,
+ __entry->lf_level,
+ __print_flags(__entry->lf_flags, "|",
{V4L2_VP8_LF_ADJ_ENABLE, "LF_ADJ_ENABLED"},
{V4L2_VP8_LF_DELTA_UPDATE, "LF_DELTA_UPDATE"},
{V4L2_VP8_LF_FILTER_TYPE_SIMPLE, "LF_FILTER_TYPE_SIMPLE"}),
- __entry->f.quant.y_ac_qi,
- __entry->f.quant.y_dc_delta,
- __entry->f.quant.y2_dc_delta,
- __entry->f.quant.y2_ac_delta,
- __entry->f.quant.uv_dc_delta,
- __entry->f.quant.uv_ac_delta,
- __entry->f.coder_state.range,
- __entry->f.coder_state.value,
- __entry->f.coder_state.bit_count,
- __entry->f.width,
- __entry->f.height,
- __entry->f.horizontal_scale,
- __entry->f.vertical_scale,
- __entry->f.version,
- __entry->f.prob_skip_false,
- __entry->f.prob_intra,
- __entry->f.prob_last,
- __entry->f.prob_gf,
- __entry->f.num_dct_parts,
- __entry->f.first_part_size,
- __entry->f.first_part_header_bits,
- __print_array(__entry->f.dct_part_sizes,
- ARRAY_SIZE(__entry->f.dct_part_sizes),
- sizeof(__entry->f.dct_part_sizes[0])),
- __entry->f.last_frame_ts,
- __entry->f.golden_frame_ts,
- __entry->f.alt_frame_ts,
- __print_flags(__entry->f.flags, "|",
+ __entry->quant_y_ac_qi,
+ __entry->quant_y_dc_delta,
+ __entry->quant_y2_dc_delta,
+ __entry->quant_y2_ac_delta,
+ __entry->quant_uv_dc_delta,
+ __entry->quant_uv_ac_delta,
+ __entry->coder_state_range,
+ __entry->coder_state_value,
+ __entry->coder_state_bit_count,
+ __entry->width,
+ __entry->height,
+ __entry->horizontal_scale,
+ __entry->vertical_scale,
+ __entry->version,
+ __entry->prob_skip_false,
+ __entry->prob_intra,
+ __entry->prob_last,
+ __entry->prob_gf,
+ __entry->num_dct_parts,
+ __entry->first_part_size,
+ __entry->first_part_header_bits,
+ __print_array(__entry->dct_part_sizes,
+ ARRAY_SIZE(__entry->dct_part_sizes),
+ sizeof(__entry->dct_part_sizes[0])),
+ __entry->last_frame_ts,
+ __entry->golden_frame_ts,
+ __entry->alt_frame_ts,
+ __print_flags(__entry->flags, "|",
{V4L2_VP8_FRAME_FLAG_KEY_FRAME, "KEY_FRAME"},
{V4L2_VP8_FRAME_FLAG_EXPERIMENTAL, "EXPERIMENTAL"},
{V4L2_VP8_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
@@ -1368,8 +2128,78 @@ DEFINE_EVENT(v4l2_ctrl_vp8_entropy_tmpl, v4l2_ctrl_vp8_entropy,
DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
TP_ARGS(f),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_frame, f)),
- TP_fast_assign(__entry->f = *f;),
+ TP_STRUCT__entry(__array(__s8, lf_ref_deltas, 4)
+ __array(__s8, lf_mode_deltas, 2)
+ __field(__u8, lf_level)
+ __field(__u8, lf_sharpness)
+ __field(__u8, lf_flags)
+ __field(__u8, quant_base_q_idx)
+ __field(__s8, quant_delta_q_y_dc)
+ __field(__s8, quant_delta_q_uv_dc)
+ __field(__s8, quant_delta_q_uv_ac)
+ __array(__u8, seg_feature_data, sizeof(__s16) * 8 * 4)
+ __array(__u8, seg_feature_enabled, 8)
+ __array(__u8, seg_tree_probs, 7)
+ __array(__u8, seg_pred_probs, 3)
+ __field(__u8, seg_flags)
+ __field(__u32, flags)
+ __field(__u16, compressed_header_size)
+ __field(__u16, uncompressed_header_size)
+ __field(__u16, frame_width_minus_1)
+ __field(__u16, frame_height_minus_1)
+ __field(__u16, render_width_minus_1)
+ __field(__u16, render_height_minus_1)
+ __field(__u64, last_frame_ts)
+ __field(__u64, golden_frame_ts)
+ __field(__u64, alt_frame_ts)
+ __field(__u8, ref_frame_sign_bias)
+ __field(__u8, reset_frame_context)
+ __field(__u8, frame_context_idx)
+ __field(__u8, profile)
+ __field(__u8, bit_depth)
+ __field(__u8, interpolation_filter)
+ __field(__u8, tile_cols_log2)
+ __field(__u8, tile_rows_log2)
+ __field(__u8, reference_mode)),
+ TP_fast_assign(memcpy(__entry->lf_ref_deltas, f->lf.ref_deltas,
+ sizeof(__entry->lf_ref_deltas));
+ memcpy(__entry->lf_mode_deltas, f->lf.mode_deltas,
+ sizeof(__entry->lf_mode_deltas));
+ __entry->lf_level = f->lf.level;
+ __entry->lf_sharpness = f->lf.sharpness;
+ __entry->lf_flags = f->lf.flags;
+ __entry->quant_base_q_idx = f->quant.base_q_idx;
+ __entry->quant_delta_q_y_dc = f->quant.delta_q_y_dc;
+ __entry->quant_delta_q_uv_dc = f->quant.delta_q_uv_dc;
+ __entry->quant_delta_q_uv_ac = f->quant.delta_q_uv_ac;
+ memcpy(__entry->seg_feature_data, f->seg.feature_data,
+ sizeof(__entry->seg_feature_data));
+ memcpy(__entry->seg_feature_enabled, f->seg.feature_enabled,
+ sizeof(__entry->seg_feature_enabled));
+ memcpy(__entry->seg_tree_probs, f->seg.tree_probs,
+ sizeof(__entry->seg_tree_probs));
+ memcpy(__entry->seg_pred_probs, f->seg.pred_probs,
+ sizeof(__entry->seg_pred_probs));
+ __entry->seg_flags = f->seg.flags;
+ __entry->flags = f->flags;
+ __entry->compressed_header_size = f->compressed_header_size;
+ __entry->uncompressed_header_size = f->uncompressed_header_size;
+ __entry->frame_width_minus_1 = f->frame_width_minus_1;
+ __entry->frame_height_minus_1 = f->frame_height_minus_1;
+ __entry->render_width_minus_1 = f->render_width_minus_1;
+ __entry->render_height_minus_1 = f->render_height_minus_1;
+ __entry->last_frame_ts = f->last_frame_ts;
+ __entry->golden_frame_ts = f->golden_frame_ts;
+ __entry->alt_frame_ts = f->alt_frame_ts;
+ __entry->ref_frame_sign_bias = f->ref_frame_sign_bias;
+ __entry->reset_frame_context = f->reset_frame_context;
+ __entry->frame_context_idx = f->frame_context_idx;
+ __entry->profile = f->profile;
+ __entry->bit_depth = f->bit_depth;
+ __entry->interpolation_filter = f->interpolation_filter;
+ __entry->tile_cols_log2 = f->tile_cols_log2;
+ __entry->tile_rows_log2 = f->tile_rows_log2;
+ __entry->reference_mode = f->reference_mode;),
TP_printk("\nlf.ref_deltas %s\n"
"lf.mode_deltas %s\n"
"lf.level %u\n"
@@ -1403,41 +2233,41 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
"tile_cols_log2 %u\n"
"tile_rows_log_2 %u\n"
"reference_mode %s\n",
- __print_array(__entry->f.lf.ref_deltas,
- ARRAY_SIZE(__entry->f.lf.ref_deltas),
- sizeof(__entry->f.lf.ref_deltas[0])),
- __print_array(__entry->f.lf.mode_deltas,
- ARRAY_SIZE(__entry->f.lf.mode_deltas),
- sizeof(__entry->f.lf.mode_deltas[0])),
- __entry->f.lf.level,
- __entry->f.lf.sharpness,
- __print_flags(__entry->f.lf.flags, "|",
+ __print_array(__entry->lf_ref_deltas,
+ ARRAY_SIZE(__entry->lf_ref_deltas),
+ sizeof(__entry->lf_ref_deltas[0])),
+ __print_array(__entry->lf_mode_deltas,
+ ARRAY_SIZE(__entry->lf_mode_deltas),
+ sizeof(__entry->lf_mode_deltas[0])),
+ __entry->lf_level,
+ __entry->lf_sharpness,
+ __print_flags(__entry->lf_flags, "|",
{V4L2_VP9_LOOP_FILTER_FLAG_DELTA_ENABLED, "DELTA_ENABLED"},
{V4L2_VP9_LOOP_FILTER_FLAG_DELTA_UPDATE, "DELTA_UPDATE"}),
- __entry->f.quant.base_q_idx,
- __entry->f.quant.delta_q_y_dc,
- __entry->f.quant.delta_q_uv_dc,
- __entry->f.quant.delta_q_uv_ac,
+ __entry->quant_base_q_idx,
+ __entry->quant_delta_q_y_dc,
+ __entry->quant_delta_q_uv_dc,
+ __entry->quant_delta_q_uv_ac,
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->f.seg.feature_data,
- sizeof(__entry->f.seg.feature_data),
+ __entry->seg_feature_data,
+ sizeof(__entry->seg_feature_data),
false),
- __print_array(__entry->f.seg.feature_enabled,
- ARRAY_SIZE(__entry->f.seg.feature_enabled),
- sizeof(__entry->f.seg.feature_enabled[0])),
- __print_array(__entry->f.seg.tree_probs,
- ARRAY_SIZE(__entry->f.seg.tree_probs),
- sizeof(__entry->f.seg.tree_probs[0])),
- __print_array(__entry->f.seg.pred_probs,
- ARRAY_SIZE(__entry->f.seg.pred_probs),
- sizeof(__entry->f.seg.pred_probs[0])),
- __print_flags(__entry->f.seg.flags, "|",
+ __print_array(__entry->seg_feature_enabled,
+ ARRAY_SIZE(__entry->seg_feature_enabled),
+ sizeof(__entry->seg_feature_enabled[0])),
+ __print_array(__entry->seg_tree_probs,
+ ARRAY_SIZE(__entry->seg_tree_probs),
+ sizeof(__entry->seg_tree_probs[0])),
+ __print_array(__entry->seg_pred_probs,
+ ARRAY_SIZE(__entry->seg_pred_probs),
+ sizeof(__entry->seg_pred_probs[0])),
+ __print_flags(__entry->seg_flags, "|",
{V4L2_VP9_SEGMENTATION_FLAG_ENABLED, "ENABLED"},
{V4L2_VP9_SEGMENTATION_FLAG_UPDATE_MAP, "UPDATE_MAP"},
{V4L2_VP9_SEGMENTATION_FLAG_TEMPORAL_UPDATE, "TEMPORAL_UPDATE"},
{V4L2_VP9_SEGMENTATION_FLAG_UPDATE_DATA, "UPDATE_DATA"},
{V4L2_VP9_SEGMENTATION_FLAG_ABS_OR_DELTA_UPDATE, "ABS_OR_DELTA_UPDATE"}),
- __print_flags(__entry->f.flags, "|",
+ __print_flags(__entry->flags, "|",
{V4L2_VP9_FRAME_FLAG_KEY_FRAME, "KEY_FRAME"},
{V4L2_VP9_FRAME_FLAG_SHOW_FRAME, "SHOW_FRAME"},
{V4L2_VP9_FRAME_FLAG_ERROR_RESILIENT, "ERROR_RESILIENT"},
@@ -1448,35 +2278,35 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
{V4L2_VP9_FRAME_FLAG_X_SUBSAMPLING, "X_SUBSAMPLING"},
{V4L2_VP9_FRAME_FLAG_Y_SUBSAMPLING, "Y_SUBSAMPLING"},
{V4L2_VP9_FRAME_FLAG_COLOR_RANGE_FULL_SWING, "COLOR_RANGE_FULL_SWING"}),
- __entry->f.compressed_header_size,
- __entry->f.uncompressed_header_size,
- __entry->f.frame_width_minus_1,
- __entry->f.frame_height_minus_1,
- __entry->f.render_width_minus_1,
- __entry->f.render_height_minus_1,
- __entry->f.last_frame_ts,
- __entry->f.golden_frame_ts,
- __entry->f.alt_frame_ts,
- __print_symbolic(__entry->f.ref_frame_sign_bias,
+ __entry->compressed_header_size,
+ __entry->uncompressed_header_size,
+ __entry->frame_width_minus_1,
+ __entry->frame_height_minus_1,
+ __entry->render_width_minus_1,
+ __entry->render_height_minus_1,
+ __entry->last_frame_ts,
+ __entry->golden_frame_ts,
+ __entry->alt_frame_ts,
+ __print_symbolic(__entry->ref_frame_sign_bias,
{V4L2_VP9_SIGN_BIAS_LAST, "SIGN_BIAS_LAST"},
{V4L2_VP9_SIGN_BIAS_GOLDEN, "SIGN_BIAS_GOLDEN"},
{V4L2_VP9_SIGN_BIAS_ALT, "SIGN_BIAS_ALT"}),
- __print_symbolic(__entry->f.reset_frame_context,
+ __print_symbolic(__entry->reset_frame_context,
{V4L2_VP9_RESET_FRAME_CTX_NONE, "RESET_FRAME_CTX_NONE"},
{V4L2_VP9_RESET_FRAME_CTX_SPEC, "RESET_FRAME_CTX_SPEC"},
{V4L2_VP9_RESET_FRAME_CTX_ALL, "RESET_FRAME_CTX_ALL"}),
- __entry->f.frame_context_idx,
- __entry->f.profile,
- __entry->f.bit_depth,
- __print_symbolic(__entry->f.interpolation_filter,
+ __entry->frame_context_idx,
+ __entry->profile,
+ __entry->bit_depth,
+ __print_symbolic(__entry->interpolation_filter,
{V4L2_VP9_INTERP_FILTER_EIGHTTAP, "INTERP_FILTER_EIGHTTAP"},
{V4L2_VP9_INTERP_FILTER_EIGHTTAP_SMOOTH, "INTERP_FILTER_EIGHTTAP_SMOOTH"},
{V4L2_VP9_INTERP_FILTER_EIGHTTAP_SHARP, "INTERP_FILTER_EIGHTTAP_SHARP"},
{V4L2_VP9_INTERP_FILTER_BILINEAR, "INTERP_FILTER_BILINEAR"},
{V4L2_VP9_INTERP_FILTER_SWITCHABLE, "INTERP_FILTER_SWITCHABLE"}),
- __entry->f.tile_cols_log2,
- __entry->f.tile_rows_log2,
- __print_symbolic(__entry->f.reference_mode,
+ __entry->tile_cols_log2,
+ __entry->tile_rows_log2,
+ __print_symbolic(__entry->reference_mode,
{V4L2_VP9_REFERENCE_MODE_SINGLE_REFERENCE, "REFERENCE_MODE_SINGLE_REFERENCE"},
{V4L2_VP9_REFERENCE_MODE_COMPOUND_REFERENCE, "REFERENCE_MODE_COMPOUND_REFERENCE"},
{V4L2_VP9_REFERENCE_MODE_SELECT, "REFERENCE_MODE_SELECT"}))
@@ -1485,8 +2315,35 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
TP_ARGS(h),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_compressed_hdr, h)),
- TP_fast_assign(__entry->h = *h;),
+ TP_STRUCT__entry(__field(__u8, tx_mode)
+ __array(__u8, tx8, 2 * 1)
+ __array(__u8, tx16, 2 * 2)
+ __array(__u8, tx32, 2 * 3)
+ __array(__u8, skip, 3)
+ __array(__u8, inter_mode, 7 * 3)
+ __array(__u8, interp_filter, 4 * 2)
+ __array(__u8, is_inter, 4)
+ __array(__u8, comp_mode, 5)
+ __array(__u8, single_ref, 5 * 2)
+ __array(__u8, comp_ref, 5)
+ __array(__u8, y_mode, 4 * 9)
+ __array(__u8, uv_mode, 10 * 9)
+ __array(__u8, partition, 16 * 3)),
+ TP_fast_assign(__entry->tx_mode = h->tx_mode;
+ memcpy(__entry->tx8, h->tx8, sizeof(__entry->tx8));
+ memcpy(__entry->tx16, h->tx16, sizeof(__entry->tx16));
+ memcpy(__entry->tx32, h->tx32, sizeof(__entry->tx32));
+ memcpy(__entry->skip, h->skip, sizeof(__entry->skip));
+ memcpy(__entry->inter_mode, h->inter_mode, sizeof(__entry->inter_mode));
+ memcpy(__entry->interp_filter, h->interp_filter,
+ sizeof(__entry->interp_filter));
+ memcpy(__entry->is_inter, h->is_inter, sizeof(__entry->is_inter));
+ memcpy(__entry->comp_mode, h->comp_mode, sizeof(__entry->comp_mode));
+ memcpy(__entry->single_ref, h->single_ref, sizeof(__entry->single_ref));
+ memcpy(__entry->comp_ref, h->comp_ref, sizeof(__entry->comp_ref));
+ memcpy(__entry->y_mode, h->y_mode, sizeof(__entry->y_mode));
+ memcpy(__entry->uv_mode, h->uv_mode, sizeof(__entry->uv_mode));
+ memcpy(__entry->partition, h->partition, sizeof(__entry->partition));),
TP_printk("\ntx_mode %s\n"
"tx8 {%s}\n"
"tx16 {%s}\n"
@@ -1501,59 +2358,59 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
"y_mode {%s}\n"
"uv_mode {%s}\n"
"partition {%s}\n",
- __print_symbolic(__entry->h.tx_mode,
+ __print_symbolic(__entry->tx_mode,
{V4L2_VP9_TX_MODE_ONLY_4X4, "TX_MODE_ONLY_4X4"},
{V4L2_VP9_TX_MODE_ALLOW_8X8, "TX_MODE_ALLOW_8X8"},
{V4L2_VP9_TX_MODE_ALLOW_16X16, "TX_MODE_ALLOW_16X16"},
{V4L2_VP9_TX_MODE_ALLOW_32X32, "TX_MODE_ALLOW_32X32"},
{V4L2_VP9_TX_MODE_SELECT, "TX_MODE_SELECT"}),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.tx8,
- sizeof(__entry->h.tx8),
+ __entry->tx8,
+ sizeof(__entry->tx8),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.tx16,
- sizeof(__entry->h.tx16),
+ __entry->tx16,
+ sizeof(__entry->tx16),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.tx32,
- sizeof(__entry->h.tx32),
+ __entry->tx32,
+ sizeof(__entry->tx32),
false),
- __print_array(__entry->h.skip,
- ARRAY_SIZE(__entry->h.skip),
- sizeof(__entry->h.skip[0])),
+ __print_array(__entry->skip,
+ ARRAY_SIZE(__entry->skip),
+ sizeof(__entry->skip[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.inter_mode,
- sizeof(__entry->h.inter_mode),
+ __entry->inter_mode,
+ sizeof(__entry->inter_mode),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.interp_filter,
- sizeof(__entry->h.interp_filter),
+ __entry->interp_filter,
+ sizeof(__entry->interp_filter),
false),
- __print_array(__entry->h.is_inter,
- ARRAY_SIZE(__entry->h.is_inter),
- sizeof(__entry->h.is_inter[0])),
- __print_array(__entry->h.comp_mode,
- ARRAY_SIZE(__entry->h.comp_mode),
- sizeof(__entry->h.comp_mode[0])),
+ __print_array(__entry->is_inter,
+ ARRAY_SIZE(__entry->is_inter),
+ sizeof(__entry->is_inter[0])),
+ __print_array(__entry->comp_mode,
+ ARRAY_SIZE(__entry->comp_mode),
+ sizeof(__entry->comp_mode[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.single_ref,
- sizeof(__entry->h.single_ref),
+ __entry->single_ref,
+ sizeof(__entry->single_ref),
false),
- __print_array(__entry->h.comp_ref,
- ARRAY_SIZE(__entry->h.comp_ref),
- sizeof(__entry->h.comp_ref[0])),
+ __print_array(__entry->comp_ref,
+ ARRAY_SIZE(__entry->comp_ref),
+ sizeof(__entry->comp_ref[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.y_mode,
- sizeof(__entry->h.y_mode),
+ __entry->y_mode,
+ sizeof(__entry->y_mode),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.uv_mode,
- sizeof(__entry->h.uv_mode),
+ __entry->uv_mode,
+ sizeof(__entry->uv_mode),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.partition,
- sizeof(__entry->h.partition),
+ __entry->partition,
+ sizeof(__entry->partition),
false)
)
);
@@ -1561,12 +2418,12 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_coef_tmpl,
TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
TP_ARGS(h),
- TP_STRUCT__entry(__field_struct(struct v4l2_ctrl_vp9_compressed_hdr, h)),
- TP_fast_assign(__entry->h = *h;),
+ TP_STRUCT__entry(__array(__u8, coef, 4 * 2 * 2 * 6 * 6 * 3)),
+ TP_fast_assign(memcpy(__entry->coef, h->coef, sizeof(__entry->coef));),
TP_printk("\n coef {%s}",
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->h.coef,
- sizeof(__entry->h.coef),
+ __entry->coef,
+ sizeof(__entry->coef),
false)
)
);
@@ -1574,8 +2431,24 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_coef_tmpl,
DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
TP_PROTO(const struct v4l2_vp9_mv_probs *p),
TP_ARGS(p),
- TP_STRUCT__entry(__field_struct(struct v4l2_vp9_mv_probs, p)),
- TP_fast_assign(__entry->p = *p;),
+ TP_STRUCT__entry(__array(__u8, joint, 3)
+ __array(__u8, sign, 2)
+ __array(__u8, classes, 2 * 10)
+ __array(__u8, class0_bit, 2)
+ __array(__u8, bits, 2 * 10)
+ __array(__u8, class0_fr, 2 * 2 * 3)
+ __array(__u8, fr, 2 * 3)
+ __array(__u8, class0_hp, 2)
+ __array(__u8, hp, 2)),
+ TP_fast_assign(memcpy(__entry->joint, p->joint, sizeof(__entry->joint));
+ memcpy(__entry->sign, p->sign, sizeof(__entry->sign));
+ memcpy(__entry->classes, p->classes, sizeof(__entry->classes));
+ memcpy(__entry->class0_bit, p->class0_bit, sizeof(__entry->class0_bit));
+ memcpy(__entry->bits, p->bits, sizeof(__entry->bits));
+ memcpy(__entry->class0_fr, p->class0_fr, sizeof(__entry->class0_fr));
+ memcpy(__entry->fr, p->fr, sizeof(__entry->fr));
+ memcpy(__entry->class0_hp, p->class0_hp, sizeof(__entry->class0_hp));
+ memcpy(__entry->hp, p->hp, sizeof(__entry->hp));),
TP_printk("\n joint %s\n"
"sign %s\n"
"classes {%s}\n"
@@ -1585,37 +2458,37 @@ DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
"fr {%s}\n"
"class0_hp %s\n"
"hp %s\n",
- __print_array(__entry->p.joint,
- ARRAY_SIZE(__entry->p.joint),
- sizeof(__entry->p.joint[0])),
- __print_array(__entry->p.sign,
- ARRAY_SIZE(__entry->p.sign),
- sizeof(__entry->p.sign[0])),
+ __print_array(__entry->joint,
+ ARRAY_SIZE(__entry->joint),
+ sizeof(__entry->joint[0])),
+ __print_array(__entry->sign,
+ ARRAY_SIZE(__entry->sign),
+ sizeof(__entry->sign[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.classes,
- sizeof(__entry->p.classes),
+ __entry->classes,
+ sizeof(__entry->classes),
false),
- __print_array(__entry->p.class0_bit,
- ARRAY_SIZE(__entry->p.class0_bit),
- sizeof(__entry->p.class0_bit[0])),
+ __print_array(__entry->class0_bit,
+ ARRAY_SIZE(__entry->class0_bit),
+ sizeof(__entry->class0_bit[0])),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.bits,
- sizeof(__entry->p.bits),
+ __entry->bits,
+ sizeof(__entry->bits),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.class0_fr,
- sizeof(__entry->p.class0_fr),
+ __entry->class0_fr,
+ sizeof(__entry->class0_fr),
false),
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
- __entry->p.fr,
- sizeof(__entry->p.fr),
+ __entry->fr,
+ sizeof(__entry->fr),
false),
- __print_array(__entry->p.class0_hp,
- ARRAY_SIZE(__entry->p.class0_hp),
- sizeof(__entry->p.class0_hp[0])),
- __print_array(__entry->p.hp,
- ARRAY_SIZE(__entry->p.hp),
- sizeof(__entry->p.hp[0]))
+ __print_array(__entry->class0_hp,
+ ARRAY_SIZE(__entry->class0_hp),
+ sizeof(__entry->class0_hp[0])),
+ __print_array(__entry->hp,
+ ARRAY_SIZE(__entry->hp),
+ sizeof(__entry->hp[0]))
)
);
--
2.54.0
^ permalink raw reply related
* [PATCH v2 3/9] media: Add tgid and fd fields in v4l2_fh struct
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
These fields will be used in traces to help userspace tracing tools
identify streams.
The tgid field will keep the PID of the process that opened the video
file.
That is needed because trace calls can happen in IRQs, for which there is
no current PID.
The fd field helps identify the context in case the same process opens the
video device multiple times.
Note that the fd field is set in the __video_do_ioctl() function.
That is because the file descriptor has not been allocated yet when
v4l2_open() is called.
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
---
drivers/media/v4l2-core/v4l2-fh.c | 1 +
drivers/media/v4l2-core/v4l2-ioctl.c | 17 +++++++++++++++++
include/media/v4l2-fh.h | 4 ++++
3 files changed, 22 insertions(+)
diff --git a/drivers/media/v4l2-core/v4l2-fh.c b/drivers/media/v4l2-core/v4l2-fh.c
index b184bed8aca9..9c2ddd1c2137 100644
--- a/drivers/media/v4l2-core/v4l2-fh.c
+++ b/drivers/media/v4l2-core/v4l2-fh.c
@@ -37,6 +37,7 @@ void v4l2_fh_init(struct v4l2_fh *fh, struct video_device *vdev)
INIT_LIST_HEAD(&fh->available);
INIT_LIST_HEAD(&fh->subscribed);
fh->sequence = -1;
+ fh->tgid = current->tgid;
mutex_init(&fh->subscribe_lock);
}
EXPORT_SYMBOL_GPL(v4l2_fh_init);
diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c
index a2b650f4ec3c..c8746a1637f5 100644
--- a/drivers/media/v4l2-core/v4l2-ioctl.c
+++ b/drivers/media/v4l2-core/v4l2-ioctl.c
@@ -9,6 +9,7 @@
*/
#include <linux/compat.h>
+#include <linux/fdtable.h>
#include <linux/mm.h>
#include <linux/module.h>
#include <linux/slab.h>
@@ -3061,6 +3062,16 @@ void v4l_printk_ioctl(const char *prefix, unsigned int cmd)
}
EXPORT_SYMBOL(v4l_printk_ioctl);
+static int _file_iterate(const void *priv, struct file *filp, unsigned int fd)
+{
+ const struct file *fh_filp = priv;
+
+ if (fh_filp == filp)
+ return fd;
+
+ return 0;
+}
+
static long __video_do_ioctl(struct file *file,
unsigned int cmd, void *arg)
{
@@ -3081,6 +3092,12 @@ static long __video_do_ioctl(struct file *file,
return ret;
}
+ if (unlikely(!vfh->fd)) {
+ vfh->fd = iterate_fd(current->files, 0, _file_iterate, file);
+ if (!vfh->fd)
+ vfh->fd = -1;
+ }
+
/*
* We need to serialize streamon/off/reqbufs with queueing new requests.
* These ioctls may trigger the cancellation of a streaming
diff --git a/include/media/v4l2-fh.h b/include/media/v4l2-fh.h
index aad4b3689d7e..4ef4e58ab8d1 100644
--- a/include/media/v4l2-fh.h
+++ b/include/media/v4l2-fh.h
@@ -28,6 +28,8 @@ struct v4l2_ctrl_handler;
* @vdev: pointer to &struct video_device
* @ctrl_handler: pointer to &struct v4l2_ctrl_handler
* @prio: priority of the file handler, as defined by &enum v4l2_priority
+ * @tgid: process id that initialized the v4l2_fh
+ * @fd: file descriptor associated to this v4l2_fh for the process id in tgid
*
* @wait: event' s wait queue
* @subscribe_lock: serialise changes to the subscribed list; guarantee that
@@ -44,6 +46,8 @@ struct v4l2_fh {
struct video_device *vdev;
struct v4l2_ctrl_handler *ctrl_handler;
enum v4l2_priority prio;
+ uint32_t tgid;
+ int fd;
/* Events */
wait_queue_head_t wait;
--
2.54.0
^ permalink raw reply related
* [PATCH v2 4/9] media: Add tgid and fd to the v4l2-requests trace fields
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
With these fields, userspace can better track which trace event matches
with a given stream.
Even though the trace shows the PID (based on current->tgid), trace
functions could be called from other contexts, therefore showing the wrong
PID, or none at all.
These will ensure that the trace event can be matched with the PID/FD that
opened and configured the video device file.
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
---
drivers/media/test-drivers/visl/visl-dec.c | 68 ++--
include/trace/events/v4l2_controls.h | 628 +++++++++++++++++++----------
2 files changed, 445 insertions(+), 251 deletions(-)
diff --git a/drivers/media/test-drivers/visl/visl-dec.c b/drivers/media/test-drivers/visl/visl-dec.c
index 1c66a1b8d78f..2a065a6249ad 100644
--- a/drivers/media/test-drivers/visl/visl-dec.c
+++ b/drivers/media/test-drivers/visl/visl-dec.c
@@ -489,67 +489,71 @@ static void visl_tpg_fill(struct visl_ctx *ctx, struct visl_run *run)
static void visl_trace_ctrls(struct visl_ctx *ctx, struct visl_run *run)
{
int i;
+ struct v4l2_fh *fh = &ctx->fh;
switch (ctx->current_codec) {
default:
case VISL_CODEC_NONE:
break;
case VISL_CODEC_FWHT:
- trace_v4l2_ctrl_fwht_params(run->fwht.params);
+ trace_v4l2_ctrl_fwht_params(fh->tgid, fh->fd, run->fwht.params);
break;
case VISL_CODEC_MPEG2:
- trace_v4l2_ctrl_mpeg2_sequence(run->mpeg2.seq);
- trace_v4l2_ctrl_mpeg2_picture(run->mpeg2.pic);
- trace_v4l2_ctrl_mpeg2_quantisation(run->mpeg2.quant);
+ trace_v4l2_ctrl_mpeg2_sequence(fh->tgid, fh->fd, run->mpeg2.seq);
+ trace_v4l2_ctrl_mpeg2_picture(fh->tgid, fh->fd, run->mpeg2.pic);
+ trace_v4l2_ctrl_mpeg2_quantisation(fh->tgid, fh->fd, run->mpeg2.quant);
break;
case VISL_CODEC_VP8:
- trace_v4l2_ctrl_vp8_frame(run->vp8.frame);
- trace_v4l2_ctrl_vp8_entropy(run->vp8.frame);
+ trace_v4l2_ctrl_vp8_frame(fh->tgid, fh->fd, run->vp8.frame);
+ trace_v4l2_ctrl_vp8_entropy(fh->tgid, fh->fd, run->vp8.frame);
break;
case VISL_CODEC_VP9:
- trace_v4l2_ctrl_vp9_frame(run->vp9.frame);
- trace_v4l2_ctrl_vp9_compressed_hdr(run->vp9.probs);
- trace_v4l2_ctrl_vp9_compressed_coeff(run->vp9.probs);
- trace_v4l2_vp9_mv_probs(&run->vp9.probs->mv);
+ trace_v4l2_ctrl_vp9_frame(fh->tgid, fh->fd, run->vp9.frame);
+ trace_v4l2_ctrl_vp9_compressed_hdr(fh->tgid, fh->fd, run->vp9.probs);
+ trace_v4l2_ctrl_vp9_compressed_coeff(fh->tgid, fh->fd, run->vp9.probs);
+ trace_v4l2_vp9_mv_probs(fh->tgid, fh->fd, &run->vp9.probs->mv);
break;
case VISL_CODEC_H264:
- trace_v4l2_ctrl_h264_sps(run->h264.sps);
- trace_v4l2_ctrl_h264_pps(run->h264.pps);
- trace_v4l2_ctrl_h264_scaling_matrix(run->h264.sm);
- trace_v4l2_ctrl_h264_slice_params(run->h264.spram);
+ trace_v4l2_ctrl_h264_sps(fh->tgid, fh->fd, run->h264.sps);
+ trace_v4l2_ctrl_h264_pps(fh->tgid, fh->fd, run->h264.pps);
+ trace_v4l2_ctrl_h264_scaling_matrix(fh->tgid, fh->fd, run->h264.sm);
+ trace_v4l2_ctrl_h264_slice_params(fh->tgid, fh->fd, run->h264.spram);
for (i = 0; i < ARRAY_SIZE(run->h264.spram->ref_pic_list0); i++)
- trace_v4l2_h264_ref_pic_list0(&run->h264.spram->ref_pic_list0[i], i);
+ trace_v4l2_h264_ref_pic_list0(fh->tgid, fh->fd,
+ &run->h264.spram->ref_pic_list0[i], i);
for (i = 0; i < ARRAY_SIZE(run->h264.spram->ref_pic_list0); i++)
- trace_v4l2_h264_ref_pic_list1(&run->h264.spram->ref_pic_list1[i], i);
+ trace_v4l2_h264_ref_pic_list1(fh->tgid, fh->fd,
+ &run->h264.spram->ref_pic_list1[i], i);
- trace_v4l2_ctrl_h264_decode_params(run->h264.dpram);
+ trace_v4l2_ctrl_h264_decode_params(fh->tgid, fh->fd, run->h264.dpram);
for (i = 0; i < ARRAY_SIZE(run->h264.dpram->dpb); i++)
- trace_v4l2_h264_dpb_entry(&run->h264.dpram->dpb[i], i);
+ trace_v4l2_h264_dpb_entry(fh->tgid, fh->fd, &run->h264.dpram->dpb[i], i);
- trace_v4l2_ctrl_h264_pred_weights(run->h264.pwht);
+ trace_v4l2_ctrl_h264_pred_weights(fh->tgid, fh->fd, run->h264.pwht);
break;
case VISL_CODEC_HEVC:
- trace_v4l2_ctrl_hevc_sps(run->hevc.sps);
- trace_v4l2_ctrl_hevc_pps(run->hevc.pps);
- trace_v4l2_ctrl_hevc_slice_params(run->hevc.spram);
- trace_v4l2_ctrl_hevc_scaling_matrix(run->hevc.sm);
- trace_v4l2_ctrl_hevc_decode_params(run->hevc.dpram);
+ trace_v4l2_ctrl_hevc_sps(fh->tgid, fh->fd, run->hevc.sps);
+ trace_v4l2_ctrl_hevc_pps(fh->tgid, fh->fd, run->hevc.pps);
+ trace_v4l2_ctrl_hevc_slice_params(fh->tgid, fh->fd, run->hevc.spram);
+ trace_v4l2_ctrl_hevc_scaling_matrix(fh->tgid, fh->fd, run->hevc.sm);
+ trace_v4l2_ctrl_hevc_decode_params(fh->tgid, fh->fd, run->hevc.dpram);
for (i = 0; i < ARRAY_SIZE(run->hevc.dpram->dpb); i++)
- trace_v4l2_hevc_dpb_entry(&run->hevc.dpram->dpb[i]);
+ trace_v4l2_hevc_dpb_entry(fh->tgid, fh->fd, &run->hevc.dpram->dpb[i]);
- trace_v4l2_hevc_pred_weight_table(&run->hevc.spram->pred_weight_table);
- trace_v4l2_ctrl_hevc_ext_sps_lt_rps(run->hevc.rps_lt);
- trace_v4l2_ctrl_hevc_ext_sps_st_rps(run->hevc.rps_st);
+ trace_v4l2_hevc_pred_weight_table(fh->tgid, fh->fd,
+ &run->hevc.spram->pred_weight_table);
+ trace_v4l2_ctrl_hevc_ext_sps_lt_rps(fh->tgid, fh->fd, run->hevc.rps_lt);
+ trace_v4l2_ctrl_hevc_ext_sps_st_rps(fh->tgid, fh->fd, run->hevc.rps_st);
break;
case VISL_CODEC_AV1:
- trace_v4l2_ctrl_av1_sequence(run->av1.seq);
- trace_v4l2_ctrl_av1_frame(run->av1.frame);
- trace_v4l2_ctrl_av1_film_grain(run->av1.grain);
- trace_v4l2_ctrl_av1_tile_group_entry(run->av1.tge);
+ trace_v4l2_ctrl_av1_sequence(fh->tgid, fh->fd, run->av1.seq);
+ trace_v4l2_ctrl_av1_frame(fh->tgid, fh->fd, run->av1.frame);
+ trace_v4l2_ctrl_av1_film_grain(fh->tgid, fh->fd, run->av1.grain);
+ trace_v4l2_ctrl_av1_tile_group_entry(fh->tgid, fh->fd, run->av1.tge);
break;
}
}
diff --git a/include/trace/events/v4l2_controls.h b/include/trace/events/v4l2_controls.h
index 3a9bc75752bf..a7c61c36a025 100644
--- a/include/trace/events/v4l2_controls.h
+++ b/include/trace/events/v4l2_controls.h
@@ -14,27 +14,39 @@
* They can be identified by the name of the event. All control fields are copied in a TP_STRUCT
* field so that they can be filtered separately in userspace.
*
+ * In addition to the controls fields, tgid and fd are also added in each trace events.
+ * This allows to identify controls set by a specific process and to match them with other events
+ * from the same process.
+ * tgid contains the process id that opened the video device.
+ * fd is the file descriptor in the tgid, used in case a process opens multiple video devices.
+ *
* Currently only the codec controls are supported.
*/
/* AV1 controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_seq_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field(__u32, flags)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_sequence *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u32, flags)
__field(__u8, seq_profile)
__field(__u8, order_hint_bits)
__field(__u8, bit_depth)
__field(__u16, max_frame_width_minus_1)
__field(__u16, max_frame_height_minus_1)),
- TP_fast_assign(__entry->flags = s->flags;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->flags = s->flags;
__entry->seq_profile = s->seq_profile;
__entry->order_hint_bits = s->order_hint_bits;
__entry->bit_depth = s->bit_depth;
__entry->max_frame_width_minus_1 = s->max_frame_width_minus_1;
__entry->max_frame_height_minus_1 = s->max_frame_height_minus_1;),
- TP_printk("\nflags %s\nseq_profile: %u\norder_hint_bits: %u\nbit_depth: %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nflags %s\nseq_profile: %u\norder_hint_bits: %u\nbit_depth: %u\n"
"max_frame_width_minus_1: %u\nmax_frame_height_minus_1: %u\n",
+ __entry->tgid, __entry->fd,
__print_flags(__entry->flags, "|",
{V4L2_AV1_SEQUENCE_FLAG_STILL_PICTURE, "STILL_PICTURE"},
{V4L2_AV1_SEQUENCE_FLAG_USE_128X128_SUPERBLOCK, "USE_128X128_SUPERBLOCK"},
@@ -65,17 +77,23 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_seq_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_tge_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
- TP_ARGS(t),
- TP_STRUCT__entry(__field(__u32, tile_offset)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_tile_group_entry *t),
+ TP_ARGS(tgid, fd, t),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u32, tile_offset)
__field(__u32, tile_size)
__field(__u32, tile_row)
__field(__u32, tile_col)),
- TP_fast_assign(__entry->tile_offset = t->tile_offset;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->tile_offset = t->tile_offset;
__entry->tile_size = t->tile_size;
__entry->tile_row = t->tile_row;
__entry->tile_col = t->tile_col;),
- TP_printk("\ntile_offset: %u\n tile_size: %u\n tile_row: %u\ntile_col: %u\n",
+ TP_printk("tgid = %u, fd = %u, "
+ "\ntile_offset: %u\n tile_size: %u\n tile_row: %u\ntile_col: %u\n",
+ __entry->tgid, __entry->fd,
__entry->tile_offset,
__entry->tile_size,
__entry->tile_row,
@@ -84,9 +102,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_tge_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field(u8, tile_info_flags)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_frame *f),
+ TP_ARGS(tgid, fd, f),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u8, tile_info_flags)
__field(u8, tile_info_context_update_tile_id)
__field(u8, tile_info_tile_cols)
__field(u8, tile_info_tile_rows)
@@ -144,7 +164,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
__array(u64, reference_frame_ts, V4L2_AV1_TOTAL_REFS_PER_FRAME)
__array(s8, ref_frame_idx, V4L2_AV1_REFS_PER_FRAME)
__field(u8, refresh_frame_flags)),
- TP_fast_assign(__entry->tile_info_flags = f->tile_info.flags;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->tile_info_flags = f->tile_info.flags;
__entry->tile_info_context_update_tile_id =
f->tile_info.context_update_tile_id;
__entry->tile_info_tile_cols = f->tile_info.tile_cols;
@@ -226,7 +248,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
memcpy(__entry->ref_frame_idx, f->ref_frame_idx,
sizeof(__entry->ref_frame_idx));
__entry->refresh_frame_flags = f->refresh_frame_flags;),
- TP_printk("\ntile_info.flags: %s\ntile_info.context_update_tile_id: %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\ntile_info.flags: %s\ntile_info.context_update_tile_id: %u\n"
"tile_info.tile_cols: %u\ntile_info.tile_rows: %u\n"
"tile_info.mi_col_starts: %s\ntile_info.mi_row_starts: %s\n"
"tile_info.width_in_sbs_minus_1: %s\ntile_info.height_in_sbs_minus_1: %s\n"
@@ -250,6 +273,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
"render_width_minus_1: %u\nrender_height_minus_1: %u\ncurrent_frame_id: %u\n"
"buffer_removal_time: %s\norder_hints: %s\nreference_frame_ts: %s\n"
"ref_frame_idx: %s\nrefresh_frame_flags: %u\n",
+ __entry->tgid, __entry->fd,
__print_flags(__entry->tile_info_flags, "|",
{V4L2_AV1_TILE_INFO_FLAG_UNIFORM_TILE_SPACING, "UNIFORM_TILE_SPACING"}),
__entry->tile_info_context_update_tile_id,
@@ -385,9 +409,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_frame_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
- TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__field(__u8, flags)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_film_grain *f),
+ TP_ARGS(tgid, fd, f),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u8, flags)
__field(__u8, cr_mult)
__field(__u16, grain_seed)
__field(__u8, film_grain_params_ref_idx)
@@ -412,7 +438,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
__field(__u8, cr_luma_mult)
__field(__u16, cb_offset)
__field(__u16, cr_offset)),
- TP_fast_assign(__entry->flags = f->flags;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->flags = f->flags;
__entry->cr_mult = f->cr_mult;
__entry->grain_seed = f->grain_seed;
__entry->film_grain_params_ref_idx = f->film_grain_params_ref_idx;
@@ -446,7 +474,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
__entry->cr_luma_mult = f->cr_luma_mult;
__entry->cb_offset = f->cb_offset;
__entry->cr_offset = f->cr_offset;),
- TP_printk("\nflags %s\ncr_mult: %u\ngrain_seed: %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nflags %s\ncr_mult: %u\ngrain_seed: %u\n"
"film_grain_params_ref_idx: %u\nnum_y_points: %u\npoint_y_value: %s\n"
"point_y_scaling: %s\nnum_cb_points: %u\npoint_cb_value: %s\n"
"point_cb_scaling: %s\nnum_cr_points: %u\npoint_cr_value: %s\n"
@@ -455,6 +484,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
"ar_coeffs_cr_plus_128: %s\nar_coeff_shift_minus_6: %u\n"
"grain_scale_shift: %u\ncb_mult: %u\ncb_luma_mult: %u\ncr_luma_mult: %u\n"
"cb_offset: %u\ncr_offset: %u\n",
+ __entry->tgid, __entry->fd,
__print_flags(__entry->flags, "|",
{V4L2_AV1_FILM_GRAIN_FLAG_APPLY_GRAIN, "APPLY_GRAIN"},
{V4L2_AV1_FILM_GRAIN_FLAG_UPDATE_GRAIN, "UPDATE_GRAIN"},
@@ -507,31 +537,32 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_av1_film_grain_tmpl,
)
DEFINE_EVENT(v4l2_ctrl_av1_seq_tmpl, v4l2_ctrl_av1_sequence,
- TP_PROTO(const struct v4l2_ctrl_av1_sequence *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_sequence *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_ctrl_av1_frame_tmpl, v4l2_ctrl_av1_frame,
- TP_PROTO(const struct v4l2_ctrl_av1_frame *f),
- TP_ARGS(f)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_frame *f),
+ TP_ARGS(tgid, fd, f)
);
DEFINE_EVENT(v4l2_ctrl_av1_tge_tmpl, v4l2_ctrl_av1_tile_group_entry,
- TP_PROTO(const struct v4l2_ctrl_av1_tile_group_entry *t),
- TP_ARGS(t)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_tile_group_entry *t),
+ TP_ARGS(tgid, fd, t)
);
DEFINE_EVENT(v4l2_ctrl_av1_film_grain_tmpl, v4l2_ctrl_av1_film_grain,
- TP_PROTO(const struct v4l2_ctrl_av1_film_grain *f),
- TP_ARGS(f)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_av1_film_grain *f),
+ TP_ARGS(tgid, fd, f)
);
/* FWHT controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_fwht_params *p),
- TP_ARGS(p),
- TP_STRUCT__entry(
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_fwht_params *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
__field(u64, backward_ref_ts)
__field(u32, version)
__field(u32, width)
@@ -542,7 +573,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
__field(u32, ycbcr_enc)
__field(u32, quantization)
),
- TP_fast_assign(
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
__entry->backward_ref_ts = p->backward_ref_ts;
__entry->version = p->version;
__entry->width = p->width;
@@ -553,8 +585,10 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
__entry->ycbcr_enc = p->ycbcr_enc;
__entry->quantization = p->quantization;
),
- TP_printk("backward_ref_ts %llu version %u width %u height %u flags %s colorspace %u "
+ TP_printk("tgid = %u, fd = %u, "
+ "backward_ref_ts %llu version %u width %u height %u flags %s colorspace %u "
"xfer_func %u ycbcr_enc %u quantization %u",
+ __entry->tgid, __entry->fd,
__entry->backward_ref_ts, __entry->version, __entry->width, __entry->height,
__print_flags(__entry->flags, "|",
{V4L2_FWHT_FL_IS_INTERLACED, "IS_INTERLACED"},
@@ -574,16 +608,18 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_fwht_params_tmpl,
);
DEFINE_EVENT(v4l2_ctrl_fwht_params_tmpl, v4l2_ctrl_fwht_params,
- TP_PROTO(const struct v4l2_ctrl_fwht_params *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_fwht_params *p),
+ TP_ARGS(tgid, fd, p)
);
/* H264 controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field(u8, profile_idc)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_sps *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u8, profile_idc)
__field(u8, constraint_set_flags)
__field(u8, level_idc)
__field(u8, seq_parameter_set_id)
@@ -601,7 +637,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
__field(u16, pic_width_in_mbs_minus1)
__field(u16, pic_height_in_map_units_minus1)
__field(u32, flags)),
- TP_fast_assign(__entry->profile_idc = s->profile_idc;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->profile_idc = s->profile_idc;
__entry->constraint_set_flags = s->constraint_set_flags;
__entry->level_idc = s->level_idc;
__entry->seq_parameter_set_id = s->seq_parameter_set_id;
@@ -622,7 +660,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
__entry->pic_width_in_mbs_minus1 = s->pic_width_in_mbs_minus1;
__entry->pic_height_in_map_units_minus1 = s->pic_height_in_map_units_minus1;
__entry->flags = s->flags),
- TP_printk("\nprofile_idc %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nprofile_idc %u\n"
"constraint_set_flags %s\n"
"level_idc %u\n"
"seq_parameter_set_id %u\n"
@@ -640,6 +679,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
"pic_width_in_mbs_minus1 %u\n"
"pic_height_in_map_units_minus1 %u\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->profile_idc,
__print_flags(__entry->constraint_set_flags, "|",
{V4L2_H264_SPS_CONSTRAINT_SET0_FLAG, "CONSTRAINT_SET0_FLAG"},
@@ -679,9 +719,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_sps_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field(u8, pic_parameter_set_id)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_pps *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u8, pic_parameter_set_id)
__field(u8, seq_parameter_set_id)
__field(u8, num_slice_groups_minus1)
__field(u8, num_ref_idx_l0_default_active_minus1)
@@ -692,7 +734,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
__field(__s8, chroma_qp_index_offset)
__field(__s8, second_chroma_qp_index_offset)
__field(u16, flags)),
- TP_fast_assign(__entry->pic_parameter_set_id = p->pic_parameter_set_id;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->pic_parameter_set_id = p->pic_parameter_set_id;
__entry->seq_parameter_set_id = p->seq_parameter_set_id;
__entry->num_slice_groups_minus1 = p->num_slice_groups_minus1;
__entry->num_ref_idx_l0_default_active_minus1 =
@@ -705,7 +749,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
__entry->chroma_qp_index_offset = p->chroma_qp_index_offset;
__entry->second_chroma_qp_index_offset = p->second_chroma_qp_index_offset;
__entry->flags = p->flags),
- TP_printk("\npic_parameter_set_id %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\npic_parameter_set_id %u\n"
"seq_parameter_set_id %u\n"
"num_slice_groups_minus1 %u\n"
"num_ref_idx_l0_default_active_minus1 %u\n"
@@ -716,6 +761,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
"chroma_qp_index_offset %d\n"
"second_chroma_qp_index_offset %d\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->pic_parameter_set_id,
__entry->seq_parameter_set_id,
__entry->num_slice_groups_minus1,
@@ -741,15 +787,21 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pps_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_scaling_matrix_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__array(u8, scaling_list_4x4, 6 * 16)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_scaling_matrix *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(u8, scaling_list_4x4, 6 * 16)
__array(u8, scaling_list_8x8, 6 * 64)),
- TP_fast_assign(memcpy(__entry->scaling_list_4x4, s->scaling_list_4x4,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->scaling_list_4x4, s->scaling_list_4x4,
sizeof(__entry->scaling_list_4x4));
memcpy(__entry->scaling_list_8x8, s->scaling_list_8x8,
sizeof(__entry->scaling_list_8x8))),
- TP_printk("\nscaling_list_4x4 {%s}\nscaling_list_8x8 {%s}",
+ TP_printk("tgid = %u, fd = %u, "
+ "\nscaling_list_4x4 {%s}\nscaling_list_8x8 {%s}",
+ __entry->tgid, __entry->fd,
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
__entry->scaling_list_4x4,
sizeof(__entry->scaling_list_4x4),
@@ -762,9 +814,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_scaling_matrix_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field(u16, luma_log2_weight_denom)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_pred_weights *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u16, luma_log2_weight_denom)
__field(u16, chroma_log2_weight_denom)
__array(__s16, weight_factors_0_luma_weight, 32)
__array(__s16, weight_factors_0_luma_offset, 32)
@@ -774,7 +828,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
__array(__s16, weight_factors_1_luma_offset, 32)
__array(__s16, weight_factors_1_chroma_weight, 32 * 2)
__array(__s16, weight_factors_1_chroma_offset, 32 * 2)),
- TP_fast_assign(__entry->luma_log2_weight_denom = p->luma_log2_weight_denom;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->luma_log2_weight_denom = p->luma_log2_weight_denom;
__entry->chroma_log2_weight_denom = p->chroma_log2_weight_denom;
memcpy(__entry->weight_factors_0_luma_weight,
p->weight_factors[0].luma_weight,
@@ -800,7 +856,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
memcpy(__entry->weight_factors_1_chroma_offset,
p->weight_factors[1].chroma_offset,
sizeof(__entry->weight_factors_1_chroma_offset))),
- TP_printk("\nluma_log2_weight_denom %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nluma_log2_weight_denom %u\n"
"chroma_log2_weight_denom %u\n"
"weight_factor[0].luma_weight %s\n"
"weight_factor[0].luma_offset %s\n"
@@ -810,6 +867,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
"weight_factor[1].luma_offset %s\n"
"weight_factor[1].chroma_weight {%s}\n"
"weight_factor[1].chroma_offset {%s}\n",
+ __entry->tgid, __entry->fd,
__entry->luma_log2_weight_denom,
__entry->chroma_log2_weight_denom,
__print_array(__entry->weight_factors_0_luma_weight,
@@ -844,9 +902,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_pred_weights_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field(u32, header_bit_size)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_slice_params *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u32, header_bit_size)
__field(u32, first_mb_in_slice)
__field(u8, slice_type)
__field(u8, colour_plane_id)
@@ -860,7 +920,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
__field(u8, num_ref_idx_l0_active_minus1)
__field(u8, num_ref_idx_l1_active_minus1)
__field(u32, flags)),
- TP_fast_assign(__entry->header_bit_size = s->header_bit_size;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->header_bit_size = s->header_bit_size;
__entry->first_mb_in_slice = s->first_mb_in_slice;
__entry->slice_type = s->slice_type;
__entry->colour_plane_id = s->colour_plane_id;
@@ -874,7 +936,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
__entry->num_ref_idx_l0_active_minus1 = s->num_ref_idx_l0_active_minus1;
__entry->num_ref_idx_l1_active_minus1 = s->num_ref_idx_l1_active_minus1;
__entry->flags = s->flags),
- TP_printk("\nheader_bit_size %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nheader_bit_size %u\n"
"first_mb_in_slice %u\n"
"slice_type %s\n"
"colour_plane_id %u\n"
@@ -888,6 +951,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
"num_ref_idx_l0_active_minus1 %u\n"
"num_ref_idx_l1_active_minus1 %u\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->header_bit_size,
__entry->first_mb_in_slice,
__print_symbolic(__entry->slice_type,
@@ -913,15 +977,21 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_slice_params_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_h264_reference_tmpl,
- TP_PROTO(const struct v4l2_h264_reference *r, int i),
- TP_ARGS(r, i),
- TP_STRUCT__entry(__field(u8, fields)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_h264_reference *r, int i),
+ TP_ARGS(tgid, fd, r, i),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u8, fields)
__field(u8, index)
__field(int, i)),
- TP_fast_assign(__entry->fields = r->fields;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->fields = r->fields;
__entry->index = r->index;
__entry->i = i;),
- TP_printk("[%d]: fields %s index %u",
+ TP_printk("tgid = %u, fd = %u, "
+ "[%d]: fields %s index %u",
+ __entry->tgid, __entry->fd,
__entry->i,
__print_flags(__entry->fields, "|",
{V4L2_H264_TOP_FIELD_REF, "TOP_FIELD_REF"},
@@ -932,9 +1002,11 @@ DECLARE_EVENT_CLASS(v4l2_h264_reference_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
- TP_ARGS(d),
- TP_STRUCT__entry(__field(u16, nal_ref_idc)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_decode_params *d),
+ TP_ARGS(tgid, fd, d),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u16, nal_ref_idc)
__field(u16, frame_num)
__field(__s32, top_field_order_cnt)
__field(__s32, bottom_field_order_cnt)
@@ -947,7 +1019,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
__field(u32, pic_order_cnt_bit_size)
__field(u32, slice_group_change_cycle)
__field(u32, flags)),
- TP_fast_assign(__entry->nal_ref_idc = d->nal_ref_idc;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->nal_ref_idc = d->nal_ref_idc;
__entry->frame_num = d->frame_num;
__entry->top_field_order_cnt = d->top_field_order_cnt;
__entry->bottom_field_order_cnt = d->bottom_field_order_cnt;
@@ -960,7 +1034,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
__entry->pic_order_cnt_bit_size = d->pic_order_cnt_bit_size;
__entry->slice_group_change_cycle = d->slice_group_change_cycle;
__entry->flags = d->flags),
- TP_printk("\nnal_ref_idc %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nnal_ref_idc %u\n"
"frame_num %u\n"
"top_field_order_cnt %d\n"
"bottom_field_order_cnt %d\n"
@@ -973,6 +1048,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
"pic_order_cnt_bit_size %u\n"
"slice_group_change_cycle %u\n"
"flags %s\n",
+ __entry->tgid, __entry->fd,
__entry->nal_ref_idc,
__entry->frame_num,
__entry->top_field_order_cnt,
@@ -995,9 +1071,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_h264_decode_params_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
- TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
- TP_ARGS(e, i),
- TP_STRUCT__entry(__field(u64, reference_ts)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_h264_dpb_entry *e, int i),
+ TP_ARGS(tgid, fd, e, i),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(u64, reference_ts)
__field(u32, pic_num)
__field(u16, frame_num)
__field(u8, fields)
@@ -1005,7 +1083,9 @@ DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
__field(__s32, bottom_field_order_cnt)
__field(u32, flags)
__field(int, i)),
- TP_fast_assign(__entry->reference_ts = e->reference_ts;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->reference_ts = e->reference_ts;
__entry->pic_num = e->pic_num;
__entry->frame_num = e->frame_num;
__entry->fields = e->fields;
@@ -1013,8 +1093,10 @@ DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
__entry->bottom_field_order_cnt = e->bottom_field_order_cnt;
__entry->flags = e->flags;
__entry->i = i;),
- TP_printk("[%d]: reference_ts %llu, pic_num %u frame_num %u fields %s "
+ TP_printk("tgid = %u, fd = %u, "
+ "[%d]: reference_ts %llu, pic_num %u frame_num %u fields %s "
"top_field_order_cnt %d bottom_field_order_cnt %d flags %s",
+ __entry->tgid, __entry->fd,
__entry->i,
__entry->reference_ts,
__entry->pic_num,
@@ -1035,56 +1117,58 @@ DECLARE_EVENT_CLASS(v4l2_h264_dpb_entry_tmpl,
);
DEFINE_EVENT(v4l2_ctrl_h264_sps_tmpl, v4l2_ctrl_h264_sps,
- TP_PROTO(const struct v4l2_ctrl_h264_sps *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_sps *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_ctrl_h264_pps_tmpl, v4l2_ctrl_h264_pps,
- TP_PROTO(const struct v4l2_ctrl_h264_pps *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_pps *p),
+ TP_ARGS(tgid, fd, p)
);
DEFINE_EVENT(v4l2_ctrl_h264_scaling_matrix_tmpl, v4l2_ctrl_h264_scaling_matrix,
- TP_PROTO(const struct v4l2_ctrl_h264_scaling_matrix *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_scaling_matrix *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_ctrl_h264_pred_weights_tmpl, v4l2_ctrl_h264_pred_weights,
- TP_PROTO(const struct v4l2_ctrl_h264_pred_weights *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_pred_weights *p),
+ TP_ARGS(tgid, fd, p)
);
DEFINE_EVENT(v4l2_ctrl_h264_slice_params_tmpl, v4l2_ctrl_h264_slice_params,
- TP_PROTO(const struct v4l2_ctrl_h264_slice_params *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_slice_params *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_h264_reference_tmpl, v4l2_h264_ref_pic_list0,
- TP_PROTO(const struct v4l2_h264_reference *r, int i),
- TP_ARGS(r, i)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_h264_reference *r, int i),
+ TP_ARGS(tgid, fd, r, i)
);
DEFINE_EVENT(v4l2_h264_reference_tmpl, v4l2_h264_ref_pic_list1,
- TP_PROTO(const struct v4l2_h264_reference *r, int i),
- TP_ARGS(r, i)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_h264_reference *r, int i),
+ TP_ARGS(tgid, fd, r, i)
);
DEFINE_EVENT(v4l2_ctrl_h264_decode_params_tmpl, v4l2_ctrl_h264_decode_params,
- TP_PROTO(const struct v4l2_ctrl_h264_decode_params *d),
- TP_ARGS(d)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_h264_decode_params *d),
+ TP_ARGS(tgid, fd, d)
);
DEFINE_EVENT(v4l2_h264_dpb_entry_tmpl, v4l2_h264_dpb_entry,
- TP_PROTO(const struct v4l2_h264_dpb_entry *e, int i),
- TP_ARGS(e, i)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_h264_dpb_entry *e, int i),
+ TP_ARGS(tgid, fd, e, i)
);
/* HEVC controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field(__u8, video_parameter_set_id)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_sps *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u8, video_parameter_set_id)
__field(__u8, seq_parameter_set_id)
__field(__u16, pic_width_in_luma_samples)
__field(__u16, pic_height_in_luma_samples)
@@ -1109,7 +1193,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
__field(__u8, chroma_format_idc)
__field(__u8, sps_max_sub_layers_minus1)
__field(__u64, flags)),
- TP_fast_assign(__entry->video_parameter_set_id = s->video_parameter_set_id;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->video_parameter_set_id = s->video_parameter_set_id;
__entry->seq_parameter_set_id = s->seq_parameter_set_id;
__entry->pic_width_in_luma_samples = s->pic_width_in_luma_samples;
__entry->pic_height_in_luma_samples = s->pic_height_in_luma_samples;
@@ -1146,7 +1232,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
__entry->chroma_format_idc = s->chroma_format_idc;
__entry->sps_max_sub_layers_minus1 = s->sps_max_sub_layers_minus1;
__entry->flags = s->flags;),
- TP_printk("\nvideo_parameter_set_id %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nvideo_parameter_set_id %u\n"
"seq_parameter_set_id %u\n"
"pic_width_in_luma_samples %u\n"
"pic_height_in_luma_samples %u\n"
@@ -1171,6 +1258,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
"chroma_format_idc %u\n"
"sps_max_sub_layers_minus1 %u\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->video_parameter_set_id,
__entry->seq_parameter_set_id,
__entry->pic_width_in_luma_samples,
@@ -1213,9 +1301,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_sps_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field(__u8, pic_parameter_set_id)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_pps *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u8, pic_parameter_set_id)
__field(__u8, num_extra_slice_header_bits)
__field(__u8, num_ref_idx_l0_default_active_minus1)
__field(__u8, num_ref_idx_l1_default_active_minus1)
@@ -1231,7 +1321,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
__field(__s8, pps_tc_offset_div2)
__field(__u8, log2_parallel_merge_level_minus2)
__field(__u64, flags)),
- TP_fast_assign(__entry->pic_parameter_set_id = p->pic_parameter_set_id;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->pic_parameter_set_id = p->pic_parameter_set_id;
__entry->num_extra_slice_header_bits = p->num_extra_slice_header_bits;
__entry->num_ref_idx_l0_default_active_minus1 =
p->num_ref_idx_l0_default_active_minus1;
@@ -1252,7 +1344,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
__entry->log2_parallel_merge_level_minus2 =
p->log2_parallel_merge_level_minus2;
__entry->flags = p->flags;),
- TP_printk("\npic_parameter_set_id %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\npic_parameter_set_id %u\n"
"num_extra_slice_header_bits %u\n"
"num_ref_idx_l0_default_active_minus1 %u\n"
"num_ref_idx_l1_default_active_minus1 %u\n"
@@ -1268,6 +1361,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
"pps_tc_offset_div2 %d\n"
"log2_parallel_merge_level_minus2 %u\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->pic_parameter_set_id,
__entry->num_extra_slice_header_bits,
__entry->num_ref_idx_l0_default_active_minus1,
@@ -1322,9 +1416,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_pps_tmpl,
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field(__u32, bit_size)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_slice_params *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u32, bit_size)
__field(__u32, data_byte_offset)
__field(__u32, num_entry_point_offsets)
__field(__u8, nal_unit_type)
@@ -1351,7 +1447,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
__field(__u16, short_term_ref_pic_set_size)
__field(__u16, long_term_ref_pic_set_size)
__field(__u64, flags)),
- TP_fast_assign(__entry->bit_size = s->bit_size;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->bit_size = s->bit_size;
__entry->data_byte_offset = s->data_byte_offset;
__entry->num_entry_point_offsets = s->num_entry_point_offsets;
__entry->nal_unit_type = s->nal_unit_type;
@@ -1378,7 +1476,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
__entry->short_term_ref_pic_set_size = s->short_term_ref_pic_set_size;
__entry->long_term_ref_pic_set_size = s->long_term_ref_pic_set_size;
__entry->flags = s->flags;),
- TP_printk("\nbit_size %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nbit_size %u\n"
"data_byte_offset %u\n"
"num_entry_point_offsets %u\n"
"nal_unit_type %u\n"
@@ -1405,6 +1504,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
"short_term_ref_pic_set_size %u\n"
"long_term_ref_pic_set_size %u\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->bit_size,
__entry->data_byte_offset,
__entry->num_entry_point_offsets,
@@ -1454,9 +1554,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_slice_params_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
- TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__array(__s8, delta_luma_weight_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_hevc_pred_weight_table *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__s8, delta_luma_weight_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
__array(__s8, luma_offset_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
__array(__s8, delta_chroma_weight_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
__array(__s8, chroma_offset_l0, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
@@ -1466,7 +1568,9 @@ DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
__array(__s8, chroma_offset_l1, V4L2_HEVC_DPB_ENTRIES_NUM_MAX * 2)
__field(__u8, luma_log2_weight_denom)
__field(__s8, delta_chroma_log2_weight_denom)),
- TP_fast_assign(memcpy(__entry->delta_luma_weight_l0, p->delta_luma_weight_l0,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->delta_luma_weight_l0, p->delta_luma_weight_l0,
sizeof(__entry->delta_luma_weight_l0));
memcpy(__entry->luma_offset_l0, p->luma_offset_l0,
sizeof(__entry->luma_offset_l0));
@@ -1485,7 +1589,8 @@ DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
__entry->luma_log2_weight_denom = p->luma_log2_weight_denom;
__entry->delta_chroma_log2_weight_denom =
p->delta_chroma_log2_weight_denom;),
- TP_printk("\ndelta_luma_weight_l0 %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\ndelta_luma_weight_l0 %s\n"
"luma_offset_l0 %s\n"
"delta_chroma_weight_l0 {%s}\n"
"chroma_offset_l0 {%s}\n"
@@ -1495,6 +1600,7 @@ DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
"chroma_offset_l1 {%s}\n"
"luma_log2_weight_denom %d\n"
"delta_chroma_log2_weight_denom %d\n",
+ __entry->tgid, __entry->fd,
__print_array(__entry->delta_luma_weight_l0,
ARRAY_SIZE(__entry->delta_luma_weight_l0),
sizeof(__entry->delta_luma_weight_l0[0])),
@@ -1529,15 +1635,19 @@ DECLARE_EVENT_CLASS(v4l2_hevc_pred_weight_table_tmpl,
))
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__array(__u8, scaling_list_4x4, 6 * 16)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_scaling_matrix *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__u8, scaling_list_4x4, 6 * 16)
__array(__u8, scaling_list_8x8, 6 * 64)
__array(__u8, scaling_list_16x16, 6 * 64)
__array(__u8, scaling_list_32x32, 2 * 64)
__array(__u8, scaling_list_dc_coef_16x16, 6)
__array(__u8, scaling_list_dc_coef_32x32, 2)),
- TP_fast_assign(memcpy(__entry->scaling_list_4x4,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->scaling_list_4x4,
s->scaling_list_4x4, sizeof(__entry->scaling_list_4x4));
memcpy(__entry->scaling_list_8x8,
s->scaling_list_8x8, sizeof(__entry->scaling_list_8x8));
@@ -1551,12 +1661,14 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
memcpy(__entry->scaling_list_dc_coef_32x32,
s->scaling_list_dc_coef_32x32,
sizeof(__entry->scaling_list_dc_coef_32x32));),
- TP_printk("\nscaling_list_4x4 {%s}\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nscaling_list_4x4 {%s}\n"
"scaling_list_8x8 {%s}\n"
"scaling_list_16x16 {%s}\n"
"scaling_list_32x32 {%s}\n"
"scaling_list_dc_coef_16x16 %s\n"
"scaling_list_dc_coef_32x32 %s\n",
+ __entry->tgid, __entry->fd,
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
__entry->scaling_list_4x4,
sizeof(__entry->scaling_list_4x4),
@@ -1582,9 +1694,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_scaling_matrix_tmpl,
))
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
- TP_ARGS(d),
- TP_STRUCT__entry(__field(__s32, pic_order_cnt_val)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_decode_params *d),
+ TP_ARGS(tgid, fd, d),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__s32, pic_order_cnt_val)
__field(__u16, short_term_ref_pic_set_size)
__field(__u16, long_term_ref_pic_set_size)
__field(__u8, num_active_dpb_entries)
@@ -1595,7 +1709,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
__array(__u8, poc_st_curr_after, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
__array(__u8, poc_lt_curr, V4L2_HEVC_DPB_ENTRIES_NUM_MAX)
__field(__u64, flags)),
- TP_fast_assign(__entry->pic_order_cnt_val = d->pic_order_cnt_val;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->pic_order_cnt_val = d->pic_order_cnt_val;
__entry->short_term_ref_pic_set_size = d->short_term_ref_pic_set_size;
__entry->long_term_ref_pic_set_size = d->long_term_ref_pic_set_size;
__entry->num_active_dpb_entries = d->num_active_dpb_entries;
@@ -1608,7 +1724,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
sizeof(__entry->poc_st_curr_after));
memcpy(__entry->poc_lt_curr, d->poc_lt_curr, sizeof(__entry->poc_lt_curr));
__entry->flags = d->flags;),
- TP_printk("\npic_order_cnt_val %d\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\npic_order_cnt_val %d\n"
"short_term_ref_pic_set_size %u\n"
"long_term_ref_pic_set_size %u\n"
"num_active_dpb_entries %u\n"
@@ -1619,6 +1736,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
"poc_st_curr_after %s\n"
"poc_lt_curr %s\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__entry->pic_order_cnt_val,
__entry->short_term_ref_pic_set_size,
__entry->long_term_ref_pic_set_size,
@@ -1643,14 +1761,20 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_decode_params_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
- TP_ARGS(lt),
- TP_STRUCT__entry(__field(__u8, flags)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
+ TP_ARGS(tgid, fd, lt),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u8, flags)
__field(__u32, lt_ref_pic_poc_lsb_sps)),
- TP_fast_assign(__entry->flags = lt->flags;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->flags = lt->flags;
__entry->lt_ref_pic_poc_lsb_sps = lt->lt_ref_pic_poc_lsb_sps;),
- TP_printk("\nflags %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nflags %s\n"
"lt_ref_pic_poc_lsb_sps %x\n",
+ __entry->tgid, __entry->fd,
__print_flags(__entry->flags, "|",
{V4L2_HEVC_EXT_SPS_LT_RPS_FLAG_USED_LT, "USED_LT"}
),
@@ -1659,9 +1783,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
- TP_ARGS(st),
- TP_STRUCT__entry(__field(__u8, flags)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
+ TP_ARGS(tgid, fd, st),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u8, flags)
__field(__u8, delta_idx_minus1)
__field(__u8, delta_rps_sign)
__field(__u16, abs_delta_rps_minus1)
@@ -1671,7 +1797,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
__field(__u32, use_delta_flag)
__array(__u32, delta_poc_s0_minus1, 16)
__array(__u32, delta_poc_s1_minus1, 16)),
- TP_fast_assign(__entry->flags = st->flags;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->flags = st->flags;
__entry->delta_idx_minus1 = st->delta_idx_minus1;
__entry->delta_rps_sign = st->delta_rps_sign;
__entry->abs_delta_rps_minus1 = st->abs_delta_rps_minus1;
@@ -1683,7 +1811,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
sizeof(__entry->delta_poc_s0_minus1));
memcpy(__entry->delta_poc_s1_minus1, st->delta_poc_s1_minus1,
sizeof(__entry->delta_poc_s1_minus1));),
- TP_printk("\nflags %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nflags %s\n"
"delta_idx_minus1: %u\n"
"delta_rps_sign: %u\n"
"abs_delta_rps_minus1: %u\n"
@@ -1693,6 +1822,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
"use_delta_flag: %08x\n"
"delta_poc_s0_minus1: %s\n"
"delta_poc_s1_minus1: %s\n",
+ __entry->tgid, __entry->fd,
__print_flags(__entry->flags, "|",
{V4L2_HEVC_EXT_SPS_ST_RPS_FLAG_INTER_REF_PIC_SET_PRED, "INTER_REF_PIC_SET_PRED"}
),
@@ -1713,20 +1843,26 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_hevc_dpb_entry_tmpl,
- TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
- TP_ARGS(e),
- TP_STRUCT__entry(__field(__u64, timestamp)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_hevc_dpb_entry *e),
+ TP_ARGS(tgid, fd, e),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u64, timestamp)
__field(__u8, flags)
__field(__u8, field_pic)
__field(__s32, pic_order_cnt_val)),
- TP_fast_assign(__entry->timestamp = e->timestamp;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->timestamp = e->timestamp;
__entry->flags = e->flags;
__entry->field_pic = e->field_pic;
__entry->pic_order_cnt_val = e->pic_order_cnt_val;),
- TP_printk("\ntimestamp %llu\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\ntimestamp %llu\n"
"flags %s\n"
"field_pic %u\n"
"pic_order_cnt_val %d\n",
+ __entry->tgid, __entry->fd,
__entry->timestamp,
__print_flags(__entry->flags, "|",
{V4L2_HEVC_DPB_ENTRY_LONG_TERM_REFERENCE, "LONG_TERM_REFERENCE"}
@@ -1736,69 +1872,75 @@ DECLARE_EVENT_CLASS(v4l2_hevc_dpb_entry_tmpl,
))
DEFINE_EVENT(v4l2_ctrl_hevc_sps_tmpl, v4l2_ctrl_hevc_sps,
- TP_PROTO(const struct v4l2_ctrl_hevc_sps *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_sps *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_ctrl_hevc_pps_tmpl, v4l2_ctrl_hevc_pps,
- TP_PROTO(const struct v4l2_ctrl_hevc_pps *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_pps *p),
+ TP_ARGS(tgid, fd, p)
);
DEFINE_EVENT(v4l2_ctrl_hevc_slice_params_tmpl, v4l2_ctrl_hevc_slice_params,
- TP_PROTO(const struct v4l2_ctrl_hevc_slice_params *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_slice_params *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_hevc_pred_weight_table_tmpl, v4l2_hevc_pred_weight_table,
- TP_PROTO(const struct v4l2_hevc_pred_weight_table *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_hevc_pred_weight_table *p),
+ TP_ARGS(tgid, fd, p)
);
DEFINE_EVENT(v4l2_ctrl_hevc_scaling_matrix_tmpl, v4l2_ctrl_hevc_scaling_matrix,
- TP_PROTO(const struct v4l2_ctrl_hevc_scaling_matrix *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_scaling_matrix *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_ctrl_hevc_decode_params_tmpl, v4l2_ctrl_hevc_decode_params,
- TP_PROTO(const struct v4l2_ctrl_hevc_decode_params *d),
- TP_ARGS(d)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_decode_params *d),
+ TP_ARGS(tgid, fd, d)
);
DEFINE_EVENT(v4l2_ctrl_hevc_ext_sps_lt_rps_tmpl, v4l2_ctrl_hevc_ext_sps_lt_rps,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
- TP_ARGS(lt)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_ext_sps_lt_rps *lt),
+ TP_ARGS(tgid, fd, lt)
);
DEFINE_EVENT(v4l2_ctrl_hevc_ext_sps_st_rps_tmpl, v4l2_ctrl_hevc_ext_sps_st_rps,
- TP_PROTO(const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
- TP_ARGS(st)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_hevc_ext_sps_st_rps *st),
+ TP_ARGS(tgid, fd, st)
);
DEFINE_EVENT(v4l2_hevc_dpb_entry_tmpl, v4l2_hevc_dpb_entry,
- TP_PROTO(const struct v4l2_hevc_dpb_entry *e),
- TP_ARGS(e)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_hevc_dpb_entry *e),
+ TP_ARGS(tgid, fd, e)
);
/* MPEG2 controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_seq_tmpl,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
- TP_ARGS(s),
- TP_STRUCT__entry(__field(__u16, horizontal_size)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_mpeg2_sequence *s),
+ TP_ARGS(tgid, fd, s),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u16, horizontal_size)
__field(__u16, vertical_size)
__field(__u32, vbv_buffer_size)
__field(__u16, profile_and_level_indication)
__field(__u8, chroma_format)
__field(__u8, flags)),
- TP_fast_assign(__entry->horizontal_size = s->horizontal_size;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->horizontal_size = s->horizontal_size;
__entry->vertical_size = s->vertical_size;
__entry->vbv_buffer_size = s->vbv_buffer_size;
__entry->profile_and_level_indication = s->profile_and_level_indication;
__entry->chroma_format = s->chroma_format;
__entry->flags = s->flags;),
- TP_printk("\nhorizontal_size %u\nvertical_size %u\nvbv_buffer_size %u\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nhorizontal_size %u\nvertical_size %u\nvbv_buffer_size %u\n"
"profile_and_level_indication %u\nchroma_format %u\nflags %s\n",
+ __entry->tgid, __entry->fd,
__entry->horizontal_size,
__entry->vertical_size,
__entry->vbv_buffer_size,
@@ -1810,24 +1952,30 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_seq_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_pic_tmpl,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__field(__u64, backward_ref_ts)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_mpeg2_picture *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u64, backward_ref_ts)
__field(__u64, forward_ref_ts)
__field(__u32, flags)
__array(__u8, f_code, 4)
__field(__u8, picture_coding_type)
__field(__u8, picture_structure)
__field(__u8, intra_dc_precision)),
- TP_fast_assign(__entry->backward_ref_ts = p->backward_ref_ts;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->backward_ref_ts = p->backward_ref_ts;
__entry->forward_ref_ts = p->forward_ref_ts;
__entry->flags = p->flags;
memcpy(__entry->f_code, p->f_code, sizeof(__entry->f_code));
__entry->picture_coding_type = p->picture_coding_type;
__entry->picture_structure = p->picture_structure;
__entry->intra_dc_precision = p->intra_dc_precision;),
- TP_printk("\nbackward_ref_ts %llu\nforward_ref_ts %llu\nflags %s\nf_code {%s}\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nbackward_ref_ts %llu\nforward_ref_ts %llu\nflags %s\nf_code {%s}\n"
"picture_coding_type: %u\npicture_structure %u\nintra_dc_precision %u\n",
+ __entry->tgid, __entry->fd,
__entry->backward_ref_ts,
__entry->forward_ref_ts,
__print_flags(__entry->flags, "|",
@@ -1850,13 +1998,17 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_pic_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_quant_tmpl,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
- TP_ARGS(q),
- TP_STRUCT__entry(__array(__u8, intra_quantiser_matrix, 64)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_mpeg2_quantisation *q),
+ TP_ARGS(tgid, fd, q),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__u8, intra_quantiser_matrix, 64)
__array(__u8, non_intra_quantiser_matrix, 64)
__array(__u8, chroma_intra_quantiser_matrix, 64)
__array(__u8, chroma_non_intra_quantiser_matrix, 64)),
- TP_fast_assign(memcpy(__entry->intra_quantiser_matrix, q->intra_quantiser_matrix,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->intra_quantiser_matrix, q->intra_quantiser_matrix,
sizeof(__entry->intra_quantiser_matrix));
memcpy(__entry->non_intra_quantiser_matrix, q->non_intra_quantiser_matrix,
sizeof(__entry->non_intra_quantiser_matrix));
@@ -1866,8 +2018,10 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_quant_tmpl,
memcpy(__entry->chroma_non_intra_quantiser_matrix,
q->chroma_non_intra_quantiser_matrix,
sizeof(__entry->chroma_non_intra_quantiser_matrix));),
- TP_printk("\nintra_quantiser_matrix %s\nnon_intra_quantiser_matrix %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nintra_quantiser_matrix %s\nnon_intra_quantiser_matrix %s\n"
"chroma_intra_quantiser_matrix %s\nchroma_non_intra_quantiser_matrix %s\n",
+ __entry->tgid, __entry->fd,
__print_array(__entry->intra_quantiser_matrix,
ARRAY_SIZE(__entry->intra_quantiser_matrix),
sizeof(__entry->intra_quantiser_matrix[0])),
@@ -1884,30 +2038,34 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_mpeg2_quant_tmpl,
)
DEFINE_EVENT(v4l2_ctrl_mpeg2_seq_tmpl, v4l2_ctrl_mpeg2_sequence,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_sequence *s),
- TP_ARGS(s)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_mpeg2_sequence *s),
+ TP_ARGS(tgid, fd, s)
);
DEFINE_EVENT(v4l2_ctrl_mpeg2_pic_tmpl, v4l2_ctrl_mpeg2_picture,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_picture *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_mpeg2_picture *p),
+ TP_ARGS(tgid, fd, p)
);
DEFINE_EVENT(v4l2_ctrl_mpeg2_quant_tmpl, v4l2_ctrl_mpeg2_quantisation,
- TP_PROTO(const struct v4l2_ctrl_mpeg2_quantisation *q),
- TP_ARGS(q)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_mpeg2_quantisation *q),
+ TP_ARGS(tgid, fd, q)
);
/* VP8 controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__array(__u8, entropy_coeff_probs, 4 * 8 * 3 * V4L2_VP8_COEFF_PROB_CNT)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(tgid, fd, f),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__u8, entropy_coeff_probs, 4 * 8 * 3 * V4L2_VP8_COEFF_PROB_CNT)
__array(__u8, entropy_y_mode_probs, 4)
__array(__u8, entropy_uv_mode_probs, 3)
__array(__u8, entropy_mv_probs, 2 * 19)),
- TP_fast_assign(memcpy(__entry->entropy_coeff_probs, f->entropy.coeff_probs,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->entropy_coeff_probs, f->entropy.coeff_probs,
sizeof(__entry->entropy_coeff_probs));
memcpy(__entry->entropy_y_mode_probs, f->entropy.y_mode_probs,
sizeof(__entry->entropy_y_mode_probs));
@@ -1915,10 +2073,12 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
sizeof(__entry->entropy_uv_mode_probs));
memcpy(__entry->entropy_mv_probs, f->entropy.mv_probs,
sizeof(__entry->entropy_mv_probs));),
- TP_printk("\nentropy.coeff_probs {%s}\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nentropy.coeff_probs {%s}\n"
"entropy.y_mode_probs %s\n"
"entropy.uv_mode_probs %s\n"
"entropy.mv_probs {%s}",
+ __entry->tgid, __entry->fd,
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
__entry->entropy_coeff_probs,
sizeof(__entry->entropy_coeff_probs),
@@ -1937,9 +2097,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_entropy_tmpl,
)
DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__array(__s8, segment_quant_update, 4)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(tgid, fd, f),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__s8, segment_quant_update, 4)
__array(__s8, segment_lf_update, 4)
__array(__u8, segment_segment_probs, 3)
__field(__u32, segment_flags)
@@ -1974,7 +2136,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
__field(__u64, golden_frame_ts)
__field(__u64, alt_frame_ts)
__field(__u64, flags)),
- TP_fast_assign(memcpy(__entry->segment_quant_update, f->segment.quant_update,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->segment_quant_update, f->segment.quant_update,
sizeof(__entry->segment_quant_update));
memcpy(__entry->segment_lf_update, f->segment.lf_update,
sizeof(__entry->segment_lf_update));
@@ -2015,7 +2179,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
__entry->golden_frame_ts = f->golden_frame_ts;
__entry->alt_frame_ts = f->alt_frame_ts;
__entry->flags = f->flags;),
- TP_printk("\nsegment.quant_update %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nsegment.quant_update %s\n"
"segment.lf_update %s\n"
"segment.segment_probs %s\n"
"segment.flags %s\n"
@@ -2050,6 +2215,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
"golden_frame_ts %llu\n"
"alt_frame_ts %llu\n"
"flags %s",
+ __entry->tgid, __entry->fd,
__print_array(__entry->segment_quant_update,
ARRAY_SIZE(__entry->segment_quant_update),
sizeof(__entry->segment_quant_update[0])),
@@ -2114,21 +2280,23 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp8_frame_tmpl,
);
DEFINE_EVENT(v4l2_ctrl_vp8_frame_tmpl, v4l2_ctrl_vp8_frame,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(tgid, fd, f)
);
DEFINE_EVENT(v4l2_ctrl_vp8_entropy_tmpl, v4l2_ctrl_vp8_entropy,
- TP_PROTO(const struct v4l2_ctrl_vp8_frame *f),
- TP_ARGS(f)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp8_frame *f),
+ TP_ARGS(tgid, fd, f)
);
/* VP9 controls */
DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
- TP_ARGS(f),
- TP_STRUCT__entry(__array(__s8, lf_ref_deltas, 4)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp9_frame *f),
+ TP_ARGS(tgid, fd, f),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__s8, lf_ref_deltas, 4)
__array(__s8, lf_mode_deltas, 2)
__field(__u8, lf_level)
__field(__u8, lf_sharpness)
@@ -2161,7 +2329,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
__field(__u8, tile_cols_log2)
__field(__u8, tile_rows_log2)
__field(__u8, reference_mode)),
- TP_fast_assign(memcpy(__entry->lf_ref_deltas, f->lf.ref_deltas,
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->lf_ref_deltas, f->lf.ref_deltas,
sizeof(__entry->lf_ref_deltas));
memcpy(__entry->lf_mode_deltas, f->lf.mode_deltas,
sizeof(__entry->lf_mode_deltas));
@@ -2200,7 +2370,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
__entry->tile_cols_log2 = f->tile_cols_log2;
__entry->tile_rows_log2 = f->tile_rows_log2;
__entry->reference_mode = f->reference_mode;),
- TP_printk("\nlf.ref_deltas %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\nlf.ref_deltas %s\n"
"lf.mode_deltas %s\n"
"lf.level %u\n"
"lf.sharpness %u\n"
@@ -2233,6 +2404,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
"tile_cols_log2 %u\n"
"tile_rows_log_2 %u\n"
"reference_mode %s\n",
+ __entry->tgid, __entry->fd,
__print_array(__entry->lf_ref_deltas,
ARRAY_SIZE(__entry->lf_ref_deltas),
sizeof(__entry->lf_ref_deltas[0])),
@@ -2313,9 +2485,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_frame_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h),
- TP_STRUCT__entry(__field(__u8, tx_mode)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(tgid, fd, h),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __field(__u8, tx_mode)
__array(__u8, tx8, 2 * 1)
__array(__u8, tx16, 2 * 2)
__array(__u8, tx32, 2 * 3)
@@ -2329,7 +2503,9 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
__array(__u8, y_mode, 4 * 9)
__array(__u8, uv_mode, 10 * 9)
__array(__u8, partition, 16 * 3)),
- TP_fast_assign(__entry->tx_mode = h->tx_mode;
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ __entry->tx_mode = h->tx_mode;
memcpy(__entry->tx8, h->tx8, sizeof(__entry->tx8));
memcpy(__entry->tx16, h->tx16, sizeof(__entry->tx16));
memcpy(__entry->tx32, h->tx32, sizeof(__entry->tx32));
@@ -2344,7 +2520,8 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
memcpy(__entry->y_mode, h->y_mode, sizeof(__entry->y_mode));
memcpy(__entry->uv_mode, h->uv_mode, sizeof(__entry->uv_mode));
memcpy(__entry->partition, h->partition, sizeof(__entry->partition));),
- TP_printk("\ntx_mode %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\ntx_mode %s\n"
"tx8 {%s}\n"
"tx16 {%s}\n"
"tx32 {%s}\n"
@@ -2358,6 +2535,7 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
"y_mode {%s}\n"
"uv_mode {%s}\n"
"partition {%s}\n",
+ __entry->tgid, __entry->fd,
__print_symbolic(__entry->tx_mode,
{V4L2_VP9_TX_MODE_ONLY_4X4, "TX_MODE_ONLY_4X4"},
{V4L2_VP9_TX_MODE_ALLOW_8X8, "TX_MODE_ALLOW_8X8"},
@@ -2416,11 +2594,17 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_hdr_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_coef_tmpl,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h),
- TP_STRUCT__entry(__array(__u8, coef, 4 * 2 * 2 * 6 * 6 * 3)),
- TP_fast_assign(memcpy(__entry->coef, h->coef, sizeof(__entry->coef));),
- TP_printk("\n coef {%s}",
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(tgid, fd, h),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__u8, coef, 4 * 2 * 2 * 6 * 6 * 3)),
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->coef, h->coef, sizeof(__entry->coef));),
+ TP_printk("tgid = %u, fd = %u, "
+ "\n coef {%s}",
+ __entry->tgid, __entry->fd,
__print_hex_dump("", DUMP_PREFIX_NONE, 32, 1,
__entry->coef,
sizeof(__entry->coef),
@@ -2429,9 +2613,11 @@ DECLARE_EVENT_CLASS(v4l2_ctrl_vp9_compressed_coef_tmpl,
);
DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
- TP_PROTO(const struct v4l2_vp9_mv_probs *p),
- TP_ARGS(p),
- TP_STRUCT__entry(__array(__u8, joint, 3)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_vp9_mv_probs *p),
+ TP_ARGS(tgid, fd, p),
+ TP_STRUCT__entry(__field(u32, tgid)
+ __field(u32, fd)
+ __array(__u8, joint, 3)
__array(__u8, sign, 2)
__array(__u8, classes, 2 * 10)
__array(__u8, class0_bit, 2)
@@ -2440,7 +2626,9 @@ DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
__array(__u8, fr, 2 * 3)
__array(__u8, class0_hp, 2)
__array(__u8, hp, 2)),
- TP_fast_assign(memcpy(__entry->joint, p->joint, sizeof(__entry->joint));
+ TP_fast_assign(__entry->tgid = tgid;
+ __entry->fd = fd;
+ memcpy(__entry->joint, p->joint, sizeof(__entry->joint));
memcpy(__entry->sign, p->sign, sizeof(__entry->sign));
memcpy(__entry->classes, p->classes, sizeof(__entry->classes));
memcpy(__entry->class0_bit, p->class0_bit, sizeof(__entry->class0_bit));
@@ -2449,7 +2637,8 @@ DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
memcpy(__entry->fr, p->fr, sizeof(__entry->fr));
memcpy(__entry->class0_hp, p->class0_hp, sizeof(__entry->class0_hp));
memcpy(__entry->hp, p->hp, sizeof(__entry->hp));),
- TP_printk("\n joint %s\n"
+ TP_printk("tgid = %u, fd = %u, "
+ "\n joint %s\n"
"sign %s\n"
"classes {%s}\n"
"class0_bit %s\n"
@@ -2458,6 +2647,7 @@ DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
"fr {%s}\n"
"class0_hp %s\n"
"hp %s\n",
+ __entry->tgid, __entry->fd,
__print_array(__entry->joint,
ARRAY_SIZE(__entry->joint),
sizeof(__entry->joint[0])),
@@ -2493,24 +2683,24 @@ DECLARE_EVENT_CLASS(v4l2_vp9_mv_probs_tmpl,
);
DEFINE_EVENT(v4l2_ctrl_vp9_frame_tmpl, v4l2_ctrl_vp9_frame,
- TP_PROTO(const struct v4l2_ctrl_vp9_frame *f),
- TP_ARGS(f)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp9_frame *f),
+ TP_ARGS(tgid, fd, f)
);
DEFINE_EVENT(v4l2_ctrl_vp9_compressed_hdr_tmpl, v4l2_ctrl_vp9_compressed_hdr,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(tgid, fd, h)
);
DEFINE_EVENT(v4l2_ctrl_vp9_compressed_coef_tmpl, v4l2_ctrl_vp9_compressed_coeff,
- TP_PROTO(const struct v4l2_ctrl_vp9_compressed_hdr *h),
- TP_ARGS(h)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_ctrl_vp9_compressed_hdr *h),
+ TP_ARGS(tgid, fd, h)
);
DEFINE_EVENT(v4l2_vp9_mv_probs_tmpl, v4l2_vp9_mv_probs,
- TP_PROTO(const struct v4l2_vp9_mv_probs *p),
- TP_ARGS(p)
+ TP_PROTO(u32 tgid, u32 fd, const struct v4l2_vp9_mv_probs *p),
+ TP_ARGS(tgid, fd, p)
);
#endif /* if !defined(_TRACE_V4L2_CONTROLS_H_) || defined(TRACE_HEADER_MULTI_READ) */
--
2.54.0
^ permalink raw reply related
* [PATCH v2 5/9] media: Add missing types to v4l2_ctrl_ptr
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
The v4l2_ctrl_ptr union contains pointers for all control types, but
v4l2_ctrl_hevc_decode_params and v4l2_ctrl_hevc_scaling_matrix are missing.
Add them.
Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
---
include/media/v4l2-ctrls.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/include/media/v4l2-ctrls.h b/include/media/v4l2-ctrls.h
index 327976b14d50..a2b4c96a9a6f 100644
--- a/include/media/v4l2-ctrls.h
+++ b/include/media/v4l2-ctrls.h
@@ -49,6 +49,8 @@ struct video_device;
* @p_hevc_sps: Pointer to an HEVC sequence parameter set structure.
* @p_hevc_pps: Pointer to an HEVC picture parameter set structure.
* @p_hevc_slice_params: Pointer to an HEVC slice parameters structure.
+ * @p_hevc_decode_params: Pointer to an HEVC decode parameters structure.
+ * @p_hevc_scaling_matrix Pointer to an HEVC scaling matrix structure.
* @p_hdr10_cll: Pointer to an HDR10 Content Light Level structure.
* @p_hdr10_mastering: Pointer to an HDR10 Mastering Display structure.
* @p_area: Pointer to an area.
@@ -81,6 +83,8 @@ union v4l2_ctrl_ptr {
struct v4l2_ctrl_hevc_sps *p_hevc_sps;
struct v4l2_ctrl_hevc_pps *p_hevc_pps;
struct v4l2_ctrl_hevc_slice_params *p_hevc_slice_params;
+ struct v4l2_ctrl_hevc_decode_params *p_hevc_decode_params;
+ struct v4l2_ctrl_hevc_scaling_matrix *p_hevc_scaling_matrix;
struct v4l2_ctrl_vp9_compressed_hdr *p_vp9_compressed_hdr_probs;
struct v4l2_ctrl_vp9_frame *p_vp9_frame;
struct v4l2_ctrl_hdr10_cll_info *p_hdr10_cll;
--
2.54.0
^ permalink raw reply related
* [PATCH v2 6/9] media: Trace the stateless controls when set in v4l2-ctrls-core.c
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
Also remove the trace from visl as the generic v4l2-requests traces can
now be used instead.
It allows all stateless drivers to inherit traceability, with just a small
overhead when disabled in userspace.
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
---
drivers/media/test-drivers/visl/visl-dec.c | 74 -------------------
drivers/media/v4l2-core/v4l2-ctrls-api.c | 10 +++
drivers/media/v4l2-core/v4l2-ctrls-core.c | 114 +++++++++++++++++++++++++++++
include/media/v4l2-ctrls.h | 15 ++++
4 files changed, 139 insertions(+), 74 deletions(-)
diff --git a/drivers/media/test-drivers/visl/visl-dec.c b/drivers/media/test-drivers/visl/visl-dec.c
index 2a065a6249ad..9517830fb3e8 100644
--- a/drivers/media/test-drivers/visl/visl-dec.c
+++ b/drivers/media/test-drivers/visl/visl-dec.c
@@ -12,7 +12,6 @@
#include <linux/workqueue.h>
#include <media/v4l2-mem2mem.h>
#include <media/tpg/v4l2-tpg.h>
-#include <trace/events/v4l2_controls.h>
#define LAST_BUF_IDX (V4L2_AV1_REF_LAST_FRAME - V4L2_AV1_REF_LAST_FRAME)
#define LAST2_BUF_IDX (V4L2_AV1_REF_LAST2_FRAME - V4L2_AV1_REF_LAST_FRAME)
@@ -486,78 +485,6 @@ static void visl_tpg_fill(struct visl_ctx *ctx, struct visl_run *run)
}
}
-static void visl_trace_ctrls(struct visl_ctx *ctx, struct visl_run *run)
-{
- int i;
- struct v4l2_fh *fh = &ctx->fh;
-
- switch (ctx->current_codec) {
- default:
- case VISL_CODEC_NONE:
- break;
- case VISL_CODEC_FWHT:
- trace_v4l2_ctrl_fwht_params(fh->tgid, fh->fd, run->fwht.params);
- break;
- case VISL_CODEC_MPEG2:
- trace_v4l2_ctrl_mpeg2_sequence(fh->tgid, fh->fd, run->mpeg2.seq);
- trace_v4l2_ctrl_mpeg2_picture(fh->tgid, fh->fd, run->mpeg2.pic);
- trace_v4l2_ctrl_mpeg2_quantisation(fh->tgid, fh->fd, run->mpeg2.quant);
- break;
- case VISL_CODEC_VP8:
- trace_v4l2_ctrl_vp8_frame(fh->tgid, fh->fd, run->vp8.frame);
- trace_v4l2_ctrl_vp8_entropy(fh->tgid, fh->fd, run->vp8.frame);
- break;
- case VISL_CODEC_VP9:
- trace_v4l2_ctrl_vp9_frame(fh->tgid, fh->fd, run->vp9.frame);
- trace_v4l2_ctrl_vp9_compressed_hdr(fh->tgid, fh->fd, run->vp9.probs);
- trace_v4l2_ctrl_vp9_compressed_coeff(fh->tgid, fh->fd, run->vp9.probs);
- trace_v4l2_vp9_mv_probs(fh->tgid, fh->fd, &run->vp9.probs->mv);
- break;
- case VISL_CODEC_H264:
- trace_v4l2_ctrl_h264_sps(fh->tgid, fh->fd, run->h264.sps);
- trace_v4l2_ctrl_h264_pps(fh->tgid, fh->fd, run->h264.pps);
- trace_v4l2_ctrl_h264_scaling_matrix(fh->tgid, fh->fd, run->h264.sm);
- trace_v4l2_ctrl_h264_slice_params(fh->tgid, fh->fd, run->h264.spram);
-
- for (i = 0; i < ARRAY_SIZE(run->h264.spram->ref_pic_list0); i++)
- trace_v4l2_h264_ref_pic_list0(fh->tgid, fh->fd,
- &run->h264.spram->ref_pic_list0[i], i);
- for (i = 0; i < ARRAY_SIZE(run->h264.spram->ref_pic_list0); i++)
- trace_v4l2_h264_ref_pic_list1(fh->tgid, fh->fd,
- &run->h264.spram->ref_pic_list1[i], i);
-
- trace_v4l2_ctrl_h264_decode_params(fh->tgid, fh->fd, run->h264.dpram);
-
- for (i = 0; i < ARRAY_SIZE(run->h264.dpram->dpb); i++)
- trace_v4l2_h264_dpb_entry(fh->tgid, fh->fd, &run->h264.dpram->dpb[i], i);
-
- trace_v4l2_ctrl_h264_pred_weights(fh->tgid, fh->fd, run->h264.pwht);
- break;
- case VISL_CODEC_HEVC:
- trace_v4l2_ctrl_hevc_sps(fh->tgid, fh->fd, run->hevc.sps);
- trace_v4l2_ctrl_hevc_pps(fh->tgid, fh->fd, run->hevc.pps);
- trace_v4l2_ctrl_hevc_slice_params(fh->tgid, fh->fd, run->hevc.spram);
- trace_v4l2_ctrl_hevc_scaling_matrix(fh->tgid, fh->fd, run->hevc.sm);
- trace_v4l2_ctrl_hevc_decode_params(fh->tgid, fh->fd, run->hevc.dpram);
-
- for (i = 0; i < ARRAY_SIZE(run->hevc.dpram->dpb); i++)
- trace_v4l2_hevc_dpb_entry(fh->tgid, fh->fd, &run->hevc.dpram->dpb[i]);
-
-
- trace_v4l2_hevc_pred_weight_table(fh->tgid, fh->fd,
- &run->hevc.spram->pred_weight_table);
- trace_v4l2_ctrl_hevc_ext_sps_lt_rps(fh->tgid, fh->fd, run->hevc.rps_lt);
- trace_v4l2_ctrl_hevc_ext_sps_st_rps(fh->tgid, fh->fd, run->hevc.rps_st);
- break;
- case VISL_CODEC_AV1:
- trace_v4l2_ctrl_av1_sequence(fh->tgid, fh->fd, run->av1.seq);
- trace_v4l2_ctrl_av1_frame(fh->tgid, fh->fd, run->av1.frame);
- trace_v4l2_ctrl_av1_film_grain(fh->tgid, fh->fd, run->av1.grain);
- trace_v4l2_ctrl_av1_tile_group_entry(fh->tgid, fh->fd, run->av1.tge);
- break;
- }
-}
-
void visl_device_run(void *priv)
{
struct visl_ctx *ctx = priv;
@@ -634,7 +561,6 @@ void visl_device_run(void *priv)
run.dst->sequence, run.dst->vb2_buf.timestamp);
visl_tpg_fill(ctx, &run);
- visl_trace_ctrls(ctx, &run);
if (bitstream_trace_frame_start > -1 &&
run.dst->sequence >= bitstream_trace_frame_start &&
diff --git a/drivers/media/v4l2-core/v4l2-ctrls-api.c b/drivers/media/v4l2-core/v4l2-ctrls-api.c
index 93d8d4012d0f..c44578828b21 100644
--- a/drivers/media/v4l2-core/v4l2-ctrls-api.c
+++ b/drivers/media/v4l2-core/v4l2-ctrls-api.c
@@ -523,6 +523,12 @@ int v4l2_g_ext_ctrls(struct v4l2_ctrl_handler *hdl, struct video_device *vdev,
}
EXPORT_SYMBOL(v4l2_g_ext_ctrls);
+static void trace_ext_ctrl(struct v4l2_fh *fh, const struct v4l2_ctrl *ctrl)
+{
+ if (ctrl->type_ops->trace)
+ ctrl->type_ops->trace(fh, ctrl, ctrl->p_cur);
+}
+
/* Validate a new control */
static int validate_new(const struct v4l2_ctrl *ctrl, union v4l2_ctrl_ptr p_new)
{
@@ -711,6 +717,10 @@ int try_set_ext_ctrls_common(struct v4l2_fh *fh,
idx = helpers[idx].next;
} while (!ret && idx);
}
+
+ if (set)
+ trace_ext_ctrl(fh, master);
+
v4l2_ctrl_unlock(master);
}
diff --git a/drivers/media/v4l2-core/v4l2-ctrls-core.c b/drivers/media/v4l2-core/v4l2-ctrls-core.c
index 6b375720e395..d8a8dc7896c5 100644
--- a/drivers/media/v4l2-core/v4l2-ctrls-core.c
+++ b/drivers/media/v4l2-core/v4l2-ctrls-core.c
@@ -10,8 +10,11 @@
#include <linux/slab.h>
#include <media/v4l2-ctrls.h>
#include <media/v4l2-event.h>
+#include <media/v4l2-fh.h>
#include <media/v4l2-fwnode.h>
+#include <trace/events/v4l2_controls.h>
+
#include "v4l2-ctrls-priv.h"
static const union v4l2_ctrl_ptr ptr_null;
@@ -1462,12 +1465,123 @@ int v4l2_ctrl_type_op_validate(const struct v4l2_ctrl *ctrl,
}
EXPORT_SYMBOL(v4l2_ctrl_type_op_validate);
+void v4l2_ctrl_type_op_trace(const struct v4l2_fh *fh,
+ const struct v4l2_ctrl *ctrl, union v4l2_ctrl_ptr ptr)
+{
+ int i = 0;
+
+ switch ((u32)ctrl->type) {
+ case V4L2_CTRL_TYPE_FWHT_PARAMS:
+ trace_v4l2_ctrl_fwht_params(fh->tgid, fh->fd, ptr.p_fwht_params);
+ break;
+ case V4L2_CTRL_TYPE_MPEG2_SEQUENCE:
+ trace_v4l2_ctrl_mpeg2_sequence(fh->tgid, fh->fd, ptr.p_mpeg2_sequence);
+ break;
+ case V4L2_CTRL_TYPE_MPEG2_PICTURE:
+ trace_v4l2_ctrl_mpeg2_picture(fh->tgid, fh->fd, ptr.p_mpeg2_picture);
+ break;
+ case V4L2_CTRL_TYPE_MPEG2_QUANTISATION:
+ trace_v4l2_ctrl_mpeg2_quantisation(fh->tgid, fh->fd, ptr.p_mpeg2_quantisation);
+ break;
+ case V4L2_CTRL_TYPE_VP8_FRAME:
+ trace_v4l2_ctrl_vp8_frame(fh->tgid, fh->fd, ptr.p_vp8_frame);
+ trace_v4l2_ctrl_vp8_entropy(fh->tgid, fh->fd, ptr.p_vp8_frame);
+ break;
+ case V4L2_CTRL_TYPE_VP9_FRAME:
+ trace_v4l2_ctrl_vp9_frame(fh->tgid, fh->fd, ptr.p_vp9_frame);
+ break;
+ case V4L2_CTRL_TYPE_VP9_COMPRESSED_HDR:
+ trace_v4l2_ctrl_vp9_compressed_hdr(fh->tgid, fh->fd,
+ ptr.p_vp9_compressed_hdr_probs);
+ trace_v4l2_ctrl_vp9_compressed_coeff(fh->tgid, fh->fd,
+ ptr.p_vp9_compressed_hdr_probs);
+ trace_v4l2_vp9_mv_probs(fh->tgid, fh->fd, &ptr.p_vp9_compressed_hdr_probs->mv);
+ break;
+ case V4L2_CTRL_TYPE_H264_SPS:
+ trace_v4l2_ctrl_h264_sps(fh->tgid, fh->fd, ptr.p_h264_sps);
+ break;
+ case V4L2_CTRL_TYPE_H264_PPS:
+ trace_v4l2_ctrl_h264_pps(fh->tgid, fh->fd, ptr.p_h264_pps);
+ break;
+ case V4L2_CTRL_TYPE_H264_SCALING_MATRIX:
+ trace_v4l2_ctrl_h264_scaling_matrix(fh->tgid, fh->fd, ptr.p_h264_scaling_matrix);
+ break;
+ case V4L2_CTRL_TYPE_H264_SLICE_PARAMS:
+ {
+ struct v4l2_ctrl_h264_slice_params *sp = ptr.p_h264_slice_params;
+
+ trace_v4l2_ctrl_h264_slice_params(fh->tgid, fh->fd, sp);
+
+ for (i = 0; i < ARRAY_SIZE(sp->ref_pic_list0); i++)
+ trace_v4l2_h264_ref_pic_list0(fh->tgid, fh->fd, &sp->ref_pic_list0[i], i);
+ for (i = 0; i < ARRAY_SIZE(sp->ref_pic_list1); i++)
+ trace_v4l2_h264_ref_pic_list1(fh->tgid, fh->fd, &sp->ref_pic_list1[i], i);
+
+ break;
+ }
+ case V4L2_CTRL_TYPE_H264_DECODE_PARAMS:
+ {
+ struct v4l2_ctrl_h264_decode_params *dp = ptr.p_h264_decode_params;
+
+ trace_v4l2_ctrl_h264_decode_params(fh->tgid, fh->fd, dp);
+
+ for (i = 0; i < ARRAY_SIZE(dp->dpb); i++)
+ trace_v4l2_h264_dpb_entry(fh->tgid, fh->fd, &dp->dpb[i], i);
+
+ break;
+ }
+ case V4L2_CTRL_TYPE_H264_PRED_WEIGHTS:
+ trace_v4l2_ctrl_h264_pred_weights(fh->tgid, fh->fd, ptr.p_h264_pred_weights);
+ break;
+ case V4L2_CTRL_TYPE_HEVC_SPS:
+ trace_v4l2_ctrl_hevc_sps(fh->tgid, fh->fd, ptr.p_hevc_sps);
+ break;
+ case V4L2_CTRL_TYPE_HEVC_PPS:
+ trace_v4l2_ctrl_hevc_pps(fh->tgid, fh->fd, ptr.p_hevc_pps);
+ break;
+ case V4L2_CTRL_TYPE_HEVC_SLICE_PARAMS:
+ trace_v4l2_ctrl_hevc_slice_params(fh->tgid, fh->fd, ptr.p_hevc_slice_params);
+ trace_v4l2_hevc_pred_weight_table(fh->tgid, fh->fd,
+ &ptr.p_hevc_slice_params->pred_weight_table);
+ break;
+ case V4L2_CTRL_TYPE_HEVC_SCALING_MATRIX:
+ trace_v4l2_ctrl_hevc_scaling_matrix(fh->tgid, fh->fd, ptr.p_hevc_scaling_matrix);
+ break;
+ case V4L2_CTRL_TYPE_HEVC_DECODE_PARAMS:
+ {
+ struct v4l2_ctrl_hevc_decode_params *dp = ptr.p_hevc_decode_params;
+
+ trace_v4l2_ctrl_hevc_decode_params(fh->tgid, fh->fd, dp);
+
+ for (i = 0; i < ARRAY_SIZE(dp->dpb); i++)
+ trace_v4l2_hevc_dpb_entry(fh->tgid, fh->fd, &dp->dpb[i]);
+
+ break;
+ }
+ case V4L2_CTRL_TYPE_AV1_SEQUENCE:
+ trace_v4l2_ctrl_av1_sequence(fh->tgid, fh->fd, ptr.p_av1_sequence);
+ break;
+ case V4L2_CTRL_TYPE_AV1_FRAME:
+ trace_v4l2_ctrl_av1_frame(fh->tgid, fh->fd, ptr.p_av1_frame);
+ break;
+ case V4L2_CTRL_TYPE_AV1_FILM_GRAIN:
+ trace_v4l2_ctrl_av1_film_grain(fh->tgid, fh->fd, ptr.p_av1_film_grain);
+ break;
+ case V4L2_CTRL_TYPE_AV1_TILE_GROUP_ENTRY:
+ trace_v4l2_ctrl_av1_tile_group_entry(fh->tgid, fh->fd, ptr.p_av1_tile_group_entry);
+ break;
+ }
+
+}
+EXPORT_SYMBOL(v4l2_ctrl_type_op_trace);
+
static const struct v4l2_ctrl_type_ops std_type_ops = {
.equal = v4l2_ctrl_type_op_equal,
.init = v4l2_ctrl_type_op_init,
.minimum = v4l2_ctrl_type_op_minimum,
.maximum = v4l2_ctrl_type_op_maximum,
.log = v4l2_ctrl_type_op_log,
+ .trace = v4l2_ctrl_type_op_trace,
.validate = v4l2_ctrl_type_op_validate,
};
diff --git a/include/media/v4l2-ctrls.h b/include/media/v4l2-ctrls.h
index a2b4c96a9a6f..57c4bb999b7b 100644
--- a/include/media/v4l2-ctrls.h
+++ b/include/media/v4l2-ctrls.h
@@ -140,6 +140,7 @@ struct v4l2_ctrl_ops {
* @minimum: set the value to the minimum value of the control.
* @maximum: set the value to the maximum value of the control.
* @log: log the value.
+ * @trace: trace the value of the control with Ftrace.
* @validate: validate the value for ctrl->new_elems array elements.
* Return 0 on success and a negative value otherwise.
*/
@@ -153,6 +154,8 @@ struct v4l2_ctrl_type_ops {
void (*maximum)(const struct v4l2_ctrl *ctrl, u32 idx,
union v4l2_ctrl_ptr ptr);
void (*log)(const struct v4l2_ctrl *ctrl);
+ void (*trace)(const struct v4l2_fh *fh,
+ const struct v4l2_ctrl *ctrl, union v4l2_ctrl_ptr ptr);
int (*validate)(const struct v4l2_ctrl *ctrl, union v4l2_ctrl_ptr ptr);
};
@@ -1627,6 +1630,18 @@ void v4l2_ctrl_type_op_init(const struct v4l2_ctrl *ctrl, u32 from_idx,
*/
void v4l2_ctrl_type_op_log(const struct v4l2_ctrl *ctrl);
+/**
+ * v4l2_ctrl_type_op_trace - Default v4l2_ctrl_type_ops trace callback.
+ *
+ * @fh: The v4l2_fh of the current context.
+ * @ctrl: The v4l2_ctrl pointer.
+ * @ptr: The v4l2 control value.
+ *
+ * Return: void
+ */
+void v4l2_ctrl_type_op_trace(const struct v4l2_fh *fh,
+ const struct v4l2_ctrl *ctrl, union v4l2_ctrl_ptr ptr);
+
/**
* v4l2_ctrl_type_op_validate - Default v4l2_ctrl_type_ops validate callback.
*
--
2.54.0
^ permalink raw reply related
* [PATCH v2 7/9] media: Add stream on/off traces and run them in the ioctl
From: Detlev Casanova @ 2026-06-10 14:33 UTC (permalink / raw)
To: Daniel Almeida, Mauro Carvalho Chehab, Steven Rostedt,
Masami Hiramatsu, Mathieu Desnoyers, Nicolas Dufresne,
Benjamin Gaignard, Philipp Zabel, Heiko Stuebner
Cc: linux-kernel, linux-media, linux-trace-kernel, linux-rockchip,
linux-arm-kernel, kernel, Detlev Casanova
In-Reply-To: <20260610-v4l2-add-ftrace-v2-0-9756edf72ac1@collabora.com>
This will automatically add stream on/off tracing for all v4l2 drivers.
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
---
drivers/media/v4l2-core/v4l2-ioctl.c | 20 +++++++++++++++++--
include/trace/events/v4l2.h | 37 ++++++++++++++++++++++++++++++++++++
2 files changed, 55 insertions(+), 2 deletions(-)
diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c
index c8746a1637f5..b09489baff3e 100644
--- a/drivers/media/v4l2-core/v4l2-ioctl.c
+++ b/drivers/media/v4l2-core/v4l2-ioctl.c
@@ -1963,13 +1963,29 @@ static int v4l_try_fmt(const struct v4l2_ioctl_ops *ops, struct file *file,
static int v4l_streamon(const struct v4l2_ioctl_ops *ops, struct file *file,
void *arg)
{
- return ops->vidioc_streamon(file, NULL, *(unsigned int *)arg);
+ struct v4l2_fh *fh = file_to_v4l2_fh(file);
+ int err;
+
+ err = ops->vidioc_streamon(file, NULL, *(unsigned int *)arg);
+
+ if (!err)
+ trace_v4l2_streamon(fh->tgid, fh->fd);
+
+ return err;
}
static int v4l_streamoff(const struct v4l2_ioctl_ops *ops, struct file *file,
void *arg)
{
- return ops->vidioc_streamoff(file, NULL, *(unsigned int *)arg);
+ struct v4l2_fh *fh = file_to_v4l2_fh(file);
+ int err;
+
+ err = ops->vidioc_streamoff(file, NULL, *(unsigned int *)arg);
+
+ if (!err)
+ trace_v4l2_streamoff(fh->tgid, fh->fd);
+
+ return err;
}
static int v4l_g_tuner(const struct v4l2_ioctl_ops *ops, struct file *file,
diff --git a/include/trace/events/v4l2.h b/include/trace/events/v4l2.h
index 248bc09bfc99..e5b80aeecc30 100644
--- a/include/trace/events/v4l2.h
+++ b/include/trace/events/v4l2.h
@@ -262,6 +262,43 @@ DEFINE_EVENT(vb2_v4l2_event_class, vb2_v4l2_qbuf,
TP_ARGS(q, vb)
);
+
+/* Events for stream on/off.
+ *
+ * These events will be fired every time userspace starts or stops a stream.
+ * tgid and fd are used to identify the process that opened the video device.
+ *
+ * Note that this even can be fired multiple times for a given tgid/fd pair.
+ * E.g.: mem2mem drivers expect stream on/off on both output and capture queues.
+ */
+DECLARE_EVENT_CLASS(v4l2_stream_class,
+ TP_PROTO(u32 tgid, u32 fd),
+ TP_ARGS(tgid, fd),
+
+ TP_STRUCT__entry(
+ __field(u32, tgid)
+ __field(u32, fd)
+ ),
+
+ TP_fast_assign(
+ __entry->tgid = tgid;
+ __entry->fd = fd;
+ ),
+
+ TP_printk("tgid = %u, fd = %u",
+ __entry->tgid, __entry->fd)
+);
+
+DEFINE_EVENT(v4l2_stream_class, v4l2_streamon,
+ TP_PROTO(u32 tgid, u32 fd),
+ TP_ARGS(tgid, fd)
+);
+
+DEFINE_EVENT(v4l2_stream_class, v4l2_streamoff,
+ TP_PROTO(u32 tgid, u32 fd),
+ TP_ARGS(tgid, fd)
+);
+
#endif /* if !defined(_TRACE_V4L2_H) || defined(TRACE_HEADER_MULTI_READ) */
/* This part must be outside protection */
--
2.54.0
^ permalink raw reply related
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox