mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Robert Richter <robert.richter@amd.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: LKML <linux-kernel@vger.kernel.org>,
	oprofile-list <oprofile-list@lists.sourceforge.net>,
	Robert Richter <robert.richter@amd.com>
Subject: [PATCH 8/9] oprofile: remove #ifdef CONFIG_OPROFILE_IBS in non-ibs code
Date: Wed, 7 Jan 2009 23:45:24 +0100	[thread overview]
Message-ID: <1231368325-19246-9-git-send-email-robert.richter@amd.com> (raw)
In-Reply-To: <1231368325-19246-1-git-send-email-robert.richter@amd.com>

The ifdefs can be removed since the code is no longer ibs specific and
can be used for other purposes as well. IBS specific code is only in
op_model_amd.c.

Signed-off-by: Robert Richter <robert.richter@amd.com>
---
 drivers/oprofile/buffer_sync.c |    6 ------
 drivers/oprofile/cpu_buffer.c  |    4 ----
 2 files changed, 0 insertions(+), 10 deletions(-)

diff --git a/drivers/oprofile/buffer_sync.c b/drivers/oprofile/buffer_sync.c
index d692fdc..ac014cb 100644
--- a/drivers/oprofile/buffer_sync.c
+++ b/drivers/oprofile/buffer_sync.c
@@ -316,8 +316,6 @@ static void add_trace_begin(void)
 	add_event_entry(TRACE_BEGIN_CODE);
 }
 
-#ifdef CONFIG_OPROFILE_IBS
-
 static void add_data(struct op_entry *entry, struct mm_struct *mm)
 {
 	unsigned long code, pc, val;
@@ -355,8 +353,6 @@ static void add_data(struct op_entry *entry, struct mm_struct *mm)
 		add_event_entry(val);
 }
 
-#endif
-
 static inline void add_sample_entry(unsigned long offset, unsigned long event)
 {
 	add_event_entry(offset);
@@ -544,10 +540,8 @@ void sync_buffer(int cpu)
 					cookie = get_exec_dcookie(mm);
 				add_user_ctx_switch(new, cookie);
 			}
-#ifdef CONFIG_OPROFILE_IBS
 			if (op_cpu_buffer_get_size(&entry))
 				add_data(&entry, mm);
-#endif
 			continue;
 		}
 
diff --git a/drivers/oprofile/cpu_buffer.c b/drivers/oprofile/cpu_buffer.c
index ddba9d0..b846af6 100644
--- a/drivers/oprofile/cpu_buffer.c
+++ b/drivers/oprofile/cpu_buffer.c
@@ -361,8 +361,6 @@ void oprofile_add_sample(struct pt_regs * const regs, unsigned long event)
 	__oprofile_add_ext_sample(pc, regs, event, is_kernel);
 }
 
-#ifdef CONFIG_OPROFILE_IBS
-
 /*
  * Add samples with data to the ring buffer.
  *
@@ -397,8 +395,6 @@ fail:
 	cpu_buf->sample_lost_overflow++;
 }
 
-#endif
-
 void oprofile_add_pc(unsigned long pc, int is_kernel, unsigned long event)
 {
 	struct oprofile_cpu_buffer *cpu_buf = &__get_cpu_var(cpu_buffer);
-- 
1.6.0.1



  parent reply	other threads:[~2009-01-07 23:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-07 22:45 [PATCH 0/9] oprofile: implement support of samples with variable data size Robert Richter
2009-01-07 22:45 ` [PATCH 1/9] oprofile: add op_cpu_buffer_write_reserve() Robert Richter
2009-01-07 22:45 ` [PATCH 2/9] oprofile: modify op_cpu_buffer_read_entry() Robert Richter
2009-01-07 22:45 ` [PATCH 3/9] oprofile: rework implementation of cpu buffer events Robert Richter
2009-01-07 22:45 ` [PATCH 4/9] oprofile: add op_cpu_buffer_add_data() Robert Richter
2009-01-07 22:45 ` [PATCH 5/9] oprofile: add op_cpu_buffer_get_data() Robert Richter
2009-01-07 22:45 ` [PATCH 6/9] oprofile: use new data sample format for ibs Robert Richter
2009-01-07 22:45 ` [PATCH 7/9] ring_buffer: fix ring_buffer_event_length() Robert Richter
2009-01-07 22:45 ` Robert Richter [this message]
2009-01-07 22:45 ` [PATCH 9/9] oprofile: make new cpu buffer functions part of the api Robert Richter
2009-01-14 21:53 ` [PATCH 0/9] oprofile: implement support of samples with variable data size Maynard Johnson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1231368325-19246-9-git-send-email-robert.richter@amd.com \
    --to=robert.richter@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=oprofile-list@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome