History

Merge tag 'trace-v4.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace

Pull tracing fixes from Steven Rostedt: "This contains a few fixes and a clean up. - a bad merge caused an "endif" to go in the wrong place in scripts/Makefile.build - softirq tracing fix for tracing that corrupts lockdep and causes a false splat - histogram documentation typo fixes - fix a bad memory reference when passing in no filter to the filter code - simplify code by using the swap macro instead of open coding the swap" * tag 'trace-v4.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace: tracing: Fix SKIP_STACK_VALIDATION=1 build due to bad merge with -mrecord-mcount tracing: Fix some errors in histogram documentation tracing: Use swap macro in update_max_tr softirq: Reorder trace_softirqs_on to prevent lockdep splat tracing: Check for no filter when processing event filters

Linus Torvalds committed 8 years ago

Commit 81f9c4e2 parents 5e22048 ed7d40b5 files · +28 −19Browse files

Showing the changes to kernel (3 of 5 files). Show all

Unified · Split

3 files
  1. kernel/softirq.c +5 −1
  2. kernel/trace/trace.c +1 −5
  3. kernel/trace/trace_events_filter.c +9 −1
kernel/softirq.c+5−1
@@ -139,9 +139,13 @@ static void __local_bh_enable(unsigned int cnt) · 138 unmodified lines
139{139{
140 lockdep_assert_irqs_disabled();140 lockdep_assert_irqs_disabled();
141 141
142 if (preempt_count() == cnt)
143 trace_preempt_on(CALLER_ADDR0, get_lock_parent_ip());
144
142 if (softirq_count() == (cnt & SOFTIRQ_MASK))145 if (softirq_count() == (cnt & SOFTIRQ_MASK))
143 trace_softirqs_on(_RET_IP_);146 trace_softirqs_on(_RET_IP_);
144 preempt_count_sub(cnt);147
148 __preempt_count_sub(cnt);
145}149}
146 150
147/*151/*
kernel/trace/trace.c+1−5
@@ -1360,8 +1360,6 @@ __update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu) · 1359 unmodified lines
1360void1360void
1361update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu)1361update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu)
1362{1362{
1363 struct ring_buffer *buf;
1364
1365 if (tr->stop_count)1363 if (tr->stop_count)
1366 return;1364 return;
1367 1365
@@ -1375,9 +1373,7 @@ update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu) · 7 unmodified lines
1375 1373
1376 arch_spin_lock(&tr->max_lock);1374 arch_spin_lock(&tr->max_lock);
1377 1375
1378 buf = tr->trace_buffer.buffer;1376 swap(tr->trace_buffer.buffer, tr->max_buffer.buffer);
1379 tr->trace_buffer.buffer = tr->max_buffer.buffer;
1380 tr->max_buffer.buffer = buf;
1381 1377
1382 __update_max_tr(tr, tsk, cpu);1378 __update_max_tr(tr, tsk, cpu);
1383 arch_spin_unlock(&tr->max_lock);1379 arch_spin_unlock(&tr->max_lock);
kernel/trace/trace_events_filter.c+9−1
@@ -78,7 +78,8 @@ static const char * ops[] = { OPS }; · 77 unmodified lines
78 C(TOO_MANY_PREDS, "Too many terms in predicate expression"), \78 C(TOO_MANY_PREDS, "Too many terms in predicate expression"), \
79 C(INVALID_FILTER, "Meaningless filter expression"), \79 C(INVALID_FILTER, "Meaningless filter expression"), \
80 C(IP_FIELD_ONLY, "Only 'ip' field is supported for function trace"), \80 C(IP_FIELD_ONLY, "Only 'ip' field is supported for function trace"), \
81 C(INVALID_VALUE, "Invalid value (did you forget quotes)?"),81 C(INVALID_VALUE, "Invalid value (did you forget quotes)?"), \
82 C(NO_FILTER, "No filter found"),
82 83
83#undef C84#undef C
84#define C(a, b) FILT_ERR_##a85#define C(a, b) FILT_ERR_##a
@@ -550,6 +551,13 @@ predicate_parse(const char *str, int nr_parens, int nr_preds, · 465 unmodified lines
550 goto out_free;551 goto out_free;
551 }552 }
552 553
554 if (!N) {
555 /* No program? */
556 ret = -EINVAL;
557 parse_error(pe, FILT_ERR_NO_FILTER, ptr - str);
558 goto out_free;
559 }
560
553 prog[N].pred = NULL; /* #13 */561 prog[N].pred = NULL; /* #13 */
554 prog[N].target = 1; /* TRUE */562 prog[N].target = 1; /* TRUE */
555 prog[N+1].pred = NULL;563 prog[N+1].pred = NULL;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t