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: Andi Kleen <andi@firstfloor.org>,
	LKML <linux-kernel@vger.kernel.org>,
	oprofile-list <oprofile-list@lists.sourceforge.net>,
	Robert Richter <robert.richter@amd.com>
Subject: [PATCH 2/7] oprofile/x86: remove CONFIG_SMP macros
Date: Thu, 6 May 2010 15:26:09 +0200	[thread overview]
Message-ID: <1273152374-9392-3-git-send-email-robert.richter@amd.com> (raw)
In-Reply-To: <1273152374-9392-1-git-send-email-robert.richter@amd.com>

CPU notifier register functions also exist if CONFIG_SMP is
disabled. This change is part of hotplug code rework and also
necessary for later patches.

Cc: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Robert Richter <robert.richter@amd.com>
---
 arch/x86/oprofile/nmi_int.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/arch/x86/oprofile/nmi_int.c b/arch/x86/oprofile/nmi_int.c
index 2458204..c5df8ee 100644
--- a/arch/x86/oprofile/nmi_int.c
+++ b/arch/x86/oprofile/nmi_int.c
@@ -471,7 +471,6 @@ static int nmi_create_files(struct super_block *sb, struct dentry *root)
 	return 0;
 }
 
-#ifdef CONFIG_SMP
 static int oprofile_cpu_notifier(struct notifier_block *b, unsigned long action,
 				 void *data)
 {
@@ -491,7 +490,6 @@ static int oprofile_cpu_notifier(struct notifier_block *b, unsigned long action,
 static struct notifier_block oprofile_cpu_nb = {
 	.notifier_call = oprofile_cpu_notifier
 };
-#endif
 
 #ifdef CONFIG_PM
 
@@ -701,9 +699,8 @@ int __init op_nmi_init(struct oprofile_operations *ops)
 		return -ENODEV;
 	}
 
-#ifdef CONFIG_SMP
 	register_cpu_notifier(&oprofile_cpu_nb);
-#endif
+
 	/* default values, can be overwritten by model */
 	ops->create_files	= nmi_create_files;
 	ops->setup		= nmi_setup;
@@ -732,9 +729,7 @@ void op_nmi_exit(void)
 {
 	if (using_nmi) {
 		exit_sysfs();
-#ifdef CONFIG_SMP
 		unregister_cpu_notifier(&oprofile_cpu_nb);
-#endif
 	}
 	if (model->exit)
 		model->exit();
-- 
1.7.0.3



  parent reply	other threads:[~2010-05-06 15:23 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-06 13:26 [PATCH 0/7] oprofile/x86: fix cpu hotplug Robert Richter
2010-05-06 13:26 ` [PATCH 1/7] oprofile/x86: fix uninitialized counter usage during " Robert Richter
2010-05-06 13:26 ` Robert Richter [this message]
2010-05-06 13:26 ` [PATCH 3/7] oprofile/x86: protect cpu hotplug sections Robert Richter
2010-05-06 13:26 ` [PATCH 4/7] oprofile/x86: stop disabled counters in nmi handler Robert Richter
2010-05-06 13:26 ` [PATCH 5/7] oprofile/x86: reordering some functions Robert Richter
2010-05-06 13:26 ` [PATCH 6/7] oprofile/x86: notify cpus only when daemon is running Robert Richter
2010-05-06 13:26 ` [PATCH 7/7] oprofile/x86: make AMD IBS hotplug capable Robert Richter
2010-05-10 10:33 ` [GIT PULL] oprofile hotplug fixes for x86 Robert Richter
2010-05-10 11:14   ` Ingo Molnar

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=1273152374-9392-3-git-send-email-robert.richter@amd.com \
    --to=robert.richter@amd.com \
    --cc=andi@firstfloor.org \
    --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