diff options
Diffstat (limited to 'arch/ia64/kernel/iosapic.c')
-rw-r--r-- | arch/ia64/kernel/iosapic.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/arch/ia64/kernel/iosapic.c b/arch/ia64/kernel/iosapic.c index c170be095ccd..7936b62f7a2e 100644 --- a/arch/ia64/kernel/iosapic.c +++ b/arch/ia64/kernel/iosapic.c | |||
@@ -489,8 +489,6 @@ static int iosapic_find_sharable_vector (unsigned long trigger, unsigned long po | |||
489 | } | 489 | } |
490 | } | 490 | } |
491 | } | 491 | } |
492 | if (vector < 0) | ||
493 | panic("%s: out of interrupt vectors!\n", __FUNCTION__); | ||
494 | 492 | ||
495 | return vector; | 493 | return vector; |
496 | } | 494 | } |
@@ -506,6 +504,8 @@ iosapic_reassign_vector (int vector) | |||
506 | 504 | ||
507 | if (!list_empty(&iosapic_intr_info[vector].rtes)) { | 505 | if (!list_empty(&iosapic_intr_info[vector].rtes)) { |
508 | new_vector = assign_irq_vector(AUTO_ASSIGN); | 506 | new_vector = assign_irq_vector(AUTO_ASSIGN); |
507 | if (new_vector < 0) | ||
508 | panic("%s: out of interrupt vectors!\n", __FUNCTION__); | ||
509 | printk(KERN_INFO "Reassigning vector %d to %d\n", vector, new_vector); | 509 | printk(KERN_INFO "Reassigning vector %d to %d\n", vector, new_vector); |
510 | memcpy(&iosapic_intr_info[new_vector], &iosapic_intr_info[vector], | 510 | memcpy(&iosapic_intr_info[new_vector], &iosapic_intr_info[vector], |
511 | sizeof(struct iosapic_intr_info)); | 511 | sizeof(struct iosapic_intr_info)); |
@@ -734,9 +734,12 @@ again: | |||
734 | spin_unlock_irqrestore(&iosapic_lock, flags); | 734 | spin_unlock_irqrestore(&iosapic_lock, flags); |
735 | 735 | ||
736 | /* If vector is running out, we try to find a sharable vector */ | 736 | /* If vector is running out, we try to find a sharable vector */ |
737 | vector = assign_irq_vector_nopanic(AUTO_ASSIGN); | 737 | vector = assign_irq_vector(AUTO_ASSIGN); |
738 | if (vector < 0) | 738 | if (vector < 0) { |
739 | vector = iosapic_find_sharable_vector(trigger, polarity); | 739 | vector = iosapic_find_sharable_vector(trigger, polarity); |
740 | if (vector < 0) | ||
741 | panic("%s: out of interrupt vectors!\n", __FUNCTION__); | ||
742 | } | ||
740 | 743 | ||
741 | spin_lock_irqsave(&irq_descp(vector)->lock, flags); | 744 | spin_lock_irqsave(&irq_descp(vector)->lock, flags); |
742 | spin_lock(&iosapic_lock); | 745 | spin_lock(&iosapic_lock); |
@@ -884,6 +887,8 @@ iosapic_register_platform_intr (u32 int_type, unsigned int gsi, | |||
884 | break; | 887 | break; |
885 | case ACPI_INTERRUPT_INIT: | 888 | case ACPI_INTERRUPT_INIT: |
886 | vector = assign_irq_vector(AUTO_ASSIGN); | 889 | vector = assign_irq_vector(AUTO_ASSIGN); |
890 | if (vector < 0) | ||
891 | panic("%s: out of interrupt vectors!\n", __FUNCTION__); | ||
887 | delivery = IOSAPIC_INIT; | 892 | delivery = IOSAPIC_INIT; |
888 | break; | 893 | break; |
889 | case ACPI_INTERRUPT_CPEI: | 894 | case ACPI_INTERRUPT_CPEI: |