diff mbox

mac80211: Use macro instead of number

Message ID 1466594583-23663-1-git-send-email-masashi.honma@gmail.com (mailing list archive)
State Accepted
Delegated to: Johannes Berg
Headers show

Commit Message

Masashi Honma June 22, 2016, 11:23 a.m. UTC
Use IEEE80211_MIN_ACTION_SIZE macro for robust management frame check.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
---
 include/linux/ieee80211.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Johannes Berg June 28, 2016, 10:50 a.m. UTC | #1
On Wed, 2016-06-22 at 20:23 +0900, Masashi Honma wrote:
> Use IEEE80211_MIN_ACTION_SIZE macro for robust management frame
> check.
> 
Applied.

johannes
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h
index 7c0771a..8326a91 100644
--- a/include/linux/ieee80211.h
+++ b/include/linux/ieee80211.h
@@ -2465,7 +2465,7 @@  static inline bool _ieee80211_is_robust_mgmt_frame(struct ieee80211_hdr *hdr)
  */
 static inline bool ieee80211_is_robust_mgmt_frame(struct sk_buff *skb)
 {
-	if (skb->len < 25)
+	if (skb->len < IEEE80211_MIN_ACTION_SIZE)
 		return false;
 	return _ieee80211_is_robust_mgmt_frame((void *)skb->data);
 }