All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shaohua Li <shaohua.li@intel.com>
To: lkml <linux-kernel@vger.kernel.org>
Cc: "Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>,
	"Raj, Ashok" <ashok.raj@intel.com>, akpm <akpm@osdl.org>
Subject: [PATCH] disable LAPIC completely for offline CPU
Date: Wed, 23 Nov 2005 23:07:58 -0800	[thread overview]
Message-ID: <1132816078.9686.12.camel@linux.site> (raw)

Disabling LAPIC timer isn't sufficient. In some situations, such as we
enabled NMI watchdog, there is still unexpected interrupt (such as NMI)
invoked in offline CPU. This also avoids offline CPU receives spurious
interrupt and anything similar.

Signed-off-by: Shaohua Li <shaohua.li@intel.com>
---

 linux-2.6.14-root/arch/i386/kernel/smpboot.c   |    3 +--
 linux-2.6.14-root/arch/x86_64/kernel/smpboot.c |    2 +-
 2 files changed, 2 insertions(+), 3 deletions(-)

diff -puN arch/x86_64/kernel/smpboot.c~cpuhp-disable-lapic arch/x86_64/kernel/smpboot.c
--- linux-2.6.14/arch/x86_64/kernel/smpboot.c~cpuhp-disable-lapic	2005-11-23 19:27:36.000000000 -0800
+++ linux-2.6.14-root/arch/x86_64/kernel/smpboot.c	2005-11-23 19:28:27.000000000 -0800
@@ -1181,7 +1181,7 @@ int __cpu_disable(void)
 	if (cpu == 0)
 		return -EBUSY;
 
-	disable_APIC_timer();
+	disable_local_APIC();
 
 	/*
 	 * HACK:
diff -puN arch/i386/kernel/smpboot.c~cpuhp-disable-lapic arch/i386/kernel/smpboot.c
--- linux-2.6.14/arch/i386/kernel/smpboot.c~cpuhp-disable-lapic	2005-11-23 19:28:38.000000000 -0800
+++ linux-2.6.14-root/arch/i386/kernel/smpboot.c	2005-11-23 19:30:05.000000000 -0800
@@ -1338,8 +1338,7 @@ int __cpu_disable(void)
 	if (cpu == 0)
 		return -EBUSY;
 
-	/* We enable the timer again on the exit path of the death loop */
-	disable_APIC_timer();
+	disable_local_APIC();
 	/* Allow any queued timer interrupts to get serviced */
 	local_irq_enable();
 	mdelay(1);
_



                 reply	other threads:[~2005-11-23 23:56 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1132816078.9686.12.camel@linux.site \
    --to=shaohua.li@intel.com \
    --cc=akpm@osdl.org \
    --cc=ashok.raj@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=venkatesh.pallipadi@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.