iommu/vt-d: Allocate IRQ remapping data structures only for all IOMMUs
commit69cf1d8a1286a7bfbeec497b69c43cc7ebb2a787
authorJoerg Roedel <jroedel@suse.de>
Wed, 7 Jan 2015 07:31:36 +0000 (7 15:31 +0800)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 15 Jan 2015 10:24:23 +0000 (15 11:24 +0100)
tree8d8062607fc72a455e7e789c5ec3e41ae80cf7ff
parent2966d9566beb39c53477c96525820b9415de7a7d
iommu/vt-d: Allocate IRQ remapping data structures only for all IOMMUs

IRQ remapping is only supported when all IOMMUs in the
system support it. So check if all IOMMUs in the system
support IRQ remapping before doing the allocations.

[Jiang]
1) Rebased to v3.19.
2) Remove redundant check of ecap_ir_support(iommu->ecap) in function
   intel_enable_irq_remapping().

Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
Tested-by: Joerg Roedel <joro@8bytes.org>
Cc: Tony Luck <tony.luck@intel.com>
Cc: iommu@lists.linux-foundation.org
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Link: http://lkml.kernel.org/r/1420615903-28253-10-git-send-email-jiang.liu@linux.intel.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
drivers/iommu/intel_irq_remapping.c