summaryrefslogtreecommitdiffstats
path: root/drivers/pci/intr_remapping.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-08-15 17:34:20 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2010-08-15 17:34:20 -0700
commite2e96c663639a3361bb1a84e666887d308c6c87e (patch)
tree7c28b1e5baaff4741d974193ba30f1c53992596f /drivers/pci/intr_remapping.c
parent7355a5a654ccbbfd2fd11bb1e2389910f786ea92 (diff)
parent1a8bd481bfba30515b54368d90a915db3faf302f (diff)
Merge git://git.infradead.org/iommu-2.6
* git://git.infradead.org/iommu-2.6: intel-iommu: Fix 32-bit build warning with __cmpxchg() intr-remap: allow disabling source id checking
Diffstat (limited to 'drivers/pci/intr_remapping.c')
-rw-r--r--drivers/pci/intr_remapping.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/drivers/pci/intr_remapping.c b/drivers/pci/intr_remapping.c
index 1694a0e2845..fd1d2867cdc 100644
--- a/drivers/pci/intr_remapping.c
+++ b/drivers/pci/intr_remapping.c
@@ -21,6 +21,8 @@ static int ir_ioapic_num, ir_hpet_num;
int intr_remapping_enabled;
static int disable_intremap;
+static int disable_sourceid_checking;
+
static __init int setup_nointremap(char *str)
{
disable_intremap = 1;
@@ -28,6 +30,22 @@ static __init int setup_nointremap(char *str)
}
early_param("nointremap", setup_nointremap);
+static __init int setup_intremap(char *str)
+{
+ if (!str)
+ return -EINVAL;
+
+ if (!strncmp(str, "on", 2))
+ disable_intremap = 0;
+ else if (!strncmp(str, "off", 3))
+ disable_intremap = 1;
+ else if (!strncmp(str, "nosid", 5))
+ disable_sourceid_checking = 1;
+
+ return 0;
+}
+early_param("intremap", setup_intremap);
+
struct irq_2_iommu {
struct intel_iommu *iommu;
u16 irte_index;
@@ -453,6 +471,8 @@ int free_irte(int irq)
static void set_irte_sid(struct irte *irte, unsigned int svt,
unsigned int sq, unsigned int sid)
{
+ if (disable_sourceid_checking)
+ svt = SVT_NO_VERIFY;
irte->svt = svt;
irte->sq = sq;
irte->sid = sid;