From: "Jan Beulich" Subject: [PATCH 2/6] AMD IOMMU: untie remap and vector maps Date: Fri, 19 Apr 2013 11:57:49 +0100 Message-ID: <51713F4D02000078000CEF09@nat28.tlf.novell.com> References: <51713D8F02000078000CEEE6@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=__Part56667B3D.2__=" Return-path: In-Reply-To: <51713D8F02000078000CEEE6@nat28.tlf.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel Cc: Jacob Shin , xiantao.zhang@intel.com, suravee.suthikulpanit@amd.com, Konrad Rzeszutek Wilk List-Id: xen-devel@lists.xenproject.org This is a MIME message. If you are reading this text, you may want to consider changing to a mail reader or gateway that understands how to properly handle MIME multipart messages. --=__Part56667B3D.2__= Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Content-Disposition: inline With the specific IRTEs used for an interrupt no longer depending on the vector, there's no need to tie the remap sharing model to the vector sharing one. Signed-off-by: Jan Beulich Acked-by: George Dunlap --- a/xen/drivers/passthrough/amd/pci_amd_iommu.c +++ b/xen/drivers/passthrough/amd/pci_amd_iommu.c @@ -207,35 +207,6 @@ int __init amd_iov_detect(void) =20 init_done =3D 1; =20 - /* - * AMD IOMMUs don't distinguish between vectors destined for - * different cpus when doing interrupt remapping. This means - * that interrupts going through the same intremap table - * can't share the same vector. - * - * If irq_vector_map isn't specified, choose a sensible default: - * - If we're using per-device interemap tables, per-device - * vector non-sharing maps - * - If we're using a global interemap table, global vector - * non-sharing map - */ - if ( opt_irq_vector_map =3D=3D OPT_IRQ_VECTOR_MAP_DEFAULT ) - { - if ( amd_iommu_perdev_intremap ) - { - printk("AMD-Vi: Enabling per-device vector maps\n"); - opt_irq_vector_map =3D OPT_IRQ_VECTOR_MAP_PERDEV; - } - else - { - printk("AMD-Vi: Enabling global vector map\n"); - opt_irq_vector_map =3D OPT_IRQ_VECTOR_MAP_GLOBAL; - } - } - else - { - printk("AMD-Vi: Not overriding irq_vector_map setting\n"); - } if ( !amd_iommu_perdev_intremap ) printk(XENLOG_WARNING "AMD-Vi: Using global interrupt remap table = is not recommended (see XSA-36)!\n"); return scan_pci_devices(); --=__Part56667B3D.2__= Content-Type: text/plain; name="AMD-IOMMU-untie-remap-and-vector-maps.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="AMD-IOMMU-untie-remap-and-vector-maps.patch" AMD IOMMU: untie remap and vector maps=0A=0AWith the specific IRTEs used = for an interrupt no longer depending on=0Athe vector, there's no need to = tie the remap sharing model to the=0Avector sharing one.=0A=0ASigned-off-by= : Jan Beulich =0AAcked-by: George Dunlap =0A=0A--- a/xen/drivers/passthrough/amd/pci_amd_iommu.c=0A+++= b/xen/drivers/passthrough/amd/pci_amd_iommu.c=0A@@ -207,35 +207,6 @@ int = __init amd_iov_detect(void)=0A =0A init_done =3D 1;=0A =0A- /*=0A- = * AMD IOMMUs don't distinguish between vectors destined for=0A- * = different cpus when doing interrupt remapping. This means=0A- * that = interrupts going through the same intremap table=0A- * can't share the = same vector.=0A- *=0A- * If irq_vector_map isn't specified, choose = a sensible default:=0A- * - If we're using per-device interemap = tables, per-device=0A- * vector non-sharing maps=0A- * - If = we're using a global interemap table, global vector=0A- * non-sharing= map=0A- */=0A- if ( opt_irq_vector_map =3D=3D OPT_IRQ_VECTOR_MAP_DE= FAULT )=0A- {=0A- if ( amd_iommu_perdev_intremap )=0A- = {=0A- printk("AMD-Vi: Enabling per-device vector maps\n");=0A- = opt_irq_vector_map =3D OPT_IRQ_VECTOR_MAP_PERDEV;=0A- = }=0A- else=0A- {=0A- printk("AMD-Vi: Enabling = global vector map\n");=0A- opt_irq_vector_map =3D OPT_IRQ_VECTOR= _MAP_GLOBAL;=0A- }=0A- }=0A- else=0A- {=0A- = printk("AMD-Vi: Not overriding irq_vector_map setting\n");=0A- }=0A = if ( !amd_iommu_perdev_intremap )=0A printk(XENLOG_WARNING = "AMD-Vi: Using global interrupt remap table is not recommended (see = XSA-36)!\n");=0A return scan_pci_devices();=0A --=__Part56667B3D.2__= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --=__Part56667B3D.2__=--