]> git.karo-electronics.de Git - linux-beck.git/commitdiff
Staging: rtl8192e: Fix Sparse warning of restricted __le16 degrades to integer in...
authorRashika Kheria <rashika.kheria@gmail.com>
Thu, 7 Nov 2013 13:26:28 +0000 (18:56 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 10 Nov 2013 20:01:35 +0000 (12:01 -0800)
This patch fixes the following Sparse warning in rtllib_softmac.c-
drivers/staging/rtl8192e/rtllib_softmac.c:230:19: warning: restricted __le16 degrades to integer

Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8192e/rtllib_softmac.c

index 933bd6deaca123035dd271dfd0ddf67bbc290e57..0ad159f52d4c3ad1be5e77c6d230126c485c2ad8 100644 (file)
@@ -227,7 +227,7 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct rtllib_device *ieee)
        /* called with 2nd param 0, no mgmt lock required */
        rtllib_sta_wakeup(ieee, 0);
 
-       if (header->frame_ctl == RTLLIB_STYPE_BEACON)
+       if (le16_to_cpu(header->frame_ctl) == RTLLIB_STYPE_BEACON)
                tcb_desc->queue_index = BEACON_QUEUE;
        else
                tcb_desc->queue_index = MGNT_QUEUE;