提交 b30a779d 编写于 作者: S Steven Rostedt (VMware)

tracing: Initialize upper and lower vars in pid_list_refill_irq()

The upper and lower variables are set as link lists to add into the sparse
array. If they are NULL, after the needed allocations are done, then there
is nothing to add. But they need to be initialized to NULL for this to
work.

Link: https://lore.kernel.org/all/221bc7ba-a475-1cb9-1bbe-730bb9c2d448@canonical.com/

Fixes: 8d6e9098 ("tracing: Create a sparse bitmask for pid filtering")
Reported-by: NColin Ian King <colin.king@canonical.com>
Signed-off-by: NSteven Rostedt (VMware) <rostedt@goodmis.org>
上级 8d6e9098
...@@ -333,8 +333,8 @@ static void pid_list_refill_irq(struct irq_work *iwork) ...@@ -333,8 +333,8 @@ static void pid_list_refill_irq(struct irq_work *iwork)
{ {
struct trace_pid_list *pid_list = container_of(iwork, struct trace_pid_list, struct trace_pid_list *pid_list = container_of(iwork, struct trace_pid_list,
refill_irqwork); refill_irqwork);
union upper_chunk *upper; union upper_chunk *upper = NULL;
union lower_chunk *lower; union lower_chunk *lower = NULL;
union upper_chunk **upper_next = &upper; union upper_chunk **upper_next = &upper;
union lower_chunk **lower_next = &lower; union lower_chunk **lower_next = &lower;
int upper_count; int upper_count;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册