From patchwork Mon Oct 5 06:25:53 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tony Cho X-Patchwork-Id: 7324881 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 983839F302 for ; Mon, 5 Oct 2015 06:28:08 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7E06820670 for ; Mon, 5 Oct 2015 06:28:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B8B7320501 for ; Mon, 5 Oct 2015 06:28:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752247AbbJEG2B (ORCPT ); Mon, 5 Oct 2015 02:28:01 -0400 Received: from eusmtp01.atmel.com ([212.144.249.242]:9031 "EHLO eusmtp01.atmel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752242AbbJEG2A (ORCPT ); Mon, 5 Oct 2015 02:28:00 -0400 Received: from tony-itx.corp.atmel.com (10.161.101.13) by eusmtp01.atmel.com (10.161.101.30) with Microsoft SMTP Server id 14.3.235.1; Mon, 5 Oct 2015 08:27:58 +0200 From: Tony Cho To: CC: , , , , , , , , , , , Subject: [PATCH 18/18] staging: wilc1000: host_interface.c : remove unused functions Date: Mon, 5 Oct 2015 15:25:53 +0900 Message-ID: <1444026353-29024-18-git-send-email-tony.cho@atmel.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1444026353-29024-1-git-send-email-tony.cho@atmel.com> References: <1444026353-29024-1-git-send-email-tony.cho@atmel.com> MIME-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Leo Kim This patch removes unused functions from the host_interface.c(h). - Switch_Log_Terminal - Handle_DelBASession - host_int_addBASession This patch includes the removal of the comment for host_int_addBASession as well. Signed-off-by: Leo Kim Signed-off-by: Tony Cho --- drivers/staging/wilc1000/host_interface.c | 143 ------------------------------ drivers/staging/wilc1000/host_interface.h | 4 - 2 files changed, 147 deletions(-) diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index dd444d1..dbaebad 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -2260,7 +2260,6 @@ static s32 Handle_RcvdGnrlAsyncInfo(tstrWILC_WFIDrv *drvHandler, /* open a BA session if possible */ /* if(pstrWFIDrv->strWILC_UsrConnReq.IsHTCapable) */ - /* host_int_addBASession(pstrWFIDrv->strWILC_UsrConnReq.pu8bssid,0, */ /* BA_SESSION_DEFAULT_BUFFER_SIZE,BA_SESSION_DEFAULT_TIMEOUT); */ } else { PRINT_D(HOSTINF_DBG, "MAC status : %d and Connect Status : %d\n", u8MacStatus, strConnectInfo.u16ConnectStatus); @@ -2884,34 +2883,6 @@ void resolve_disconnect_aberration(tstrWILC_WFIDrv *drvHandler) host_int_disconnect(pstrWFIDrv, 1); } } -static s32 Switch_Log_Terminal(tstrWILC_WFIDrv *drvHandler) -{ - - - s32 s32Error = 0; - tstrWID strWID; - static char dummy = 9; - tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler; - - strWID.u16WIDid = (u16)WID_LOGTerminal_Switch; - strWID.enuWIDtype = WID_CHAR; - strWID.ps8WidVal = &dummy; - strWID.s32ValueSize = sizeof(char); - - s32Error = send_config_pkt(SET_CFG, &strWID, 1, true, - get_id_from_handler(pstrWFIDrv)); - - - if (s32Error) { - PRINT_D(HOSTINF_DBG, "Failed to switch log terminal\n"); - PRINT_ER("Failed to switch log terminal\n"); - return -EINVAL; - } - - PRINT_INFO(HOSTINF_DBG, "MAC address set ::\n"); - - return s32Error; -} /** * @brief Handle_GetChnl @@ -3870,79 +3841,6 @@ static s32 Handle_AddBASession(tstrWILC_WFIDrv *drvHandler, } - -/** - * @brief Handle_DelBASession - * @details Delete block ack session - * @param[in] tstrHostIFSetMulti* strHostIfSetMulti - * @return NONE - * @author Amr Abdel-Moghny - * @date Feb. 2013 - * @version 9.0 - */ -static s32 Handle_DelBASession(tstrWILC_WFIDrv *drvHandler, - struct ba_session_info *strHostIfBASessionInfo) -{ - s32 s32Error = 0; - tstrWID strWID; - char *ptr = NULL; - tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)drvHandler; - - PRINT_D(GENERIC_DBG, "Delete Block Ack session with\nBSSID = %.2x:%.2x:%.2x\nTID=%d\n", - strHostIfBASessionInfo->au8Bssid[0], - strHostIfBASessionInfo->au8Bssid[1], - strHostIfBASessionInfo->au8Bssid[2], - strHostIfBASessionInfo->u8Ted); - - strWID.u16WIDid = (u16)WID_11E_P_ACTION_REQ; - strWID.enuWIDtype = WID_STR; - strWID.ps8WidVal = kmalloc(BLOCK_ACK_REQ_SIZE, GFP_KERNEL); - strWID.s32ValueSize = BLOCK_ACK_REQ_SIZE; - ptr = strWID.ps8WidVal; - /* *ptr++ = 0x14; */ - *ptr++ = 0x14; - *ptr++ = 0x3; - *ptr++ = 0x2; - memcpy(ptr, strHostIfBASessionInfo->au8Bssid, ETH_ALEN); - ptr += ETH_ALEN; - *ptr++ = strHostIfBASessionInfo->u8Ted; - /* BA direction = recipent*/ - *ptr++ = 0; - /* Delba Reason */ - *ptr++ = 32; /* Unspecific QOS reason */ - - s32Error = send_config_pkt(SET_CFG, &strWID, 1, true, - get_id_from_handler(pstrWFIDrv)); - if (s32Error) - PRINT_D(HOSTINF_DBG, "Couldn't delete BA Session\n"); - - - strWID.u16WIDid = (u16)WID_11E_P_ACTION_REQ; - strWID.enuWIDtype = WID_STR; - strWID.s32ValueSize = 15; - ptr = strWID.ps8WidVal; - /* *ptr++ = 0x14; */ - *ptr++ = 15; - *ptr++ = 7; - *ptr++ = 0x3; - memcpy(ptr, strHostIfBASessionInfo->au8Bssid, ETH_ALEN); - ptr += ETH_ALEN; - /* TID*/ - *ptr++ = strHostIfBASessionInfo->u8Ted; - - s32Error = send_config_pkt(SET_CFG, &strWID, 1, true, - get_id_from_handler(pstrWFIDrv)); - - if (strWID.ps8WidVal != NULL) - kfree(strWID.ps8WidVal); - - up(&hWaitResponse); - - return s32Error; - -} - - /** * @brief Handle_DelAllRxBASessions * @details Delete all Rx BA sessions @@ -7097,47 +6995,6 @@ void host_int_freeJoinParams(void *pJoinParams) PRINT_ER("Unable to FREE null pointer\n"); } -/** - * @brief host_int_addBASession - * @details Open a block Ack session with the given parameters - * @param[in] tstrNetworkInfo* ptstrNetworkInfo - * @return - * @author anoureldin - * @date - * @version 1.0**/ - -static int host_int_addBASession(tstrWILC_WFIDrv *hWFIDrv, char *pBSSID, char TID, short int BufferSize, - short int SessionTimeout, void *drvHandler) -{ - s32 s32Error = 0; - tstrWILC_WFIDrv *pstrWFIDrv = (tstrWILC_WFIDrv *)hWFIDrv; - struct host_if_msg msg; - struct ba_session_info *pBASessionInfo = &msg.body.session_info; - - if (pstrWFIDrv == NULL) { - PRINT_ER("driver is null\n"); - return -EFAULT; - } - - memset(&msg, 0, sizeof(struct host_if_msg)); - - /* prepare the WiphyParams Message */ - msg.id = HOST_IF_MSG_ADD_BA_SESSION; - - memcpy(pBASessionInfo->au8Bssid, pBSSID, ETH_ALEN); - pBASessionInfo->u8Ted = TID; - pBASessionInfo->u16BufferSize = BufferSize; - pBASessionInfo->u16SessionTimeout = SessionTimeout; - msg.drvHandler = hWFIDrv; - - s32Error = wilc_mq_send(&gMsgQHostIF, &msg, sizeof(struct host_if_msg)); - if (s32Error) - PRINT_ER("wilc_mq_send fail\n"); - - return s32Error; -} - - s32 host_int_delBASession(tstrWILC_WFIDrv *hWFIDrv, char *pBSSID, char TID) { s32 s32Error = 0; diff --git a/drivers/staging/wilc1000/host_interface.h b/drivers/staging/wilc1000/host_interface.h index 7c2846e..7391903 100644 --- a/drivers/staging/wilc1000/host_interface.h +++ b/drivers/staging/wilc1000/host_interface.h @@ -1191,10 +1191,6 @@ s32 host_int_set_operation_mode(tstrWILC_WFIDrv *hWFIDrv, u32 u32mode); static s32 Handle_ScanDone(tstrWILC_WFIDrv *drvHandler, tenuScanEvent enuEvent); -static int host_int_addBASession(tstrWILC_WFIDrv *hWFIDrv, char *pBSSID, char TID, short int BufferSize, - short int SessionTimeout, void *drvHandler); - - void host_int_freeJoinParams(void *pJoinParams); s32 host_int_get_statistics(tstrWILC_WFIDrv *hWFIDrv, tstrStatistics *pstrStatistics);