Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d8e94d09 authored by Igor Pylypiv's avatar Igor Pylypiv Committed by Greg Kroah-Hartman
Browse files

staging: wlan-ng: add missing byte order conversion



commit 2c474b8579e9b67ff72b2bcefce9f53c7f4469d4 upstream.

Conversion macros le16_to_cpu was removed and that caused new sparse warning

sparse output:
drivers/staging/wlan-ng/p80211netdev.c:241:44: warning: incorrect type in argument 2 (different base types)
drivers/staging/wlan-ng/p80211netdev.c:241:44:    expected unsigned short [unsigned] [usertype] fc
drivers/staging/wlan-ng/p80211netdev.c:241:44:    got restricted __le16 [usertype] fc

Fixes: 7ad82572 ("staging:wlan-ng:Fix sparse warning")
Signed-off-by: default avatarIgor Pylypiv <igor.pylypiv@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 47b7257f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -232,7 +232,7 @@ static int p80211_convert_to_ether(struct wlandevice *wlandev, struct sk_buff *s
	struct p80211_hdr_a3 *hdr;

	hdr = (struct p80211_hdr_a3 *)skb->data;
	if (p80211_rx_typedrop(wlandev, hdr->fc))
	if (p80211_rx_typedrop(wlandev, le16_to_cpu(hdr->fc)))
		return CONV_TO_ETHER_SKIPPED;

	/* perform mcast filtering: allow my local address through but reject