diff options
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/trace/trace_event_perf.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/kernel/trace/trace_event_perf.c b/kernel/trace/trace_event_perf.c index 26b8607a0abc..cb6f365016e4 100644 --- a/kernel/trace/trace_event_perf.c +++ b/kernel/trace/trace_event_perf.c | |||
@@ -157,6 +157,7 @@ __kprobes void *perf_trace_buf_prepare(int size, unsigned short type, | |||
157 | struct pt_regs *regs, int *rctxp) | 157 | struct pt_regs *regs, int *rctxp) |
158 | { | 158 | { |
159 | struct trace_entry *entry; | 159 | struct trace_entry *entry; |
160 | unsigned long flags; | ||
160 | char *raw_data; | 161 | char *raw_data; |
161 | int pc; | 162 | int pc; |
162 | 163 | ||
@@ -174,7 +175,8 @@ __kprobes void *perf_trace_buf_prepare(int size, unsigned short type, | |||
174 | memset(&raw_data[size - sizeof(u64)], 0, sizeof(u64)); | 175 | memset(&raw_data[size - sizeof(u64)], 0, sizeof(u64)); |
175 | 176 | ||
176 | entry = (struct trace_entry *)raw_data; | 177 | entry = (struct trace_entry *)raw_data; |
177 | tracing_generic_entry_update(entry, regs->flags, pc); | 178 | local_save_flags(flags); |
179 | tracing_generic_entry_update(entry, flags, pc); | ||
178 | entry->type = type; | 180 | entry->type = type; |
179 | 181 | ||
180 | return raw_data; | 182 | return raw_data; |