浏览代码

oprofile: remove backtrace code for ibs

This code is broken since a TRACE_BEGIN_CODE is never sent to the
daemon. The data becomes corrupt since the backtrace is interpreted as
ibs sample.

Signed-off-by: Robert Richter <robert.richter@amd.com>
Robert Richter 16 年之前
父节点
当前提交
8350c78734
共有 2 个文件被更改,包括 2 次插入10 次删除
  1. 0 2
      drivers/oprofile/buffer_sync.c
  2. 2 8
      drivers/oprofile/cpu_buffer.c

+ 0 - 2
drivers/oprofile/buffer_sync.c

@@ -557,11 +557,9 @@ void sync_buffer(int cpu)
 				break;
 #ifdef CONFIG_OPROFILE_IBS
 			case IBS_FETCH_BEGIN:
-				state = sb_bt_start;
 				add_ibs_begin(cpu, IBS_FETCH_CODE, mm);
 				break;
 			case IBS_OP_BEGIN:
-				state = sb_bt_start;
 				add_ibs_begin(cpu, IBS_OP_CODE, mm);
 				break;
 #endif

+ 2 - 8
drivers/oprofile/cpu_buffer.c

@@ -347,17 +347,11 @@ void oprofile_add_ibs_sample(struct pt_regs * const regs,
 		fail = fail || add_sample(cpu_buf, ibs_sample[10], ibs_sample[11]);
 	}
 
-	if (fail)
-		goto fail;
-
-	if (oprofile_backtrace_depth)
-		oprofile_ops.backtrace(regs, oprofile_backtrace_depth);
-
-	return;
+	if (!fail)
+		return;
 
 fail:
 	cpu_buf->sample_lost_overflow++;
-	return;
 }
 
 #endif