[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 19/26] q35: Fix non-PCI IRQ processing in ich
From: |
Michael S. Tsirkin |
Subject: |
Re: [Qemu-devel] [PATCH v3 19/26] q35: Fix non-PCI IRQ processing in ich9_lpc_update_apic |
Date: |
Mon, 22 Oct 2012 16:04:16 +0200 |
On Fri, Oct 19, 2012 at 04:43:38PM -0400, Jason Baron wrote:
> From: Jan Kiszka <address@hidden>
>
> Avoid passing a non-PCI IRQ to ich9_gsi_to_pirq. It's wrong and triggers
> an assertion.
>
> Reviewed-by: Paolo Bonzini <address@hidden>
> Signed-off-by: Jan Kiszka <address@hidden>
> Signed-off-by: Jason Baron <address@hidden>
Thanks, applied.
> ---
> hw/lpc_ich9.c | 6 ++++--
> 1 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/hw/lpc_ich9.c b/hw/lpc_ich9.c
> index d9fd9de..a47d7a9 100644
> --- a/hw/lpc_ich9.c
> +++ b/hw/lpc_ich9.c
> @@ -264,9 +264,11 @@ static int ich9_gsi_to_pirq(int gsi)
>
> static void ich9_lpc_update_apic(ICH9LPCState *lpc, int gsi)
> {
> - int level;
> + int level = 0;
>
> - level = pci_bus_get_irq_level(lpc->d.bus, ich9_gsi_to_pirq(gsi));
> + if (gsi >= ICH9_LPC_PIC_NUM_PINS) {
> + level |= pci_bus_get_irq_level(lpc->d.bus, ich9_gsi_to_pirq(gsi));
> + }
> if (gsi == ich9_lpc_sci_irq(lpc)) {
> level |= lpc->sci_level;
> }
> --
> 1.7.1
- Re: [Qemu-devel] [PATCH v3 25/26] q35: fill in usb pci slots with -usb, (continued)
- [Qemu-devel] [PATCH v3 15/26] q35: Introduce q35 pc based chipset emulator, Jason Baron, 2012/10/19
- [Qemu-devel] [PATCH v3 21/26] q35: Add kvmclock support, Jason Baron, 2012/10/19
- [Qemu-devel] [PATCH v3 26/26] ich9: add support pci assignment, Jason Baron, 2012/10/19
- [Qemu-devel] [PATCH v3 20/26] q35: smbus: Remove PCI_STATUS_SIG_SYSTEM_ERROR and PCI_STATUS_DETECTED_PARITY from w1cmask, Jason Baron, 2012/10/19
- [Qemu-devel] [PATCH v3 17/26] Add i21154 bridge chip., Jason Baron, 2012/10/19
- [Qemu-devel] [PATCH v3 19/26] q35: Fix non-PCI IRQ processing in ich9_lpc_update_apic, Jason Baron, 2012/10/19
- Re: [Qemu-devel] [PATCH v3 19/26] q35: Fix non-PCI IRQ processing in ich9_lpc_update_apic,
Michael S. Tsirkin <=
- [Qemu-devel] [PATCH v3 24/26] q35: add acpi-based pci hotplug., Jason Baron, 2012/10/19
- Re: [Qemu-devel] [PATCH v3 00/26] q35 qemu support, Michael Tokarev, 2012/10/20
- Re: [Qemu-devel] [PATCH v3 00/26] q35 qemu support, Michael S. Tsirkin, 2012/10/21
- Re: [Qemu-devel] [PATCH v3 00/26] q35 qemu support, Michael S. Tsirkin, 2012/10/21