diff options
author | Alexander Gordeev <agordeev@redhat.com> | 2014-07-16 20:05:07 +0200 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2014-07-29 08:38:52 -0400 |
commit | 8cb7f63d68bb87a4ade9cebc571a97f2a2354dc6 (patch) | |
tree | 9603cc62d89b673d0b2d705b10dc9fa77f2a32fe /drivers/scsi/bfa | |
parent | cd69a09eb2851b3320a8526781916f5a2a1660a2 (diff) | |
download | linux-8cb7f63d68bb87a4ade9cebc571a97f2a2354dc6.tar.bz2 |
bfa: Cleanup bfad_setup_intr() function
Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
Acked-by: Anil Gurumurthy <anil.gurumurthy@qlogic.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/bfa')
-rw-r--r-- | drivers/scsi/bfa/bfad.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c index bb931808328f..c18279fbb8b3 100644 --- a/drivers/scsi/bfa/bfad.c +++ b/drivers/scsi/bfa/bfad.c @@ -1219,7 +1219,7 @@ bfad_install_msix_handler(struct bfad_s *bfad) int bfad_setup_intr(struct bfad_s *bfad) { - int error = 0; + int error; u32 mask = 0, i, num_bit = 0, max_bit = 0; struct msix_entry msix_entries[MAX_MSIX_ENTRY]; struct pci_dev *pdev = bfad->pcidev; @@ -1279,20 +1279,18 @@ bfad_setup_intr(struct bfad_s *bfad) bfad->bfad_flags |= BFAD_MSIX_ON; - return error; + return 0; } line_based: - error = 0; - if (request_irq - (bfad->pcidev->irq, (irq_handler_t) bfad_intx, BFAD_IRQ_FLAGS, - BFAD_DRIVER_NAME, bfad) != 0) { - /* Enable interrupt handler failed */ - return 1; - } + error = request_irq(bfad->pcidev->irq, (irq_handler_t)bfad_intx, + BFAD_IRQ_FLAGS, BFAD_DRIVER_NAME, bfad); + if (error) + return error; + bfad->bfad_flags |= BFAD_INTX_ON; - return error; + return 0; } void |