Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750990AbbDGFDE (ORCPT ); Tue, 7 Apr 2015 01:03:04 -0400 Received: from mga03.intel.com ([134.134.136.65]:40213 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750756AbbDGFDA convert rfc822-to-8bit (ORCPT ); Tue, 7 Apr 2015 01:03:00 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.11,536,1422950400"; d="scan'208";a="551920800" From: "Wu, Feng" To: "Li, ZhenHua" CC: Joerg Roedel , "dwmw2@infradead.org" , "jiang.liu@linux.intel.com" , "iommu@lists.linux-foundation.org" , "linux-kernel@vger.kernel.org" , "Wu, Feng" Subject: RE: [v4 0/8] Add VT-d Posted-Interrupts support - IOMMU part Thread-Topic: [v4 0/8] Add VT-d Posted-Interrupts support - IOMMU part Thread-Index: AQHQbeYUXl0izTEvjUyeY+lpo/yaCJ069Syw Date: Tue, 7 Apr 2015 05:02:55 +0000 Message-ID: References: <1422864424-19411-1-git-send-email-feng.wu@intel.com> <20150402112833.GN4441@8bytes.org> <551E4B7D.6020108@hp.com> In-Reply-To: <551E4B7D.6020108@hp.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3320 Lines: 91 > -----Original Message----- > From: Li, ZhenHua [mailto:zhen-hual@hp.com] > Sent: Friday, April 03, 2015 4:13 PM > To: Wu, Feng > Cc: Joerg Roedel; dwmw2@infradead.org; jiang.liu@linux.intel.com; > iommu@lists.linux-foundation.org; linux-kernel@vger.kernel.org; Li, ZhenHua > Subject: Re: [v4 0/8] Add VT-d Posted-Interrupts support - IOMMU part > > Hi Feng Wu, > In my patchset, I created a new member ir_table->base_old_phys; In the > normal kernel, everything is the same. In kdump kernel, ir_table->base > is used for a buffer, and ir_table->base_old_phys is the physical > address of the tables used by the old kernel, also being used by the > current kernel. > > I did this in modify_irte(): > > set_64bit(&irte->high, irte_modified->high); > + > +#ifdef CONFIG_CRASH_DUMP > + if (is_kdump_kernel()) > + __iommu_update_old_irte(iommu, index); > +#endif > __iommu_flush_cache(iommu, irte, sizeof(*irte)); > > > Here the irte tables are stored in two places: > iommu->ir_table->base : It is a buffer in kdump kernel, which is the > running kernel; > iommu->ir_table->base_old_phys : It is the irte used by the old kernel; > > And function __iommu_update_old_irte is used to save the content of > iommu->ir_table->base to iommu->ir_table->base_old_phys. Because in > kdump kernel, the vt-d is using ir_table->base_old_phys, not > ir_table->base, so we need to copy the updated ir_table->base to > ir_table->base_old_phys . > Hi Zhenhua, Thanks very much for your clarification! Basically, the main purpose of my Patch-set is to provide an interface to KVM, so that KVM can update irte for posted-interrupts. In this interface, it calls modify_irte(). I also go through your patch set with the associated part, seems I cannot find any conflicts with your patches. What is your idea about this? Thanks a lot! Thanks, Feng - > > Thanks > Zhenhua > > On 04/02/2015 07:28 PM, Joerg Roedel wrote: > > On Mon, Feb 02, 2015 at 04:06:56PM +0800, Feng Wu wrote: > >> VT-d Posted-Interrupts is an enhancement to CPU side Posted-Interrupt. > >> With VT-d Posted-Interrupts enabled, external interrupts from > >> direct-assigned devices can be delivered to guests without VMM > >> intervention when guest is running in non-root mode. > >> > >> You can find the VT-d Posted-Interrtups Spec. in the following URL: > >> > http://www.intel.com/content/www/us/en/intelligent-systems/intel-technolog > y/vt-directed-io-spec.html > >> > >> This series was part of > http://thread.gmane.org/gmane.linux.kernel.iommu/7708. To make things > clear, send out IOMMU part here. > > > > Besides the modify_irte() changes I asked for the patch-set looks good. > > I just have some concerns what these changes mean for the VT-d kdump > > improvements Zhen-Hua Li is working on. Can you please discuss the > > implications of having both patch-sets applied with him and make sure > > they work together? I think in its current form your patch-set breaks > > the kdump support patches. I added Zhen-Hua to Cc. > > > > Thanks, > > > > Joerg > > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/