Skip to content

Commit

Permalink
i40e: removing unreachable code
Browse files Browse the repository at this point in the history
The return value from i40e_shutdown_adminq() is always 0
(I40E_SUCCESS). So, the test for non-0 will never be true. Cleanup
by removing the test and debug print statement.

Change-ID: Ie51e8e37515c3e3a6a9ff26fa951d0e5e24343c1
Signed-off-by: Henry Tieman <henry.w.tieman@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
  • Loading branch information
Henry Tieman authored and Jeff Kirsher committed Sep 25, 2016
1 parent a3417d2 commit ac9c5c6
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions drivers/net/ethernet/intel/i40e/i40e_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -11333,11 +11333,7 @@ static void i40e_remove(struct pci_dev *pdev)
}

/* shutdown the adminq */
ret_code = i40e_shutdown_adminq(hw);
if (ret_code)
dev_warn(&pdev->dev,
"Failed to destroy the Admin Queue resources: %d\n",
ret_code);
i40e_shutdown_adminq(hw);

/* destroy the locks only once, here */
mutex_destroy(&hw->aq.arq_mutex);
Expand Down

0 comments on commit ac9c5c6

Please sign in to comment.