mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-12 07:34:08 +08:00
staging: r8188eu: use ieee80211 helper to check for pspoll
Use the ieee80211 helper to check if our incoming ctrl frame is a pspoll frame. We can drop the initial ctrl frame check as ieee80211_is_pspoll checks for a control frame with subtype pspoll. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Link: https://lore.kernel.org/r/20220403164526.357371-3-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
797afdf248
commit
45d433b817
@ -804,15 +804,12 @@ static void validate_recv_ctrl_frame(struct adapter *padapter,
|
||||
__le16 fc = *(__le16 *)pframe;
|
||||
/* uint len = precv_frame->len; */
|
||||
|
||||
if (!ieee80211_is_ctl(fc))
|
||||
return;
|
||||
|
||||
/* receive the frames that ra(a1) is my address */
|
||||
if (memcmp(GetAddr1Ptr(pframe), myid(&padapter->eeprompriv), ETH_ALEN))
|
||||
return;
|
||||
|
||||
/* only handle ps-poll */
|
||||
if (GetFrameSubType(pframe) == WIFI_PSPOLL) {
|
||||
if (ieee80211_is_pspoll(fc)) {
|
||||
u16 aid;
|
||||
u8 wmmps_ac = 0;
|
||||
struct sta_info *psta = NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user