From mboxrd@z Thu Jan 1 00:00:00 1970 From: Beth Kon Subject: Re: [PATCH 1/5] BIOS changes for configuring irq0->inti2 override (v4) Date: Thu, 11 Jun 2009 17:23:17 -0400 Message-ID: <4A3175C5.6070205@us.ibm.com> References: <1244731365-32069-1-git-send-email-eak@us.ibm.com> <96E2F18C325F48788FEB591C6547B4B5@FSCPC> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: avi@redhat.com, kvm@vger.kernel.org To: Sebastian Herbszt Return-path: Received: from e37.co.us.ibm.com ([32.97.110.158]:35127 "EHLO e37.co.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750736AbZFKVWT (ORCPT ); Thu, 11 Jun 2009 17:22:19 -0400 Received: from d03relay04.boulder.ibm.com (d03relay04.boulder.ibm.com [9.17.195.106]) by e37.co.us.ibm.com (8.13.1/8.13.1) with ESMTP id n5BLLfHg004639 for ; Thu, 11 Jun 2009 15:21:41 -0600 Received: from d03av03.boulder.ibm.com (d03av03.boulder.ibm.com [9.17.195.169]) by d03relay04.boulder.ibm.com (8.13.8/8.13.8/NCO v9.2) with ESMTP id n5BLMJmH152136 for ; Thu, 11 Jun 2009 15:22:19 -0600 Received: from d03av03.boulder.ibm.com (loopback [127.0.0.1]) by d03av03.boulder.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n5BLMIsd010818 for ; Thu, 11 Jun 2009 15:22:19 -0600 In-Reply-To: <96E2F18C325F48788FEB591C6547B4B5@FSCPC> Sender: kvm-owner@vger.kernel.org List-ID: Sebastian Herbszt wrote: > Beth Kon wrote: >> These patches resolve the irq0->inti2 override issue, and get the >> hpet working >> on kvm. >> >> Override and HPET changes are sent as a series because HPET depends >> on the >> override. Win2k8 expects the HPET interrupt on inti2, regardless of >> whether >> an override exists in the BIOS. And the HPET spec states that in >> legacy mode, >> timer interrupt is on inti2. >> >> The irq0->inti2 override will always be used unless the kernel cannot >> do irq >> routing (i.e., compatibility with old kernels). So if the kernel is >> capable, >> userspace sets up irq0->inti2 via the irq routing interface, and adds >> the >> irq0->inti2 override to the MADT interrupt source override table, >> and the mp table (for the no-acpi case). >> >> Changes from v3: >> >> - changes based on comments from Avi and Gleb. >> - corrected legacy enable/disable for in-kernel PIT. The code now best >> approximates a multiplexer that disables PIT interrupts when HPET is >> in legacy mode (as described by HPET spec). Any changes to the PIT >> that may occur while HPET is operating in legacy mode are saved, so >> if HPET leaves legacy mode, the PIT is just reenabled, with mode >> set to whatever the last setting from guest was. Legacy mode is >> disabled >> at least during crash and shutdown (in Linux), so this needs to be >> handled properly. >> >> >> --- >> kvm/bios/rombios32.c | 60 >> ++++++++++++++++++++++++++++++++++++------------- >> 1 files changed, 44 insertions(+), 16 deletions(-) > > What about the mptable entry count? > Think it would need something like > > #ifdef BX_QEMU > if (irq0_override) > putle16(&q, smp_cpus + 17); /* entry count */ > else > putle16(&q, smp_cpus + 18); /* entry count */ > #else > putle16(&q, smp_cpus + 18); /* entry count */ > #endif > > Your patch "Fix non-ACPI Timer Interrupt Routing - v3" [1] included > such a change. > > [1] http://lists.gnu.org/archive/html/qemu-devel/2009-04/msg01396.html Yes, I lost that somehow! Thanks (again!). > > - Sebastian >