From patchwork Tue Jun 2 08:55:06 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanislav Kholmanskikh X-Patchwork-Id: 6527591 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 EAB7B9F1CC for ; Tue, 2 Jun 2015 08:55:24 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id F3E36204AB for ; Tue, 2 Jun 2015 08:55:23 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D7949204A7 for ; Tue, 2 Jun 2015 08:55:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755082AbbFBIzV (ORCPT ); Tue, 2 Jun 2015 04:55:21 -0400 Received: from mail-wi0-f174.google.com ([209.85.212.174]:37426 "EHLO mail-wi0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753146AbbFBIzS (ORCPT ); Tue, 2 Jun 2015 04:55:18 -0400 Received: by wifw1 with SMTP id w1so135818451wif.0; Tue, 02 Jun 2015 01:55:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=vDRRW0bDAt7HzS8jIIPvM2NqPvs5eCauQJ+bsOKGFLw=; b=R8B0KL2ofteaWQEPKfWdypN5uzP+HJ572ILAfFciZU628UE49QndnBb+ff7Jt7fL8x Wowxdi7XpvfYTMUKKbqxuO2ZGujg7TBk9Td3+7iA9VPVl4CMU2P+BvrkZzyEvA13hAGH tb8OgLnDTzTotXjf4NP4ebUgSAU7n5E3ZQvN7LrjJwDvTZaqCiHJzrHwLrS0KiZw+oU+ 79grVsDfBYmEP2sn0cLtPpEqL3K6FcS0EGKej362C82QNMtkP/vG94fbkSa6t06e06+a XF3Gt7a5RdyvZAp3JhPeSFVb4LciYji8ECWMdxCkpJ7LBG+hZ7RkEwHzAkdPosJJx5jE kVcQ== X-Received: by 10.180.102.227 with SMTP id fr3mr28245530wib.19.1433235317258; Tue, 02 Jun 2015 01:55:17 -0700 (PDT) Received: from ubuntu-pc.ru.oracle.com (ukc1-proxy-mwg01-o.oracle.com. [144.24.20.226]) by mx.google.com with ESMTPSA id u7sm20521061wif.3.2015.06.02.01.55.15 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 02 Jun 2015 01:55:16 -0700 (PDT) From: Stanislav Kholmanskikh To: gregkh@linuxfoundation.org, johnny.kim@atmel.com, rachel.kim@atmel.com, dean.lee@atmel.com, chris.park@atmel.com, devel@driverdev.osuosl.org Cc: linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, Stanislav Kholmanskikh Subject: [PATCH v3 1/2] staging: wilc1000: Cleanup to coreconfigurator Date: Tue, 2 Jun 2015 12:55:06 +0400 Message-Id: <1433235307-13146-1-git-send-email-kholmanskikh.s.s@gmail.com> X-Mailer: git-send-email 1.9.1 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.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 Fixed several syntax/style issues found with checkpatch.pl. Signed-off-by: Stanislav Kholmanskikh --- Changes since V2: * The first 2 patches were removed, because what they fix is already fixed now. drivers/staging/wilc1000/coreconfigurator.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/staging/wilc1000/coreconfigurator.c b/drivers/staging/wilc1000/coreconfigurator.c index e3e3f20..43864dc 100644 --- a/drivers/staging/wilc1000/coreconfigurator.c +++ b/drivers/staging/wilc1000/coreconfigurator.c @@ -28,7 +28,7 @@ #define INVALID 255 #define MAC_ADDR_LEN 6 #define TAG_PARAM_OFFSET (MAC_HDR_LEN + TIME_STAMP_LEN + \ - BEACON_INTERVAL_LEN + CAP_INFO_LEN) + BEACON_INTERVAL_LEN + CAP_INFO_LEN) /*****************************************************************************/ /* Function Macros */ @@ -672,14 +672,14 @@ INLINE WILC_Uint16 get_asoc_id(u8 *data) WILC_Sint32 CoreConfiguratorInit(void) { WILC_Sint32 s32Error = WILC_SUCCESS; - PRINT_D(CORECONFIG_DBG, "CoreConfiguratorInit() \n"); + PRINT_D(CORECONFIG_DBG, "CoreConfiguratorInit()\n"); sema_init(&SemHandleSendPkt, 1); sema_init(&SemHandlePktResp, 0); gps8ConfigPacket = (WILC_Sint8 *)WILC_MALLOC(MAX_PACKET_BUFF_SIZE); if (gps8ConfigPacket == NULL) { - PRINT_ER("failed in gps8ConfigPacket allocation \n"); + PRINT_ER("failed in gps8ConfigPacket allocation\n"); s32Error = WILC_NO_MEM; goto _fail_; } @@ -710,13 +710,13 @@ u8 *get_tim_elm(u8 *pu8msa, WILC_Uint16 u16RxLen, WILC_Uint16 u16TagParamOffset) /* Search for the TIM Element Field and return if the element is found */ while (u16index < (u16RxLen - FCS_LEN)) { if (pu8msa[u16index] == ITIM) { - return(&pu8msa[u16index]); + return &pu8msa[u16index]; } else { u16index += (IE_HDR_LEN + pu8msa[u16index + 1]); } } - return(0); + return 0; } /* This function gets the current channel information from @@ -728,7 +728,7 @@ u8 get_current_channel_802_11n(u8 *pu8msa, WILC_Uint16 u16RxLen) index = TAG_PARAM_OFFSET; while (index < (u16RxLen - FCS_LEN)) { if (pu8msa[index] == IDSPARMS) - return (pu8msa[index + 2]); + return pu8msa[index + 2]; else /* Increment index by length information and header */ index += pu8msa[index + 1] + IE_HDR_LEN; @@ -750,7 +750,7 @@ u8 get_current_channel(u8 *pu8msa, WILC_Uint16 u16RxLen) #else /* FIVE_GHZ_BAND */ /* Extract current channel information from */ /* the beacon/probe response frame */ - return (get_current_channel_802_11n(pu8msa, u16RxLen)); + return get_current_channel_802_11n(pu8msa, u16RxLen); #endif /* FIVE_GHZ_BAND */ #else return 0; @@ -1444,7 +1444,7 @@ void ProcessAdrWid(WILC_Char *pcPacket, WILC_Sint32 *ps32PktLen, void ProcessBinWid(WILC_Char *pcPacket, WILC_Sint32 *ps32PktLen, tstrWID *pstrWID, u8 *pu8val, WILC_Sint32 s32ValueSize) { - /* WILC_ERROR("processing Binary WIDs is not supported \n"); */ + /* WILC_ERROR("processing Binary WIDs is not supported\n"); */ WILC_Uint16 u16MsgLen = 0; WILC_Uint16 idx = 0; @@ -1583,7 +1583,7 @@ WILC_Sint32 further_process_response(u8 *resp, WILC_memcpy(pstrWIDresult->ps8WidVal, cfg_str, cfg_len); /* mostafa: no need currently for the extra NULL byte */ pstrWIDresult->s32ValueSize = cfg_len; } else { - PRINT_ER("allocated WID buffer length is smaller than the received WID Length \n"); + PRINT_ER("allocated WID buffer length is smaller than the received WID Length\n"); retval = -2; } @@ -2027,7 +2027,7 @@ WILC_Sint32 ConfigProvideResponse(WILC_Char *pcRespBuffer, WILC_Sint32 s32RespLe } else { WILC_memcpy(gstrConfigPktInfo.pcRespBuffer, pcRespBuffer, gstrConfigPktInfo.s32MaxRespBuffLen); gstrConfigPktInfo.s32BytesRead = gstrConfigPktInfo.s32MaxRespBuffLen; - PRINT_ER("BusProvideResponse() Response greater than the prepared Buffer Size \n"); + PRINT_ER("BusProvideResponse() Response greater than the prepared Buffer Size\n"); } up(&SemHandlePktResp); @@ -2076,7 +2076,7 @@ WILC_Sint32 ConfigPktReceived(u8 *pu8RxPacket, WILC_Sint32 s32RxPacketLen) break; default: - PRINT_ER("ConfigPktReceived(): invalid received msg type at the Core Configurator \n"); + PRINT_ER("ConfigPktReceived(): invalid received msg type at the Core Configurator\n"); break; } @@ -2097,7 +2097,7 @@ WILC_Sint32 CoreConfiguratorDeInit(void) { WILC_Sint32 s32Error = WILC_SUCCESS; - PRINT_D(CORECONFIG_DBG, "CoreConfiguratorDeInit() \n"); + PRINT_D(CORECONFIG_DBG, "CoreConfiguratorDeInit()\n"); if (gps8ConfigPacket != NULL) {