From: Andi Kleen <ak@suse.de>
To: Jan Beulich <JBeulich@novell.com>
Cc: Andreas Kleen <ak@suse.de>,
linux-kernel@vger.kernel.org, discuss@x86-64.org
Subject: Re: [discuss] [PATCH] add and handle NMI_VECTOR
Date: Fri, 9 Sep 2005 02:20:45 +0200 [thread overview]
Message-ID: <20050909002045.GA19913@wotan.suse.de> (raw)
In-Reply-To: <43207DFC0200007800024543@emea1-mh.id2.novell.com>
On Thu, Sep 08, 2005 at 06:07:56PM +0200, Jan Beulich wrote:
> (Note: Patch also attached because the inline version is certain to get
> line wrapped.)
>
> Declare NMI_VECTOR and handle it in the IPI sending code.
The earlier consensus was to just rename KDB_VECTOR to NMI vector.
I added the following patch.
-Andi
Rename KDB_VECTOR to NMI_VECTOR
As a generic NMI IPI vector to be used by debuggers.
And clean up the ICR setup for that slightly (code is equivalent, but cleaner
now)
Signed-off-by: Andi Kleen <ak@suse.de>
Index: linux/include/asm-x86_64/hw_irq.h
===================================================================
--- linux.orig/include/asm-x86_64/hw_irq.h
+++ linux/include/asm-x86_64/hw_irq.h
@@ -52,7 +52,7 @@ struct hw_interrupt_type;
#define ERROR_APIC_VECTOR 0xfe
#define RESCHEDULE_VECTOR 0xfd
#define CALL_FUNCTION_VECTOR 0xfc
-#define KDB_VECTOR 0xfb /* reserved for KDB */
+#define NMI_VECTOR 0xfb /* IPI NMIs for debugging */
#define THERMAL_APIC_VECTOR 0xfa
/* 0xf9 free */
#define INVALIDATE_TLB_VECTOR_END 0xf8
Index: linux/include/asm-x86_64/ipi.h
===================================================================
--- linux.orig/include/asm-x86_64/ipi.h
+++ linux/include/asm-x86_64/ipi.h
@@ -29,11 +29,14 @@
* We use 'broadcast', CPU->CPU IPIs and self-IPIs too.
*/
-static inline unsigned int __prepare_ICR (unsigned int shortcut, int vector, unsigned int dest)
+static inline unsigned int
+__prepare_ICR (unsigned int shortcut, int vector, unsigned int dest)
{
- unsigned int icr = APIC_DM_FIXED | shortcut | vector | dest;
- if (vector == KDB_VECTOR)
- icr = (icr & (~APIC_VECTOR_MASK)) | APIC_DM_NMI;
+ unsigned int icr = shortcut | dest;
+ if (vector == NMI_VECTOR)
+ icr |= APIC_DM_DMI;
+ else
+ icr |= APIC_DM_FIXED | vector;
return icr;
}
next prev parent reply other threads:[~2005-09-09 0:20 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-09-08 16:07 [PATCH] add and handle NMI_VECTOR Jan Beulich
2005-09-09 0:20 ` Andi Kleen [this message]
2005-09-09 0:43 ` [discuss] [PATCH] add and handle NMI_VECTOR II Andi Kleen
2005-09-09 6:42 ` Jan Beulich
2005-09-09 6:55 ` Andi Kleen
2005-09-09 7:13 ` Jan Beulich
2005-09-09 7:14 ` Andi Kleen
2005-09-09 7:57 ` Jan Beulich
2005-09-09 7:58 ` Andi Kleen
2005-09-09 8:50 ` [discuss] [PATCH] add and handle NMI_VECTOR Andi Kleen
2005-09-09 9:14 ` Jan Beulich
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=20050909002045.GA19913@wotan.suse.de \
--to=ak@suse.de \
--cc=JBeulich@novell.com \
--cc=discuss@x86-64.org \
--cc=linux-kernel@vger.kernel.org \
/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