wifi: iwlwifi: mvm: remove conditional return with no effect
PATCH v2 1/1 wifi: iwlwifi: mvm: remove conditional return with no effect
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly.
This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci.
Signed-off-by Sang-Heon Jeon <[email protected]>
---
As suggested by Ping-Ke, the wifi patch of the treewide v1 series [1] is split per driver and posted separately. You can find the Coccinelle script in v1 [1].
---
Changes from v1 [1]
- Split the wifi patch per driver
- Change base to iwlwifi-next/next
- Filter only iwlwifi changes
[1] https://lore.kernel.org/all/[email protected]/
---
drivers/net/wireless/intel/iwlwifi/mvm/link.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)
drivers/net/wireless/intel/iwlwifi/mvm/link.c +1 -5
@@ -278,11 +278,7 @@ int iwl_mvm_disable_link(struct iwl_mvm *mvm, struct ieee80211_vif *vif,if (ret)return ret; - ret =iwl_mvm_remove_link (mvm, vif, link_conf); -if (ret) -return ret; - -return ret; +return iwl_mvm_remove_link (mvm, vif, link_conf); }void iwl_mvm_init_link (struct iwl_mvm_vif_link_info *link)
Signature · 1 line
2.43.0