Commit 6dd8420d authored by Martin Kaiser's avatar Martin Kaiser Committed by Greg Kroah-Hartman
Browse files

staging: r8188eu: remove duplicate psta check



We do not need the psta check in the while loop of rtw_xmitframe_coalesce.
psta is already checked near the start of the function and is not modified
afterwards.

Signed-off-by: default avatarMartin Kaiser <martin@kaiser.cx>
Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150
Link: https://lore.kernel.org/r/20221230180646.91008-9-martin@kaiser.cx


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a8dce6b4
Loading
Loading
Loading
Loading
+17 −19
Original line number Diff line number Diff line
@@ -1009,7 +1009,6 @@ s32 rtw_xmitframe_coalesce(struct adapter *padapter, struct sk_buff *pkt, struct

		/* adding icv, if necessary... */
		if (pattrib->iv_len) {
			if (psta) {
			switch (pattrib->encrypt) {
			case _WEP40_:
			case _WEP104_:
@@ -1028,7 +1027,6 @@ s32 rtw_xmitframe_coalesce(struct adapter *padapter, struct sk_buff *pkt, struct
					AES_IV(pattrib->iv, psta->dot11txpn, 0);
				break;
			}
			}

			memcpy(pframe, pattrib->iv, pattrib->iv_len);