diff options
-rw-r--r-- | arch/x86/include/asm/io_apic.h | 2 | ||||
-rw-r--r-- | arch/x86/kernel/apic/io_apic.c | 5 | ||||
-rw-r--r-- | drivers/xen/events/events_base.c | 17 |
3 files changed, 1 insertions, 23 deletions
diff --git a/arch/x86/include/asm/io_apic.h b/arch/x86/include/asm/io_apic.h index 459e50a424d1..90f97b4b9347 100644 --- a/arch/x86/include/asm/io_apic.h +++ b/arch/x86/include/asm/io_apic.h | |||
@@ -168,8 +168,6 @@ extern int save_ioapic_entries(void); | |||
168 | extern void mask_ioapic_entries(void); | 168 | extern void mask_ioapic_entries(void); |
169 | extern int restore_ioapic_entries(void); | 169 | extern int restore_ioapic_entries(void); |
170 | 170 | ||
171 | extern int get_nr_irqs_gsi(void); | ||
172 | |||
173 | extern void setup_ioapic_ids_from_mpc(void); | 171 | extern void setup_ioapic_ids_from_mpc(void); |
174 | extern void setup_ioapic_ids_from_mpc_nocheck(void); | 172 | extern void setup_ioapic_ids_from_mpc_nocheck(void); |
175 | 173 | ||
diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c index 3c17b25d159d..be3b5741badb 100644 --- a/arch/x86/kernel/apic/io_apic.c +++ b/arch/x86/kernel/apic/io_apic.c | |||
@@ -3450,11 +3450,6 @@ static void __init probe_nr_irqs_gsi(void) | |||
3450 | printk(KERN_DEBUG "nr_irqs_gsi: %d\n", nr_irqs_gsi); | 3450 | printk(KERN_DEBUG "nr_irqs_gsi: %d\n", nr_irqs_gsi); |
3451 | } | 3451 | } |
3452 | 3452 | ||
3453 | int get_nr_irqs_gsi(void) | ||
3454 | { | ||
3455 | return nr_irqs_gsi; | ||
3456 | } | ||
3457 | |||
3458 | unsigned int arch_dynirq_lower_bound(unsigned int from) | 3453 | unsigned int arch_dynirq_lower_bound(unsigned int from) |
3459 | { | 3454 | { |
3460 | return from < nr_irqs_gsi ? nr_irqs_gsi : from; | 3455 | return from < nr_irqs_gsi ? nr_irqs_gsi : from; |
diff --git a/drivers/xen/events/events_base.c b/drivers/xen/events/events_base.c index dfa12a4a0a48..c919d3d5c845 100644 --- a/drivers/xen/events/events_base.c +++ b/drivers/xen/events/events_base.c | |||
@@ -390,22 +390,7 @@ static void xen_irq_init(unsigned irq) | |||
390 | 390 | ||
391 | static int __must_check xen_allocate_irqs_dynamic(int nvec) | 391 | static int __must_check xen_allocate_irqs_dynamic(int nvec) |
392 | { | 392 | { |
393 | int first = 0; | 393 | int i, irq = irq_alloc_descs(-1, 0, nvec, -1); |
394 | int i, irq; | ||
395 | |||
396 | #ifdef CONFIG_X86_IO_APIC | ||
397 | /* | ||
398 | * For an HVM guest or domain 0 which see "real" (emulated or | ||
399 | * actual respectively) GSIs we allocate dynamic IRQs | ||
400 | * e.g. those corresponding to event channels or MSIs | ||
401 | * etc. from the range above those "real" GSIs to avoid | ||
402 | * collisions. | ||
403 | */ | ||
404 | if (xen_initial_domain() || xen_hvm_domain()) | ||
405 | first = get_nr_irqs_gsi(); | ||
406 | #endif | ||
407 | |||
408 | irq = irq_alloc_descs_from(first, nvec, -1); | ||
409 | 394 | ||
410 | if (irq >= 0) { | 395 | if (irq >= 0) { |
411 | for (i = 0; i < nvec; i++) | 396 | for (i = 0; i < nvec; i++) |