iwlagn: remove hw_ready variable
This variable is only ever checked right after the function that sets it, but the same function will also return the status, so we can pass it through instead of checking hw_ready later. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
This commit is contained in:
committed by
Wey-Yi Guy
parent
dbf28e21ca
commit
4cd2bf76a4
@@ -2306,8 +2306,7 @@ int iwlagn_start_device(struct iwl_priv *priv)
|
||||
{
|
||||
int ret;
|
||||
|
||||
iwl_prepare_card_hw(priv);
|
||||
if (!priv->hw_ready) {
|
||||
if (iwl_prepare_card_hw(priv)) {
|
||||
IWL_WARN(priv, "Exit HW not ready\n");
|
||||
return -EIO;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user