lkml.org 
[lkml]   [2012]   [Jan]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Lapic vector priorites
On Sun, 22 Jan 2012, john stultz wrote:

> I'm really not that familiar with the lapic code, but reading over some
> of the documentation I could find through searches, and then looking at
> the lapic vector layout in the kernel, I'm now a little curious.
>
> >From what I've read the irq priority is set by the vector, where 0x0 is
> the highest and 0xFF is the lowest.
>
> In irq_vectors.h I see:
> #define NMI_VECTOR 0x02
> #define MCE_VECTOR 0x12

Both these vectors are hardwired internally in the CPU and irrelevant to
the APIC interrupt priority levels as these apply to ordinary interrupts
only. For these the higher the vector value, the higher the priority (I
won't get into the gory details, my memory has already faded about that
and I'd have to resort to documentation to avoid confusion).

The MCE is actually a processor exception and as such does not go through
the APIC at all. It's either signalled internally by the CPU (to record
an internal malfunction) or via an external signal (to raise a bus error
or a similar event).

The NMI is the non-maskable interrupt and is driven by the local APIC on
a separate processor's internal line (back in the 1990s where discrete
local APICs were used this would actually be a separate board signal to
the CPU) and it's the CPU that gives this line the priority above an
ordinary interrupt that may be asserted at the same time. For an NMI the
CPU does not drive an INTA cycle (again, internally for modern processors)
on its bus which the local APIC would respond with an interrupt vector to.

I hope this helps.

Maciej


\
 
 \ /
  Last update: 2012-01-23 07:27    [W:0.045 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site