From: "Jiang, Yunhong" Subject: RE: [PATCH] Fix "hda lost interrupt issue" on PAE host Date: Fri, 21 Apr 2006 04:41:45 +0800 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: quoted-printable Return-path: Content-class: urn:content-classes:message List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Hi,Keir I'm very sorry that I didn't descript it more clearly in previous mail. I will try to use following scenario to descript the purpose of the = patch and how it fix the issue. An IDE DMA interrupt is injected into guest, through setting the = VM_ENTRY_INTR_INFO_FIELD field on VMCS. When vmentry to vmx guest, vmx will try to inject this event to guest. = However, in this process, a page fault occurred because the page for = IDT is not set on shadow page table, maybe because of cr3 switch. This = will cause a immediately vmexit again. On this situation, because the = vmexit is occurred because of the event delivery, so the original = VM_ENTRY_INTR_INFO_FIELD information is kept in = IDT_VECTORING_INFO_FIELD. If we copy the information from IDT_VECTORING_INFO_FIELD to = VM_ENTRY_INTR_INFO_FIELD, then this interrupt will be injected again on = next vmresume. However, on original code, there is a corner case. If before the next = vmresume, a timer interrupt happened, then vmx_intr_assist may overwrite = the information on VM_ENTRY_INTR_INFO_FIELD, that will cause the IDE DMA = interrupt lost. This patch checkes the IDT_VECTORING_INFO_FIELD on vmx_intr_assist, and = if it is set, then copy it to VM_ENTRY_INTR_INFO_FIELD and return. = Though this method, we can avoid interrupt lost. More information for IDT_VECTORING_INFO_FIELD can be seen on = "Information for VM Exits That Occur During Event Delivery" section on = vmx specification. Hope I explained the issue clearly. Thanks Yunhong Jiang >-----Original Message----- >From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk] >Sent: 2006=C4=EA4=D4=C220=C8=D5 0:31 >To: Jiang, Yunhong >Cc: xen-devel@lists.xensource.com >Subject: Re: [Xen-devel] [PATCH] Fix "hda lost interrupt issue" on PAE = host > > >On 20 Apr 2006, at 02:23, Jiang, Yunhong wrote: > >> Hi, Keir >> This patch fix the =A1=B0hda lost interrupt=A1=B1 issue when create = vmx guest on >> PAE host. >> >> Signed-off-by: Yunhong Jiang Yunhong.jiang@intel.com >> Signed-off-by: Eddie Dong eddie.dong@intel.com >> > >It'd be nice to have some description of *how* the patch fixes the bug. >I'd like to have some idea what the purpose of the piece of code you >move around is: what's the difference between IDT-vectoring exception >info and ordinary VM-exit exception info? Why is reflecting the info >back into VM-entry fields always the right thing to do? etc. In >general, patches that appear to simply shuffle code around worry me. > > -- Keir