From 3967e93e063d7ee608f465cbccb65abb518e9d33 Mon Sep 17 00:00:00 2001 From: Robert Richter Date: Tue, 30 Dec 2008 05:10:58 +0100 Subject: [PATCH] oprofile: simplify add_sample() in cpu_buffer.c Signed-off-by: Robert Richter --- drivers/oprofile/cpu_buffer.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/oprofile/cpu_buffer.c b/drivers/oprofile/cpu_buffer.c index 435bd6e08d5..d92f0020502 100644 --- a/drivers/oprofile/cpu_buffer.c +++ b/drivers/oprofile/cpu_buffer.c @@ -203,11 +203,7 @@ add_sample(struct oprofile_cpu_buffer *cpu_buf, entry.sample->eip = pc; entry.sample->event = event; - ret = op_cpu_buffer_write_commit(&entry); - if (ret) - return ret; - - return 0; + return op_cpu_buffer_write_commit(&entry); } static inline int -- 2.41.1