diff options
Diffstat (limited to 'kernel/trace/trace_output.c')
-rw-r--r-- | kernel/trace/trace_output.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c index 859fae6b1825..df611a0e76c5 100644 --- a/kernel/trace/trace_output.c +++ b/kernel/trace/trace_output.c | |||
@@ -652,6 +652,8 @@ int trace_print_lat_context(struct trace_iterator *iter) | |||
652 | { | 652 | { |
653 | u64 next_ts; | 653 | u64 next_ts; |
654 | int ret; | 654 | int ret; |
655 | /* trace_find_next_entry will reset ent_size */ | ||
656 | int ent_size = iter->ent_size; | ||
655 | struct trace_seq *s = &iter->seq; | 657 | struct trace_seq *s = &iter->seq; |
656 | struct trace_entry *entry = iter->ent, | 658 | struct trace_entry *entry = iter->ent, |
657 | *next_entry = trace_find_next_entry(iter, NULL, | 659 | *next_entry = trace_find_next_entry(iter, NULL, |
@@ -660,6 +662,9 @@ int trace_print_lat_context(struct trace_iterator *iter) | |||
660 | unsigned long abs_usecs = ns2usecs(iter->ts - iter->tr->time_start); | 662 | unsigned long abs_usecs = ns2usecs(iter->ts - iter->tr->time_start); |
661 | unsigned long rel_usecs; | 663 | unsigned long rel_usecs; |
662 | 664 | ||
665 | /* Restore the original ent_size */ | ||
666 | iter->ent_size = ent_size; | ||
667 | |||
663 | if (!next_entry) | 668 | if (!next_entry) |
664 | next_ts = iter->ts; | 669 | next_ts = iter->ts; |
665 | rel_usecs = ns2usecs(next_ts - iter->ts); | 670 | rel_usecs = ns2usecs(next_ts - iter->ts); |