diff options
| -rw-r--r-- | trace-graph.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/trace-graph.c b/trace-graph.c index 4e91fe8..7225880 100644 --- a/trace-graph.c +++ b/trace-graph.c | |||
| @@ -1041,9 +1041,11 @@ int trace_graph_check_sched_wakeup(struct graph_info *ginfo, | |||
| 1041 | 1041 | ||
| 1042 | if (id == ginfo->event_wakeup_id) { | 1042 | if (id == ginfo->event_wakeup_id) { |
| 1043 | /* We only want those that actually woke up the task */ | 1043 | /* We only want those that actually woke up the task */ |
| 1044 | pevent_read_number_field(ginfo->wakeup_success_field, record->data, &val); | 1044 | if (ginfo->wakeup_success_field) { |
| 1045 | if (!val) | 1045 | pevent_read_number_field(ginfo->wakeup_success_field, record->data, &val); |
| 1046 | return 0; | 1046 | if (!val) |
| 1047 | return 0; | ||
| 1048 | } | ||
| 1047 | pevent_read_number_field(ginfo->wakeup_pid_field, record->data, &val); | 1049 | pevent_read_number_field(ginfo->wakeup_pid_field, record->data, &val); |
| 1048 | if (pid) | 1050 | if (pid) |
| 1049 | *pid = val; | 1051 | *pid = val; |
| @@ -1052,9 +1054,11 @@ int trace_graph_check_sched_wakeup(struct graph_info *ginfo, | |||
| 1052 | 1054 | ||
| 1053 | if (id == ginfo->event_wakeup_new_id) { | 1055 | if (id == ginfo->event_wakeup_new_id) { |
| 1054 | /* We only want those that actually woke up the task */ | 1056 | /* We only want those that actually woke up the task */ |
| 1055 | pevent_read_number_field(ginfo->wakeup_new_success_field, record->data, &val); | 1057 | if (ginfo->wakeup_new_success_field) { |
| 1056 | if (!val) | 1058 | pevent_read_number_field(ginfo->wakeup_new_success_field, record->data, &val); |
| 1057 | return 0; | 1059 | if (!val) |
| 1060 | return 0; | ||
| 1061 | } | ||
| 1058 | pevent_read_number_field(ginfo->wakeup_new_pid_field, record->data, &val); | 1062 | pevent_read_number_field(ginfo->wakeup_new_pid_field, record->data, &val); |
| 1059 | if (pid) | 1063 | if (pid) |
| 1060 | *pid = val; | 1064 | *pid = val; |
