[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level al
From: |
Avi Kivity |
Subject: |
Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request |
Date: |
Mon, 10 Sep 2012 11:56:24 +0300 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120828 Thunderbird/15.0 |
On 09/10/2012 04:27 AM, Matthew Ogilvie wrote:
> Intel's definition of "edge triggered" means: "asserted with a
> low-to-high transition at the time an interrupt is registered and
> then kept high until the interrupt is served via one of the
> EOI mechanisms or goes away unhandled."
>
> So the only difference between edge triggered and level triggered
> is in the leading edge, with no difference in the trailing edge.
Hard to believe. So an edge while cpu interrupts are disabled is ignored?
>
> This bug manifested itself when the guest was Microport UNIX
> System V/386 v2.1 (ca. 1987), because it would sometimes mask
> off IRQ14 in the slave IMR after it had already been asserted.
> The master would still try to deliver an interrupt even though
> IRQ2 had dropped again, resulting in a spurious interupt
> (IRQ15) and a panicked kernel.
This is something else. It means that setting an edge must happen after
IMR is cleared to be picked up. But this is not what the patch is doing.
>
> Signed-off-by: Matthew Ogilvie <address@hidden>
> ---
>
> If you missed the previous thread about this, see
> http://www.mail-archive.com/address@hidden/msg129071.html
>
> hw/i8259.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/hw/i8259.c b/hw/i8259.c
> index 6587666..c011787 100644
> --- a/hw/i8259.c
> +++ b/hw/i8259.c
> @@ -157,6 +157,7 @@ static void pic_set_irq(void *opaque, int irq, int level)
> }
> s->last_irr |= mask;
> } else {
> + s->irr &= ~mask;
> s->last_irr &= ~mask;
> }
> }
>
--
error compiling committee.c: too many arguments to function
- [Qemu-devel] [PATCH v5 0/6] Running Microport UNIX (ca 1987), Matthew Ogilvie, 2012/09/09
- [Qemu-devel] [PATCH v5 1/6] fix some debug printf format strings, Matthew Ogilvie, 2012/09/09
- [Qemu-devel] [PATCH v5 3/6] qemu-options.hx: mention retrace= VGA option, Matthew Ogilvie, 2012/09/09
- [Qemu-devel] [PATCH v5 2/6] vl: fix -hdachs/-hda argument order parsing issues, Matthew Ogilvie, 2012/09/09
- [Qemu-devel] [PATCH v5 4/6] vga: add some optional CGA compatibility hacks, Matthew Ogilvie, 2012/09/09
- [Qemu-devel] [PATCH v5 6/6] i8259: refactor pic_set_irq level logic, Matthew Ogilvie, 2012/09/09
- [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Matthew Ogilvie, 2012/09/09
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request,
Avi Kivity <=
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Jan Kiszka, 2012/09/10
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Avi Kivity, 2012/09/10
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Jan Kiszka, 2012/09/10
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Maciej W. Rozycki, 2012/09/10
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Avi Kivity, 2012/09/11
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Matthew Ogilvie, 2012/09/11
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Jan Kiszka, 2012/09/11
- Re: [Qemu-devel] [PATCH v5 5/6] i8259: fix so that dropping IRQ level always clears the interrupt request, Avi Kivity, 2012/09/11