qlcnic: Fix MSI-X initialization code
authorAlexander Gordeev <agordeev@redhat.com>
Tue, 15 Apr 2014 09:37:14 +0000 (11:37 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 15 Apr 2014 19:14:19 +0000 (15:14 -0400)
commit8564ae09e08340a26c5408637cc4b32dba9f1640
tree5f0fecd77549f54cb631647a729b81f70cc55dd9
parent54d63f787b652755e66eb4dd8892ee6d3f5197fc
qlcnic: Fix MSI-X initialization code

Function qlcnic_setup_tss_rss_intr() might enter endless
loop in case pci_enable_msix() contiguously returns a
positive number of MSI-Xs that could have been allocated.
Besides, the function contains 'err = -EIO;' assignment
that never could be reached. This update fixes the
aforementioned issues.

Cc: Shahed Shaikh <shahed.shaikh@qlogic.com>
Cc: Dept-HSGLinuxNICDev@qlogic.com
Cc: netdev@vger.kernel.org
Cc: linux-pci@vger.kernel.org
Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
Acked-by: Shahed Shaikh <shahed.shaikh@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c