diff options
Diffstat (limited to 'drivers/pci/msi.c')
-rw-r--r-- | drivers/pci/msi.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c index 4f326f38f9bf..38e4c807f80f 100644 --- a/drivers/pci/msi.c +++ b/drivers/pci/msi.c | |||
@@ -573,8 +573,6 @@ void pci_disable_msi(struct pci_dev* dev) | |||
573 | return; | 573 | return; |
574 | } | 574 | } |
575 | 575 | ||
576 | BUG_ON(irq_has_action(dev->first_msi_irq)); | ||
577 | |||
578 | default_irq = entry->msi_attrib.default_irq; | 576 | default_irq = entry->msi_attrib.default_irq; |
579 | msi_free_irq(dev, dev->first_msi_irq); | 577 | msi_free_irq(dev, dev->first_msi_irq); |
580 | 578 | ||
@@ -590,6 +588,8 @@ static int msi_free_irq(struct pci_dev* dev, int irq) | |||
590 | int head, entry_nr, type; | 588 | int head, entry_nr, type; |
591 | void __iomem *base; | 589 | void __iomem *base; |
592 | 590 | ||
591 | BUG_ON(irq_has_action(irq)); | ||
592 | |||
593 | entry = get_irq_msi(irq); | 593 | entry = get_irq_msi(irq); |
594 | if (!entry || entry->dev != dev) { | 594 | if (!entry || entry->dev != dev) { |
595 | return -EINVAL; | 595 | return -EINVAL; |
@@ -682,8 +682,6 @@ static void msix_free_all_irqs(struct pci_dev *dev) | |||
682 | while (head != tail) { | 682 | while (head != tail) { |
683 | tail = get_irq_msi(irq)->link.tail; | 683 | tail = get_irq_msi(irq)->link.tail; |
684 | 684 | ||
685 | BUG_ON(irq_has_action(irq)); | ||
686 | |||
687 | if (irq != head) | 685 | if (irq != head) |
688 | msi_free_irq(dev, irq); | 686 | msi_free_irq(dev, irq); |
689 | irq = tail; | 687 | irq = tail; |
@@ -723,10 +721,8 @@ void msi_remove_pci_irq_vectors(struct pci_dev* dev) | |||
723 | if (!pci_msi_enable || !dev) | 721 | if (!pci_msi_enable || !dev) |
724 | return; | 722 | return; |
725 | 723 | ||
726 | if (dev->msi_enabled) { | 724 | if (dev->msi_enabled) |
727 | BUG_ON(irq_has_action(dev->first_msi_irq)); | ||
728 | msi_free_irq(dev, dev->first_msi_irq); | 725 | msi_free_irq(dev, dev->first_msi_irq); |
729 | } | ||
730 | 726 | ||
731 | if (dev->msix_enabled) | 727 | if (dev->msix_enabled) |
732 | msix_free_all_irqs(dev); | 728 | msix_free_all_irqs(dev); |