aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-07-01 16:25:56 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-07-01 16:25:56 -0400
commitc9e0b8454582b413bc64c16693c7979417cad3eb (patch)
treedfa94b9445aaa854f8e8767d60f395c2de59a29c /arch/x86
parent0466dcbeda72e6a2753cd7e81f0a190054bd2233 (diff)
parent155a16f21923bc2f04161ac92acca986371ef27b (diff)
Merge branch 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen
* 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen: xen/pci: Use the INT_SRC_OVR IRQ (instead of GSI) to preset the ACPI SCI IRQ. xen/mmu: Fix for linker errors when CONFIG_SMP is not defined.
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/pci/xen.c26
-rw-r--r--arch/x86/xen/mmu.c4
2 files changed, 28 insertions, 2 deletions
diff --git a/arch/x86/pci/xen.c b/arch/x86/pci/xen.c
index 8214724ce54d..fe008309ffec 100644
--- a/arch/x86/pci/xen.c
+++ b/arch/x86/pci/xen.c
@@ -333,6 +333,7 @@ static int xen_register_pirq(u32 gsi, int triggering)
333 struct physdev_map_pirq map_irq; 333 struct physdev_map_pirq map_irq;
334 int shareable = 0; 334 int shareable = 0;
335 char *name; 335 char *name;
336 bool gsi_override = false;
336 337
337 if (!xen_pv_domain()) 338 if (!xen_pv_domain())
338 return -1; 339 return -1;
@@ -349,11 +350,32 @@ static int xen_register_pirq(u32 gsi, int triggering)
349 if (pirq < 0) 350 if (pirq < 0)
350 goto out; 351 goto out;
351 352
352 irq = xen_bind_pirq_gsi_to_irq(gsi, pirq, shareable, name); 353 /* Before we bind the GSI to a Linux IRQ, check whether
354 * we need to override it with bus_irq (IRQ) value. Usually for
355 * IRQs below IRQ_LEGACY_IRQ this holds IRQ == GSI, as so:
356 * ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 low level)
357 * but there are oddballs where the IRQ != GSI:
358 * ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 20 low level)
359 * which ends up being: gsi_to_irq[9] == 20
360 * (which is what acpi_gsi_to_irq ends up calling when starting the
361 * the ACPI interpreter and keels over since IRQ 9 has not been
362 * setup as we had setup IRQ 20 for it).
363 */
364 if (gsi == acpi_sci_override_gsi) {
365 /* Check whether the GSI != IRQ */
366 acpi_gsi_to_irq(gsi, &irq);
367 if (irq != gsi)
368 /* Bugger, we MUST have that IRQ. */
369 gsi_override = true;
370 }
371 if (gsi_override)
372 irq = xen_bind_pirq_gsi_to_irq(irq, pirq, shareable, name);
373 else
374 irq = xen_bind_pirq_gsi_to_irq(gsi, pirq, shareable, name);
353 if (irq < 0) 375 if (irq < 0)
354 goto out; 376 goto out;
355 377
356 printk(KERN_DEBUG "xen: --> pirq=%d -> irq=%d\n", pirq, irq); 378 printk(KERN_DEBUG "xen: --> pirq=%d -> irq=%d (gsi=%d)\n", pirq, irq, gsi);
357 379
358 map_irq.domid = DOMID_SELF; 380 map_irq.domid = DOMID_SELF;
359 map_irq.type = MAP_PIRQ_TYPE_GSI; 381 map_irq.type = MAP_PIRQ_TYPE_GSI;
diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c
index 673e968df3cf..0ccccb67a993 100644
--- a/arch/x86/xen/mmu.c
+++ b/arch/x86/xen/mmu.c
@@ -1232,7 +1232,11 @@ static void xen_flush_tlb_others(const struct cpumask *cpus,
1232{ 1232{
1233 struct { 1233 struct {
1234 struct mmuext_op op; 1234 struct mmuext_op op;
1235#ifdef CONFIG_SMP
1235 DECLARE_BITMAP(mask, num_processors); 1236 DECLARE_BITMAP(mask, num_processors);
1237#else
1238 DECLARE_BITMAP(mask, NR_CPUS);
1239#endif
1236 } *args; 1240 } *args;
1237 struct multicall_space mcs; 1241 struct multicall_space mcs;
1238 1242