staging: rtl8188eu: Remove function rtw_setdatarate_cmd()
authornavin patidar <navin.patidar@gmail.com>
Thu, 10 Jul 2014 03:42:06 +0000 (09:12 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 10 Jul 2014 04:14:35 +0000 (21:14 -0700)
rtw_setdatarate_cmd() enqueue _SetDataRate command but there is not
handler mapped in wlancmds[] to handle this command.

Signed-off-by: navin patidar <navin.patidar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/core/rtw_cmd.c
drivers/staging/rtl8188eu/include/rtw_cmd.h
drivers/staging/rtl8188eu/os_dep/ioctl_linux.c

index e140325..08980ec 100644 (file)
@@ -344,37 +344,6 @@ u8 rtw_sitesurvey_cmd(struct adapter  *padapter, struct ndis_802_11_ssid *ssid,
        return res;
 }
 
-u8 rtw_setdatarate_cmd(struct adapter *padapter, u8 *rateset)
-{
-       struct cmd_obj *ph2c;
-       struct setdatarate_parm *pbsetdataratepara;
-       struct cmd_priv *pcmdpriv = &padapter->cmdpriv;
-       u8      res = _SUCCESS;
-
-
-       ph2c = kzalloc(sizeof(struct cmd_obj), GFP_KERNEL);
-       if (ph2c == NULL) {
-               res = _FAIL;
-               goto exit;
-       }
-
-       pbsetdataratepara = kzalloc(sizeof(struct setdatarate_parm), GFP_KERNEL);
-       if (pbsetdataratepara == NULL) {
-               kfree(ph2c);
-               res = _FAIL;
-               goto exit;
-       }
-
-       init_h2fwcmd_w_parm_no_rsp(ph2c, pbsetdataratepara, GEN_CMD_CODE(_SetDataRate));
-       pbsetdataratepara->mac_id = 5;
-       memcpy(pbsetdataratepara->datarates, rateset, NumRates);
-       res = rtw_enqueue_cmd(pcmdpriv, ph2c);
-exit:
-
-
-       return res;
-}
-
 void rtw_readtssi_cmdrsp_callback(struct adapter *padapter,  struct cmd_obj *pcmd)
 {
 
index 3f3f257..47fdef1 100644 (file)
@@ -468,8 +468,6 @@ u8 rtw_disassoc_cmd(struct adapter *padapter, u32 deauth_timeout_ms,
                    bool enqueue);
 u8 rtw_setopmode_cmd(struct adapter *padapter,
                     enum ndis_802_11_network_infra networktype);
-u8 rtw_setdatarate_cmd(struct adapter *padapter, u8 *rateset);
-
 u8 rtw_addbareq_cmd(struct adapter *padapter, u8 tid, u8 *addr);
 
 u8 rtw_dynamic_chk_wk_cmd(struct adapter *adapter);
index 1f46ade..d9cee8c 100644 (file)
@@ -1417,7 +1417,6 @@ static int rtw_wx_set_rate(struct net_device *dev,
                              union iwreq_data *wrqu, char *extra)
 {
        int i, ret = 0;
-       struct adapter *padapter = (struct adapter *)rtw_netdev_priv(dev);
        u8 datarates[NumRates];
        u32     target_rate = wrqu->bitrate.value;
        u32     fixed = wrqu->bitrate.fixed;
@@ -1490,12 +1489,6 @@ set_rate:
                RT_TRACE(_module_rtl871x_ioctl_os_c, _drv_info_, ("datarate_inx =%d\n", datarates[i]));
        }
 
-       if (rtw_setdatarate_cmd(padapter, datarates) != _SUCCESS) {
-               RT_TRACE(_module_rtl871x_ioctl_os_c, _drv_err_, ("rtw_wx_set_rate Fail!!!\n"));
-               ret = -1;
-       }
-
-
        return ret;
 }