mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-05 12:36:40 +07:00
ath9k: check for NULL rate when using ieee80211_get_rts_cts_rate()
ieee80211_get_rts_cts_rate() can return NULL, so don't rely on its members when it does return NULL. Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
94e7876daa
commit
09b029b6b6
@ -2006,6 +2006,9 @@ static void setup_frame_info(struct ieee80211_hw *hw,
|
||||
fi->keyix = ATH9K_TXKEYIX_INVALID;
|
||||
fi->keytype = keytype;
|
||||
fi->framelen = framelen;
|
||||
|
||||
if (!rate)
|
||||
return;
|
||||
fi->rtscts_rate = rate->hw_value;
|
||||
if (short_preamble)
|
||||
fi->rtscts_rate |= rate->hw_value_short;
|
||||
|
Loading…
Reference in New Issue
Block a user