]> git.karo-electronics.de Git - linux-beck.git/commitdiff
Staging: wilc1000: coreconfigurator: Remove irrelevant wrapper function
authorShivani Bhardwaj <shivanib134@gmail.com>
Mon, 26 Oct 2015 14:51:05 +0000 (20:21 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 27 Oct 2015 05:27:27 +0000 (14:27 +0900)
Remove the function get_current_channel() and replace its calls by
get_current_channel_802_11n() as the former function's definition
involves only returning the value of latter function.
Semantic patch used to find out the issue:

@@
identifier f,g;
@@

*f(...) {
 return g(...); }

Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wilc1000/coreconfigurator.c

index 6dfe26d5ccc0892b29e56ea7622eab95e4c1e6b8..1403a33f680f0a9c78c5c15174e66768e7e203d4 100644 (file)
@@ -331,13 +331,6 @@ u8 get_current_channel_802_11n(u8 *pu8msa, u16 u16RxLen)
        return 0;  /* no MIB here */
 }
 
-u8 get_current_channel(u8 *pu8msa, u16 u16RxLen)
-{
-       /* Extract current channel information from */
-       /* the beacon/probe response frame          */
-       return get_current_channel_802_11n(pu8msa, u16RxLen);
-}
-
 /**
  *  @brief                      parses the received 'N' message
  *  @details
@@ -425,8 +418,12 @@ s32 parse_network_info(u8 *pu8MsgBuffer, tstrNetworkInfo **ppstrNetworkInfo)
                /* Get BSSID */
                get_BSSID(pu8msa, pstrNetworkInfo->au8bssid);
 
-               /* Get the current channel */
-               pstrNetworkInfo->u8channel = get_current_channel(pu8msa, (u16RxLen + FCS_LEN));
+               /* 
+                * Extract current channel information from
+                * the beacon/probe response frame          
+                */
+               pstrNetworkInfo->u8channel = get_current_channel_802_11n(pu8msa,
+                                                       (u16RxLen + FCS_LEN));
 
                /* Get beacon period */
                u8index = (MAC_HDR_LEN + TIME_STAMP_LEN);