From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46631) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1anZgq-0001XF-JO for qemu-devel@nongnu.org; Tue, 05 Apr 2016 18:43:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1anZgl-0006T8-GD for qemu-devel@nongnu.org; Tue, 05 Apr 2016 18:43:16 -0400 Received: from mail.windriver.com ([147.11.1.11]:63543) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1anZgl-0006Sf-6V for qemu-devel@nongnu.org; Tue, 05 Apr 2016 18:43:11 -0400 From: Bill Paul Date: Tue, 5 Apr 2016 15:58:19 -0700 MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <201604051558.20070.wpaul@windriver.com> Subject: [Qemu-devel] [PATCH] hw/timer: Revert "hpet: inverse polarity when pin above ISA_NUM_IRQS" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Eduardo Habkost , Richard Henderson This reverts commit 0d63b2dd31464cfccc80bbeedc24e3863fe4c895. This change was originally intended to correct the HPET behavior in conjunction with Linux, however the behavior that it actually creates doesn't match what happens with real hardware, the logic doesn't seem compatible with the ioapic.c implementation either. Signed-off-by: Bill Paul CC: Paolo Bonzini CC: Richard Henderson CC: Eduardo Habkost --- hw/timer/hpet.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/hw/timer/hpet.c b/hw/timer/hpet.c index 78140e6..a2c18b3 100644 --- a/hw/timer/hpet.c +++ b/hw/timer/hpet.c @@ -201,12 +201,7 @@ static void update_irq(struct HPETTimer *timer, int set) if (!set || !timer_enabled(timer) || !hpet_enabled(timer->state)) { s->isr &= ~mask; if (!timer_fsb_route(timer)) { - /* fold the ICH PIRQ# pin's internal inversion logic into hpet */ - if (route >= ISA_NUM_IRQS) { - qemu_irq_raise(s->irqs[route]); - } else { - qemu_irq_lower(s->irqs[route]); - } + qemu_irq_lower(s->irqs[route]); } } else if (timer_fsb_route(timer)) { address_space_stl_le(&address_space_memory, timer->fsb >> 32, @@ -214,12 +209,7 @@ static void update_irq(struct HPETTimer *timer, int set) NULL); } else if (timer->config & HPET_TN_TYPE_LEVEL) { s->isr |= mask; - /* fold the ICH PIRQ# pin's internal inversion logic into hpet */ - if (route >= ISA_NUM_IRQS) { - qemu_irq_lower(s->irqs[route]); - } else { - qemu_irq_raise(s->irqs[route]); - } + qemu_irq_raise(s->irqs[route]); } else { s->isr &= ~mask; qemu_irq_pulse(s->irqs[route]); -- 2.4.6