diff options
-rw-r--r-- | kernel/trace/trace.c | 1 | ||||
-rw-r--r-- | kernel/trace/trace.h | 1 | ||||
-rw-r--r-- | kernel/trace/trace_output.c | 10 |
3 files changed, 9 insertions, 3 deletions
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index cb2b708e4ea7..7bdf8ba323ec 100644 --- a/kernel/trace/trace.c +++ b/kernel/trace/trace.c | |||
@@ -1664,6 +1664,7 @@ tracing_generic_entry_update(struct trace_entry *entry, unsigned long flags, | |||
1664 | #else | 1664 | #else |
1665 | TRACE_FLAG_IRQS_NOSUPPORT | | 1665 | TRACE_FLAG_IRQS_NOSUPPORT | |
1666 | #endif | 1666 | #endif |
1667 | ((pc & NMI_MASK ) ? TRACE_FLAG_NMI : 0) | | ||
1667 | ((pc & HARDIRQ_MASK) ? TRACE_FLAG_HARDIRQ : 0) | | 1668 | ((pc & HARDIRQ_MASK) ? TRACE_FLAG_HARDIRQ : 0) | |
1668 | ((pc & SOFTIRQ_MASK) ? TRACE_FLAG_SOFTIRQ : 0) | | 1669 | ((pc & SOFTIRQ_MASK) ? TRACE_FLAG_SOFTIRQ : 0) | |
1669 | (tif_need_resched() ? TRACE_FLAG_NEED_RESCHED : 0) | | 1670 | (tif_need_resched() ? TRACE_FLAG_NEED_RESCHED : 0) | |
diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h index 39588c23dd8b..3fff4adfd431 100644 --- a/kernel/trace/trace.h +++ b/kernel/trace/trace.h | |||
@@ -125,6 +125,7 @@ enum trace_flag_type { | |||
125 | TRACE_FLAG_HARDIRQ = 0x08, | 125 | TRACE_FLAG_HARDIRQ = 0x08, |
126 | TRACE_FLAG_SOFTIRQ = 0x10, | 126 | TRACE_FLAG_SOFTIRQ = 0x10, |
127 | TRACE_FLAG_PREEMPT_RESCHED = 0x20, | 127 | TRACE_FLAG_PREEMPT_RESCHED = 0x20, |
128 | TRACE_FLAG_NMI = 0x40, | ||
128 | }; | 129 | }; |
129 | 130 | ||
130 | #define TRACE_BUF_SIZE 1024 | 131 | #define TRACE_BUF_SIZE 1024 |
diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c index 282982195e09..0bb9cf2d53e6 100644 --- a/kernel/trace/trace_output.c +++ b/kernel/trace/trace_output.c | |||
@@ -389,7 +389,9 @@ int trace_print_lat_fmt(struct trace_seq *s, struct trace_entry *entry) | |||
389 | char irqs_off; | 389 | char irqs_off; |
390 | int hardirq; | 390 | int hardirq; |
391 | int softirq; | 391 | int softirq; |
392 | int nmi; | ||
392 | 393 | ||
394 | nmi = entry->flags & TRACE_FLAG_NMI; | ||
393 | hardirq = entry->flags & TRACE_FLAG_HARDIRQ; | 395 | hardirq = entry->flags & TRACE_FLAG_HARDIRQ; |
394 | softirq = entry->flags & TRACE_FLAG_SOFTIRQ; | 396 | softirq = entry->flags & TRACE_FLAG_SOFTIRQ; |
395 | 397 | ||
@@ -415,10 +417,12 @@ int trace_print_lat_fmt(struct trace_seq *s, struct trace_entry *entry) | |||
415 | } | 417 | } |
416 | 418 | ||
417 | hardsoft_irq = | 419 | hardsoft_irq = |
420 | (nmi && hardirq) ? 'Z' : | ||
421 | nmi ? 'z' : | ||
418 | (hardirq && softirq) ? 'H' : | 422 | (hardirq && softirq) ? 'H' : |
419 | hardirq ? 'h' : | 423 | hardirq ? 'h' : |
420 | softirq ? 's' : | 424 | softirq ? 's' : |
421 | '.'; | 425 | '.' ; |
422 | 426 | ||
423 | trace_seq_printf(s, "%c%c%c", | 427 | trace_seq_printf(s, "%c%c%c", |
424 | irqs_off, need_resched, hardsoft_irq); | 428 | irqs_off, need_resched, hardsoft_irq); |