]> www.infradead.org Git - users/hch/misc.git/commitdiff
wifi: iwlwifi: mld: make iwl_mld_rm_vif void
authorMiri Korenblit <miriam.rachel.korenblit@intel.com>
Thu, 28 Aug 2025 08:25:58 +0000 (11:25 +0300)
committerMiri Korenblit <miriam.rachel.korenblit@intel.com>
Sun, 31 Aug 2025 11:39:26 +0000 (14:39 +0300)
Unlike adding/allocating an object, destroying it should always
succeed. In addition, the return value of iwl_mld_rm_vif is not even
used.
Make it a void function.

Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250828111032.418e898e908d.I18cc8d6b55a4e468dd155a40089ebea7de70594c@changeid
drivers/net/wireless/intel/iwlwifi/mld/iface.c
drivers/net/wireless/intel/iwlwifi/mld/iface.h

index 38993d65c052a8736e36a08b8a0095567467c5cd..c4738400ee11dba9d0661efddcf2da7296cbdd0b 100644 (file)
@@ -451,24 +451,21 @@ int iwl_mld_add_vif(struct iwl_mld *mld, struct ieee80211_vif *vif)
        return ret;
 }
 
-int iwl_mld_rm_vif(struct iwl_mld *mld, struct ieee80211_vif *vif)
+void iwl_mld_rm_vif(struct iwl_mld *mld, struct ieee80211_vif *vif)
 {
        struct iwl_mld_vif *mld_vif = iwl_mld_vif_from_mac80211(vif);
-       int ret;
 
        lockdep_assert_wiphy(mld->wiphy);
 
-       ret = iwl_mld_mac_fw_action(mld, vif, FW_CTXT_ACTION_REMOVE);
+       iwl_mld_mac_fw_action(mld, vif, FW_CTXT_ACTION_REMOVE);
 
        if (WARN_ON(mld_vif->fw_id >= ARRAY_SIZE(mld->fw_id_to_vif)))
-               return -EINVAL;
+               return;
 
        RCU_INIT_POINTER(mld->fw_id_to_vif[mld_vif->fw_id], NULL);
 
        iwl_mld_cancel_notifications_of_object(mld, IWL_MLD_OBJECT_TYPE_VIF,
                                               mld_vif->fw_id);
-
-       return ret;
 }
 
 void iwl_mld_set_vif_associated(struct iwl_mld *mld,
index 38e10e279153c1f580d69a97b46a138084f561d0..a3573d20f214ad0b693f7d077a95cea5e15156e0 100644 (file)
@@ -224,7 +224,7 @@ void iwl_mld_cleanup_vif(void *data, u8 *mac, struct ieee80211_vif *vif);
 int iwl_mld_mac_fw_action(struct iwl_mld *mld, struct ieee80211_vif *vif,
                          u32 action);
 int iwl_mld_add_vif(struct iwl_mld *mld, struct ieee80211_vif *vif);
-int iwl_mld_rm_vif(struct iwl_mld *mld, struct ieee80211_vif *vif);
+void iwl_mld_rm_vif(struct iwl_mld *mld, struct ieee80211_vif *vif);
 void iwl_mld_set_vif_associated(struct iwl_mld *mld,
                                struct ieee80211_vif *vif);
 u8 iwl_mld_get_fw_bss_vifs_ids(struct iwl_mld *mld);