Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2ea5ea5f authored by Emil Tantilov's avatar Emil Tantilov Committed by Jeff Kirsher
Browse files

ixgbe: fix return value checks



The value of status was incorrectly tested. Also whitespace cleanup.

Signed-off-by: default avatarEmil Tantilov <emil.s.tantilov@intel.com>
Tested-by: default avatarEvan Swanson <evan.swanson@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent c8ca76eb
Loading
Loading
Loading
Loading
+2 −3
Original line number Original line Diff line number Diff line
@@ -452,7 +452,7 @@ static s32 ixgbe_update_flash_X540(struct ixgbe_hw *hw)
	IXGBE_WRITE_REG(hw, IXGBE_EEC, flup);
	IXGBE_WRITE_REG(hw, IXGBE_EEC, flup);


	status = ixgbe_poll_flash_update_done_X540(hw);
	status = ixgbe_poll_flash_update_done_X540(hw);
	if (status)
	if (status == 0)
		hw_dbg(hw, "Flash update complete\n");
		hw_dbg(hw, "Flash update complete\n");
	else
	else
		hw_dbg(hw, "Flash update time out\n");
		hw_dbg(hw, "Flash update time out\n");
@@ -466,11 +466,10 @@ static s32 ixgbe_update_flash_X540(struct ixgbe_hw *hw)
		}
		}


		status = ixgbe_poll_flash_update_done_X540(hw);
		status = ixgbe_poll_flash_update_done_X540(hw);
		if (status)
		if (status == 0)
			hw_dbg(hw, "Flash update complete\n");
			hw_dbg(hw, "Flash update complete\n");
		else
		else
			hw_dbg(hw, "Flash update time out\n");
			hw_dbg(hw, "Flash update time out\n");

	}
	}
out:
out:
	return status;
	return status;