cxgb3: Remove superfluous call to pci_disable_msix()
authorAlexander Gordeev <agordeev@redhat.com>
Tue, 18 Feb 2014 10:07:57 +0000 (11:07 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 18 Feb 2014 20:33:29 +0000 (15:33 -0500)
There is no need to call pci_disable_msix() in case
the previous call to pci_enable_msix() failed

Signed-off-by: Alexander Gordeev <agordeev@redhat.com>
Cc: Santosh Raspatur <santosh@chelsio.com>
Cc: netdev@vger.kernel.org
Cc: linux-pci@vger.kernel.org
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb3/cxgb3_main.c

index 45d77334d7d9a6c1a053be81599edcbf8b74c3b7..b72d2ed9dad4e0a5cb9c311a9bca1fb760e3f870 100644 (file)
@@ -3097,9 +3097,6 @@ static int cxgb_enable_msix(struct adapter *adap)
        while ((err = pci_enable_msix(adap->pdev, entries, vectors)) > 0)
                vectors = err;
 
-       if (err < 0)
-               pci_disable_msix(adap->pdev);
-
        if (!err && vectors < (adap->params.nports + 1)) {
                pci_disable_msix(adap->pdev);
                err = -1;