Re: [PATCH 2/2] x86_64 irq: Handle irqs pending in IRR during irqmigration.

From: Andrew Morton
Date: Fri Feb 02 2007 - 20:05:46 EST


On Fri, 02 Feb 2007 17:35:31 -0700
ebiederm@xxxxxxxxxxxx (Eric W. Biederman) wrote:

> When making the interrupt vectors per cpu I failed to handle a case
> during irq migration. If the same interrupt comes in while we are
> servicing the irq but before we migrate it the pending bit in the
> local apic IRR register will be set for that irq.
>
> After migrating the irq to another cpu and or vector the data
> structures will no longer be setup to handle this pending irq. Then as
> soon as we return from servicing the irq we just migrated we will get
> a nasty: "No irq handler for vector" message.
>
> Since we do not disable irqs for edge triggered interrupts except
> in the smallest possible window during migration I cannot avoid
> migrating an irq in the unlikely event that it becomes pending.
> This is because by the time the irq could no longer become pending
> I have already updated all of my data structures.
>
> Therefore this patch introduces an intermediate state that
> exists soley on the cpu where we are handling the irq during
> migration. The irq number is changed to negative in the
> vector_irq data structure.
>
> Once the migration operation is complete we know we will receive
> no more interrupts on this vector so the irq pending state for
> this irq will no longer be updated. If the irq is not pending and
> we are in the intermediate state we immediately free the vector,
> otherwise in we free the vector in do_IRQ when the pending irq
> arrives.

So is this a for-2.6.20 thing? The bug was present in 2.6.19, so
I assume it doesn't affect many people?
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/