Skip to content

Commit 7a7458e

Browse files
Miriam-Racheljmberg-intel
authored andcommitted
wifi: mac80211: reduce the scope of rts_threshold
This is only needed within the 'if' scope, not in the function scope. Signed-off-by: Miri Korenblit <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Johannes Berg <[email protected]>
1 parent 937d6ae commit 7a7458e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

net/mac80211/util.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1756,7 +1756,6 @@ int ieee80211_reconfig(struct ieee80211_local *local)
17561756
bool sched_scan_stopped = false;
17571757
bool suspended = local->suspended;
17581758
bool in_reconfig = false;
1759-
u32 rts_threshold;
17601759

17611760
lockdep_assert_wiphy(local->hw.wiphy);
17621761

@@ -1832,7 +1831,9 @@ int ieee80211_reconfig(struct ieee80211_local *local)
18321831
/* setup RTS threshold */
18331832
if (hw->wiphy->n_radio > 0) {
18341833
for (i = 0; i < hw->wiphy->n_radio; i++) {
1835-
rts_threshold = hw->wiphy->radio_cfg[i].rts_threshold;
1834+
u32 rts_threshold =
1835+
hw->wiphy->radio_cfg[i].rts_threshold;
1836+
18361837
drv_set_rts_threshold(local, i, rts_threshold);
18371838
}
18381839
} else {

0 commit comments

Comments
 (0)