Skip to content

Commit 60a4fe0

Browse files
royujjaljmberg-intel
authored andcommitted
cfg80211: fix wext-compat for getting retry value
While getting the retry limit, wext-compat returns the value without updating the flag for retry->flags is 0. Also in this case, it updates long retry flag when short and long retry value are unequal. So, iwconfig never showing "Retry short limit" and showing "Retry long limit" when both values are unequal. Updated the flags and corrected the condition properly. Signed-off-by: Ujjal Roy <royujjal@gmail.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
1 parent 6b5895d commit 60a4fe0

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎net/wireless/wext-compat.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -412,9 +412,9 @@ int cfg80211_wext_giwretry(struct net_device *dev,
412412
* First return short value, iwconfig will ask long value
413413
* later if needed
414414
*/
415-
retry->flags |= IW_RETRY_LIMIT;
415+
retry->flags |= IW_RETRY_LIMIT | IW_RETRY_SHORT;
416416
retry->value = wdev->wiphy->retry_short;
417-
if (wdev->wiphy->retry_long != wdev->wiphy->retry_short)
417+
if (wdev->wiphy->retry_long == wdev->wiphy->retry_short)
418418
retry->flags |= IW_RETRY_LONG;
419419

420420
return 0;

0 commit comments

Comments
 (0)