diff options
Diffstat (limited to 'tools/perf/builtin-timechart.c')
-rw-r--r-- | tools/perf/builtin-timechart.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/tools/perf/builtin-timechart.c b/tools/perf/builtin-timechart.c index 58d737ec8f5e..3f45b8b24e3d 100644 --- a/tools/perf/builtin-timechart.c +++ b/tools/perf/builtin-timechart.c | |||
@@ -752,6 +752,7 @@ static void draw_wakeups(void) | |||
752 | we = wake_events; | 752 | we = wake_events; |
753 | while (we) { | 753 | while (we) { |
754 | int from = 0, to = 0; | 754 | int from = 0, to = 0; |
755 | char *task_from = NULL, *task_to = NULL; | ||
755 | 756 | ||
756 | /* locate the column of the waker and wakee */ | 757 | /* locate the column of the waker and wakee */ |
757 | p = all_data; | 758 | p = all_data; |
@@ -760,10 +761,14 @@ static void draw_wakeups(void) | |||
760 | c = p->all; | 761 | c = p->all; |
761 | while (c) { | 762 | while (c) { |
762 | if (c->Y && c->start_time <= we->time && c->end_time >= we->time) { | 763 | if (c->Y && c->start_time <= we->time && c->end_time >= we->time) { |
763 | if (p->pid == we->waker) | 764 | if (p->pid == we->waker) { |
764 | from = c->Y; | 765 | from = c->Y; |
765 | if (p->pid == we->wakee) | 766 | task_from = c->comm; |
767 | } | ||
768 | if (p->pid == we->wakee) { | ||
766 | to = c->Y; | 769 | to = c->Y; |
770 | task_to = c->comm; | ||
771 | } | ||
767 | } | 772 | } |
768 | c = c->next; | 773 | c = c->next; |
769 | } | 774 | } |
@@ -776,7 +781,7 @@ static void draw_wakeups(void) | |||
776 | else if (from && to && abs(from - to) == 1) | 781 | else if (from && to && abs(from - to) == 1) |
777 | svg_wakeline(we->time, from, to); | 782 | svg_wakeline(we->time, from, to); |
778 | else | 783 | else |
779 | svg_partial_wakeline(we->time, from, to); | 784 | svg_partial_wakeline(we->time, from, task_from, to, task_to); |
780 | we = we->next; | 785 | we = we->next; |
781 | } | 786 | } |
782 | } | 787 | } |