From nobody Wed Apr 8 06:37:59 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1FE06ECAAA1 for ; Fri, 28 Oct 2022 17:41:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230030AbiJ1RlS (ORCPT ); Fri, 28 Oct 2022 13:41:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45064 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229971AbiJ1RlN (ORCPT ); Fri, 28 Oct 2022 13:41:13 -0400 Received: from mail-lj1-x236.google.com (mail-lj1-x236.google.com [IPv6:2a00:1450:4864:20::236]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5788733D5 for ; Fri, 28 Oct 2022 10:41:12 -0700 (PDT) Received: by mail-lj1-x236.google.com with SMTP id o4so9248056ljp.8 for ; Fri, 28 Oct 2022 10:41:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=5iA9FQCCsPWBm44+xNI1z9eJC+PJ5gHzpB5ZmyGrAxc=; b=qcnKddy3yTCU5aLuceyXydyTteujQvtbrdlFMeIPN8+Bpxxd9DsPvm4NULnuzugHaQ 1ms4rnHqKkUjjF38BUBDa6CQEmA9mok6NBtdBE7IVznn31tc2vUuT2oVVSnVuRndxqe+ KRa/4KuR5eILFSvpnmOtsWxINWk+GJ9xOKUa3514UME54L4lksxbcxU0sf5f1110ze1I cvYttmvMfxZPMaReTyojaL6oHpSveNSmdRrGqp9bOKAa0aeHgLImQ1R3h/kZbmCrCXl3 ztFP6YdHC/bIsnnc9Et/sX/AgnT1+8rZQ0gu5VdhJJZxk7YZbaafJNVRk0yH1JJcY8Mk 2/ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5iA9FQCCsPWBm44+xNI1z9eJC+PJ5gHzpB5ZmyGrAxc=; b=HewHOF57zBwwzvASwTxDvqNoqFgPlVe7Dw2z71Fvu56LGy9JK5qzuoKV3+Sg8fEn0c 6o/RJ1gSGfhcMxQduHL1Ykma9fnGHWd5FYuMtFebeiP1w6B5slbkDb+4tEzd1MQe8nNi pcEmgKShDxzvUeb8lSJ/ednpKd1BSBXjqAs+KtIfL6WOuoUmq/DPydb7LDnbuob+kYp4 0Ndz5R8PaYQjGss/GgG8CrvvrkB1dxlK/YoUbcA3Qt+HCFuv+7eJ0HAz562jq6Mp/yWp ju1TAM0e6aIWM+fKZevdmyOhC17kanYAX7liXuDczFJvgCypn/hSSye43BhPmv9TxIjK mZjQ== X-Gm-Message-State: ACrzQf2CK2pdEnDmCTQXEDOPUYXSPmsbVcXUTGUP3ZBiMCEbLjuwPcLE 4SnxePNBBuYYURmEMesay2M= X-Google-Smtp-Source: AMsMyM4kynLWxKg4+8XmaKXXtiIQHfLnI8847IdtUkL+fKzVY18QuHAPKDvh4rol/hZxww+ytA1+zA== X-Received: by 2002:a2e:bd86:0:b0:26d:e64e:c230 with SMTP id o6-20020a2ebd86000000b0026de64ec230mr241489ljq.405.1666978870954; Fri, 28 Oct 2022 10:41:10 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id s2-20020a2eb622000000b0026dfdcbccdasm725322ljn.14.2022.10.28.10.41.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 10:41:10 -0700 (PDT) From: Tanjuate Brunostar To: gregkh@linuxfoundation.org Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH v8 1/6] staging: vt6655: fix lines ending in a '(' Date: Fri, 28 Oct 2022 17:40:53 +0000 Message-Id: <6742e42999e05ddf09318a0a3bda9ce23b6ae562.1666978292.git.tanjubrunostar0@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" fix serveral checkpatch errors related to lines ending with a '(' by refactoring the code lines Signed-off-by: Tanjuate Brunostar --- drivers/staging/vt6655/rxtx.c | 165 ++++++++++++++-------------------- 1 file changed, 69 insertions(+), 96 deletions(-) diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 1e5036121665..7eb7c6eb5cf0 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -139,15 +139,11 @@ static __le16 vnt_time_stamp_off(struct vnt_private *= priv, u16 rate) * PK_TYPE_11GB 2 * PK_TYPE_11GA 3 */ -static -unsigned int -s_uGetTxRsvTime( - struct vnt_private *pDevice, - unsigned char byPktType, - unsigned int cbFrameLength, - unsigned short wRate, - bool bNeedAck -) +static unsigned int s_uGetTxRsvTime(struct vnt_private *pDevice, + unsigned char byPktType, + unsigned int cbFrameLength, + unsigned short wRate, + bool bNeedAck) { unsigned int uDataTime, uAckTime; =20 @@ -214,20 +210,16 @@ static __le16 get_rtscts_time(struct vnt_private *pri= v, } =20 /* byFreqType 0: 5GHz, 1:2.4Ghz */ -static -unsigned int -s_uGetDataDuration( - struct vnt_private *pDevice, - unsigned char byDurType, - unsigned int cbFrameLength, - unsigned char byPktType, - unsigned short wRate, - bool bNeedAck, - unsigned int uFragIdx, - unsigned int cbLastFragmentSize, - unsigned int uMACfragNum, - unsigned char byFBOption -) +static unsigned int s_uGetDataDuration(struct vnt_private *pDevice, + unsigned char byDurType, + unsigned int cbFrameLength, + unsigned char byPktType, + unsigned short wRate, + bool bNeedAck, + unsigned int uFragIdx, + unsigned int cbLastFragmentSize, + unsigned int uMACfragNum, + unsigned char byFBOption) { bool bLastFrag =3D false; unsigned int uAckTime =3D 0, uNextPktTime =3D 0, len; @@ -316,17 +308,13 @@ s_uGetDataDuration( } =20 /* byFreqType: 0=3D>5GHZ 1=3D>2.4GHZ */ -static -__le16 -s_uGetRTSCTSDuration( - struct vnt_private *pDevice, - unsigned char byDurType, - unsigned int cbFrameLength, - unsigned char byPktType, - unsigned short wRate, - bool bNeedAck, - unsigned char byFBOption -) +static __le16 s_uGetRTSCTSDuration(struct vnt_private *pDevice, + unsigned char byDurType, + unsigned int cbFrameLength, + unsigned char byPktType, + unsigned short wRate, + bool bNeedAck, + unsigned char byFBOption) { unsigned int uCTSTime =3D 0, uDurTime =3D 0; =20 @@ -409,22 +397,18 @@ s_uGetRTSCTSDuration( return cpu_to_le16((u16)uDurTime); } =20 -static -__le16 -s_uFillDataHead( - struct vnt_private *pDevice, - unsigned char byPktType, - void *pTxDataHead, - unsigned int cbFrameLength, - unsigned int uDMAIdx, - bool bNeedAck, - unsigned int uFragIdx, - unsigned int cbLastFragmentSize, - unsigned int uMACfragNum, - unsigned char byFBOption, - unsigned short wCurrentRate, - bool is_pspoll -) +static __le16 s_uFillDataHead(struct vnt_private *pDevice, + unsigned char byPktType, + void *pTxDataHead, + unsigned int cbFrameLength, + unsigned int uDMAIdx, + bool bNeedAck, + unsigned int uFragIdx, + unsigned int cbLastFragmentSize, + unsigned int uMACfragNum, + unsigned char byFBOption, + unsigned short wCurrentRate, + bool is_pspoll) { struct vnt_tx_datahead_ab *buf =3D pTxDataHead; =20 @@ -555,19 +539,15 @@ s_uFillDataHead( return buf->duration; } =20 -static -void -s_vFillRTSHead( - struct vnt_private *pDevice, - unsigned char byPktType, - void *pvRTS, - unsigned int cbFrameLength, - bool bNeedAck, - bool bDisCRC, - struct ieee80211_hdr *hdr, - unsigned short wCurrentRate, - unsigned char byFBOption -) +static void s_vFillRTSHead(struct vnt_private *pDevice, + unsigned char byPktType, + void *pvRTS, + unsigned int cbFrameLength, + bool bNeedAck, + bool bDisCRC, + struct ieee80211_hdr *hdr, + unsigned short wCurrentRate, + unsigned char byFBOption) { unsigned int uRTSFrameLen =3D 20; =20 @@ -750,19 +730,15 @@ s_vFillRTSHead( } } =20 -static -void -s_vFillCTSHead( - struct vnt_private *pDevice, - unsigned int uDMAIdx, - unsigned char byPktType, - void *pvCTS, - unsigned int cbFrameLength, - bool bNeedAck, - bool bDisCRC, - unsigned short wCurrentRate, - unsigned char byFBOption -) +static void s_vFillCTSHead(struct vnt_private *pDevice, + unsigned int uDMAIdx, + unsigned char byPktType, + void *pvCTS, + unsigned int cbFrameLength, + bool bNeedAck, + bool bDisCRC, + unsigned short wCurrentRate, + unsigned char byFBOption) { unsigned int uCTSFrameLen =3D 14; =20 @@ -868,21 +844,17 @@ s_vFillCTSHead( - * unsigned int cbFrameSize, Hdr+Payload+FCS */ -static -void -s_vGenerateTxParameter( - struct vnt_private *pDevice, - unsigned char byPktType, - struct vnt_tx_fifo_head *tx_buffer_head, - void *pvRrvTime, - void *pvRTS, - void *pvCTS, - unsigned int cbFrameSize, - bool bNeedACK, - unsigned int uDMAIdx, - void *psEthHeader, - unsigned short wCurrentRate -) +static void s_vGenerateTxParameter(struct vnt_private *pDevice, + unsigned char byPktType, + struct vnt_tx_fifo_head *tx_buffer_head, + void *pvRrvTime, + void *pvRTS, + void *pvCTS, + unsigned int cbFrameSize, + bool bNeedACK, + unsigned int uDMAIdx, + void *psEthHeader, + unsigned short wCurrentRate) { u16 fifo_ctl =3D le16_to_cpu(tx_buffer_head->fifo_ctl); bool bDisCRC =3D false; @@ -954,11 +926,12 @@ s_vGenerateTxParameter( } } =20 -static unsigned int -s_cbFillTxBufHead(struct vnt_private *pDevice, unsigned char byPktType, - unsigned char *pbyTxBufferAddr, - unsigned int uDMAIdx, struct vnt_tx_desc *pHeadTD, - unsigned int is_pspoll) +static unsigned int s_cbFillTxBufHead(struct vnt_private *pDevice, + unsigned char byPktType, + unsigned char *pbyTxBufferAddr, + unsigned int uDMAIdx, + struct vnt_tx_desc *pHeadTD, + unsigned int is_pspoll) { struct vnt_td_info *td_info =3D pHeadTD->td_info; struct sk_buff *skb =3D td_info->skb; --=20 2.34.1 From nobody Wed Apr 8 06:37:59 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 90422C38A02 for ; Fri, 28 Oct 2022 17:41:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230046AbiJ1RlW (ORCPT ); Fri, 28 Oct 2022 13:41:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230019AbiJ1RlQ (ORCPT ); Fri, 28 Oct 2022 13:41:16 -0400 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A1ED8733D5 for ; Fri, 28 Oct 2022 10:41:14 -0700 (PDT) Received: by mail-lj1-x22c.google.com with SMTP id o4so9248168ljp.8 for ; Fri, 28 Oct 2022 10:41:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=GisTkrXG4tQARuScMo9w+It1weHIQ73W/nVCSWIv2to=; b=iJxEawULyj876KthDDUAfaglYp3W+eFseSjLF462+jp2oDP+7q31wylTtdCpXFQJ1i NuyQcqL1qXjg64u/XHruv2A5U7XbX4MwoUmOFPY1SWbnPaO8N1PaFwdhz6ixq3G+/Fzi eVUDSctCOkmC8yXVJ2WzbVEUYjj7BXAFVF7F5TmAeWrqGzFy2U5MtfwUA1JSFn+kwft4 oScd5KivCPrH4mL55XhAnGCX4EFkW8pZQLCCuMujy1wEnT9TRVbawKU5Gzb1sk0yTKAz OLGTvfYiGpZbzXf1knqviR+bGrDY9/JEHWDMd+RmPCfiAtWZDBjOcUKnZF2RhY1v7WUR vQRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GisTkrXG4tQARuScMo9w+It1weHIQ73W/nVCSWIv2to=; b=f481GqHRgWVoltf+9A29QB54dql6X+Rwry59wszlFs081rAuIvRuCVTzjyZPBLnN59 xD+fS1WvvCeud7DFe2h/mRoqmEGXIHsftIz77B8GPRaQQtaLwGRpnhiFlVoJpsbiZ6mL Iu8UxECkiKKoisgh5SlGGRqXcryx9KLPfk4MG1HeqWjEcdPpoj2tO3eSqHt1Z8dQ9ccb NmOMMIU44aGsJgPwJdToIvleEtnByRrv4PZikQ2B2yHVCFtYjI6I7KcB3qFfFBxD3NBk JCQid/jqgoVjBeiYBMl74EMWgXW2byZwX9ZNrzfoZM/OOgLJQ0SDCiS3o+ClRMBPuKNi cxgw== X-Gm-Message-State: ACrzQf0ZNmU0PI0+ZF6naUGQX+4sKtxMX85QmbMw9nqTX4huXK/5Ixjd ghckeWA7UbA2NlBxBFHzxy5n5pp7pWvqGg== X-Google-Smtp-Source: AMsMyM5bZqqEqoaMeHxY9YXJaEuO8asOo/J0upeClq6Ifn6oeKqaja2vc++klidwXKohyatSuP74Vw== X-Received: by 2002:a05:651c:1a0d:b0:277:113c:9e89 with SMTP id by13-20020a05651c1a0d00b00277113c9e89mr248102ljb.245.1666978872786; Fri, 28 Oct 2022 10:41:12 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id s2-20020a2eb622000000b0026dfdcbccdasm725322ljn.14.2022.10.28.10.41.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 10:41:12 -0700 (PDT) From: Tanjuate Brunostar To: gregkh@linuxfoundation.org Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH v8 2/6] staging: vt6655: refactor long lines of code in s_uGetRTSCTSDuration Date: Fri, 28 Oct 2022 17:40:54 +0000 Message-Id: <0e6a307052d3a354a850a502e509f46baccdbe1e.1666978292.git.tanjubrunostar0@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" fix checkpatch errors by refactoring long lines of code in the function: s_= uGetRTSCTSDuration Signed-off-by: Tanjuate Brunostar --- drivers/staging/vt6655/rxtx.c | 108 ++++++++++++++++++++++++---------- 1 file changed, 76 insertions(+), 32 deletions(-) diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 7eb7c6eb5cf0..8e56a7ee8035 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -186,20 +186,29 @@ static __le16 get_rtscts_time(struct vnt_private *pri= v, =20 data_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, frame_leng= th, current_rate); if (rts_rsvtype =3D=3D 0) { /* RTSTxRrvTime_bb */ - rts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 20, priv->= byTopCCKBasicRate); - ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, priv->= byTopCCKBasicRate); + rts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 20, + priv->byTopCCKBasicRate); + ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, + priv->byTopCCKBasicRate); cts_time =3D ack_time; } else if (rts_rsvtype =3D=3D 1) { /* RTSTxRrvTime_ba, only in 2.4GHZ */ - rts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 20, priv->= byTopCCKBasicRate); - cts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, priv->= byTopCCKBasicRate); - ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, priv->= byTopOFDMBasicRate); + rts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 20, + priv->byTopCCKBasicRate); + cts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, + priv->byTopCCKBasicRate); + ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, + priv->byTopOFDMBasicRate); } else if (rts_rsvtype =3D=3D 2) { /* RTSTxRrvTime_aa */ - rts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 20, priv->= byTopOFDMBasicRate); - ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, priv->= byTopOFDMBasicRate); + rts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 20, + priv->byTopOFDMBasicRate); + ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, + priv->byTopOFDMBasicRate); cts_time =3D ack_time; } else if (rts_rsvtype =3D=3D 3) { /* CTSTxRrvTime_ba, only in 2.4GHZ */ - cts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, priv->= byTopCCKBasicRate); - ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, priv->= byTopOFDMBasicRate); + cts_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, + priv->byTopCCKBasicRate); + ack_time =3D bb_get_frame_time(priv->preamble_type, pkt_type, 14, + priv->byTopOFDMBasicRate); rrv_time =3D cts_time + ack_time + data_time + 2 * priv->uSIFS; return cpu_to_le16((u16)rrv_time); } @@ -320,73 +329,108 @@ static __le16 s_uGetRTSCTSDuration(struct vnt_privat= e *pDevice, =20 switch (byDurType) { case RTSDUR_BB: /* RTSDuration_bb */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopCCKBasicRate); - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, by= PktType, cbFrameLength, wRate, bNeedAck); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopCCKBasicRate); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, wRate, bNeedAck); break; =20 case RTSDUR_BA: /* RTSDuration_ba */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopCCKBasicRate); - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, by= PktType, cbFrameLength, wRate, bNeedAck); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopCCKBasicRate); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, wRate, bNeedAck); break; =20 case RTSDUR_AA: /* RTSDuration_aa */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopOFDMBasicRate); - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, by= PktType, cbFrameLength, wRate, bNeedAck); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopOFDMBasicRate); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, wRate, bNeedAck); break; =20 case CTSDUR_BA: /* CTSDuration_ba */ - uDurTime =3D pDevice->uSIFS + s_uGetTxRsvTime(pDevice, byPktType, cbFram= eLength, wRate, bNeedAck); + uDurTime =3D pDevice->uSIFS + s_uGetTxRsvTime(pDevice, byPktType, + cbFrameLength, wRate, bNeedAck); break; =20 case RTSDUR_BA_F0: /* RTSDuration_ba_f0 */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopCCKBasicRate); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopCCKBasicRate); if ((byFBOption =3D=3D AUTO_FB_0) && (wRate >=3D RATE_18M) && (wRate <= =3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt0[FB_RATE0][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt0[FB_RATE0][wRate - RATE_18M], bNeedAck); else if ((byFBOption =3D=3D AUTO_FB_1) && (wRate >=3D RATE_18M) && (wRat= e <=3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt1[FB_RATE0][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt1[FB_RATE0][wRate - RATE_18M], bNeedAck); =20 break; =20 case RTSDUR_AA_F0: /* RTSDuration_aa_f0 */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopOFDMBasicRate); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopOFDMBasicRate); if ((byFBOption =3D=3D AUTO_FB_0) && (wRate >=3D RATE_18M) && (wRate <= =3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt0[FB_RATE0][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt0[FB_RATE0][wRate - RATE_18M], bNeedAck); else if ((byFBOption =3D=3D AUTO_FB_1) && (wRate >=3D RATE_18M) && (wRat= e <=3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt1[FB_RATE0][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt1[FB_RATE0][wRate - RATE_18M], bNeedAck); =20 break; =20 case RTSDUR_BA_F1: /* RTSDuration_ba_f1 */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopCCKBasicRate); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopCCKBasicRate); if ((byFBOption =3D=3D AUTO_FB_0) && (wRate >=3D RATE_18M) && (wRate <= =3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt0[FB_RATE1][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt0[FB_RATE1][wRate - RATE_18M], bNeedAck); else if ((byFBOption =3D=3D AUTO_FB_1) && (wRate >=3D RATE_18M) && (wRat= e <=3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt1[FB_RATE1][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt1[FB_RATE1][wRate - RATE_18M], bNeedAck); =20 break; =20 case RTSDUR_AA_F1: /* RTSDuration_aa_f1 */ - uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, pD= evice->byTopOFDMBasicRate); + uCTSTime =3D bb_get_frame_time(pDevice->preamble_type, byPktType, 14, + pDevice->byTopOFDMBasicRate); if ((byFBOption =3D=3D AUTO_FB_0) && (wRate >=3D RATE_18M) && (wRate <= =3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt0[FB_RATE1][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt0[FB_RATE1][wRate - RATE_18M], bNeedAck); else if ((byFBOption =3D=3D AUTO_FB_1) && (wRate >=3D RATE_18M) && (wRat= e <=3D RATE_54M)) - uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + s_uGetTxRsvTime(pDevice, b= yPktType, cbFrameLength, wFB_Opt1[FB_RATE1][wRate - RATE_18M], bNeedAck); + uDurTime =3D uCTSTime + 2 * pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt1[FB_RATE1][wRate - RATE_18M], bNeedAck); =20 break; =20 case CTSDUR_BA_F0: /* CTSDuration_ba_f0 */ if ((byFBOption =3D=3D AUTO_FB_0) && (wRate >=3D RATE_18M) && (wRate <= =3D RATE_54M)) - uDurTime =3D pDevice->uSIFS + s_uGetTxRsvTime(pDevice, byPktType, cbFra= meLength, wFB_Opt0[FB_RATE0][wRate - RATE_18M], bNeedAck); + uDurTime =3D pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt0[FB_RATE0][wRate - RATE_18M], bNeedAck); else if ((byFBOption =3D=3D AUTO_FB_1) && (wRate >=3D RATE_18M) && (wRat= e <=3D RATE_54M)) - uDurTime =3D pDevice->uSIFS + s_uGetTxRsvTime(pDevice, byPktType, cbFra= meLength, wFB_Opt1[FB_RATE0][wRate - RATE_18M], bNeedAck); + uDurTime =3D pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt1[FB_RATE0][wRate - RATE_18M], bNeedAck); =20 break; =20 case CTSDUR_BA_F1: /* CTSDuration_ba_f1 */ if ((byFBOption =3D=3D AUTO_FB_0) && (wRate >=3D RATE_18M) && (wRate <= =3D RATE_54M)) - uDurTime =3D pDevice->uSIFS + s_uGetTxRsvTime(pDevice, byPktType, cbFra= meLength, wFB_Opt0[FB_RATE1][wRate - RATE_18M], bNeedAck); + uDurTime =3D pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt0[FB_RATE1][wRate - RATE_18M], bNeedAck); else if ((byFBOption =3D=3D AUTO_FB_1) && (wRate >=3D RATE_18M) && (wRat= e <=3D RATE_54M)) - uDurTime =3D pDevice->uSIFS + s_uGetTxRsvTime(pDevice, byPktType, cbFra= meLength, wFB_Opt1[FB_RATE1][wRate - RATE_18M], bNeedAck); + uDurTime =3D pDevice->uSIFS + + s_uGetTxRsvTime(pDevice, byPktType, cbFrameLength, + wFB_Opt1[FB_RATE1][wRate - RATE_18M], bNeedAck); =20 break; =20 --=20 2.34.1 From nobody Wed Apr 8 06:37:59 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 599D5ECAAA1 for ; Fri, 28 Oct 2022 17:41:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230048AbiJ1Rl2 (ORCPT ); Fri, 28 Oct 2022 13:41:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45148 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230016AbiJ1RlR (ORCPT ); Fri, 28 Oct 2022 13:41:17 -0400 Received: from mail-lj1-x22e.google.com (mail-lj1-x22e.google.com [IPv6:2a00:1450:4864:20::22e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 997881C73C2 for ; Fri, 28 Oct 2022 10:41:16 -0700 (PDT) Received: by mail-lj1-x22e.google.com with SMTP id a15so9250653ljb.7 for ; Fri, 28 Oct 2022 10:41:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8Mcq4XElldK8n+d5RjVbZo8PZpT7nLSBwi7AAq7x+9Q=; b=D3e25OU+HyDWqNN1fgasgYV3Vkbk7jwBXYjresdC3vESiCdk9dMq8VY0KfePh1bhaa alOiUdmtuuL/qxkDetqvvMwuGcADZTpHHC4e8lqiFU+2j/pg31QeEJZdTNMOx2JN1TS5 vZDv/T5/kx1RSGf2t5OQEM5r/LG6dM6M+1QVsPrjc3yW1EXTYaKihrLzwlX5wLys32RH d7fVGPOQDfrBhz+0Vywxh0N5UIaypCfZ2crHMY3IrBouabL+jjg+QiOhZ/rcNGz556rH tSxOFehPCsbRKxBX7uafACB60BAcoD/eV0FwJNgVZlP78J9gnNDwP5IeCuIHiUc+tbse YXzQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8Mcq4XElldK8n+d5RjVbZo8PZpT7nLSBwi7AAq7x+9Q=; b=gq+qj6ZlpoigHCLSBD1fOx0q1i/3uvhfPnvAQZ8j+vAqug8slV8RdKEkIJjM076t5v +gU0olzKkmkkNzanS1VFv0OOg4nOJpBOw9klUxvDrUuW2v5lxmW19hjjLujAXeuryNuf TCqUHidnfKQcGyMh5CkLV8lavxGiXN2nrV/jE4otg7OjP5UsxjgWrBhSFgzncuBsY2Bt +Gik/QywfGO07EamQX31JIJU4lCKiB5z4S6WWmCRZBiF1NvagRXMz21IOBXVZmz/alpV xvP7pyDRskivcXmC4+GkHjpupmoLkxhj8hRk+LjUa0tzjWrCZeeqE+/pB/N7cvEU5Ccb ecDw== X-Gm-Message-State: ACrzQf0IYxkt+mKEHDRj402m3/BIzoJIzhsVXRs2jQ6nYGDio4iYgy9W +nWrL1WWmc4xCKFtbNb0MfM= X-Google-Smtp-Source: AMsMyM4JZ6JEnInv/iWxYNaboR0DAxnAIjGH6SPMnVMPNFq7ghm31fy/lYM4VKJAkuNntsVB6dCnGw== X-Received: by 2002:a2e:92c4:0:b0:25d:9d30:5d61 with SMTP id k4-20020a2e92c4000000b0025d9d305d61mr291921ljh.202.1666978874931; Fri, 28 Oct 2022 10:41:14 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id s2-20020a2eb622000000b0026dfdcbccdasm725322ljn.14.2022.10.28.10.41.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 10:41:14 -0700 (PDT) From: Tanjuate Brunostar To: gregkh@linuxfoundation.org Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH v8 3/6] staging: vt6655: refactor long lines of code in s_uFillDataHead Date: Fri, 28 Oct 2022 17:40:55 +0000 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" fix checkpatch errors by refactoring long lines of code in the function: s_= uFillDataHead Signed-off-by: Tanjuate Brunostar --- drivers/staging/vt6655/rxtx.c | 97 ++++++++++++++++++++++++----------- 1 file changed, 67 insertions(+), 30 deletions(-) diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 8e56a7ee8035..7b6571ba7c36 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -481,19 +481,28 @@ static __le16 s_uFillDataHead(struct vnt_private *pDe= vice, } else { /* Get Duration and TimeStamp */ buf->duration_a =3D - cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A, cbFrameLength, - byPktType, wCurrentRate, bNeedAck, uFragIdx, - cbLastFragmentSize, uMACfragNum, + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A, + cbFrameLength, + byPktType, + wCurrentRate, bNeedAck, + uFragIdx, + cbLastFragmentSize, + uMACfragNum, byFBOption)); buf->duration_b =3D - cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_B, cbFrameLength, - PK_TYPE_11B, pDevice->byTopCCKBasicRate, - bNeedAck, uFragIdx, cbLastFragmentSize, - uMACfragNum, byFBOption)); + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_B, + cbFrameLength, + PK_TYPE_11B, + pDevice->byTopCCKBasicRate, + bNeedAck, uFragIdx, + cbLastFragmentSize, + uMACfragNum, + byFBOption)); } =20 buf->time_stamp_off_a =3D vnt_time_stamp_off(pDevice, wCurrentRate); - buf->time_stamp_off_b =3D vnt_time_stamp_off(pDevice, pDevice->byTopCCK= BasicRate); + buf->time_stamp_off_b =3D vnt_time_stamp_off(pDevice, + pDevice->byTopCCKBasicRate); =20 return buf->duration_a; } @@ -506,14 +515,29 @@ static __le16 s_uFillDataHead(struct vnt_private *pDe= vice, pDevice->byTopCCKBasicRate, PK_TYPE_11B, &buf->b); /* Get Duration and TimeStamp */ - buf->duration_a =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR= _A, cbFrameLength, byPktType, - wCurrentRate, bNeedAck, uFragIdx, cbLastFragmentSize, uMACfr= agNum, byFBOption)); - buf->duration_b =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR= _B, cbFrameLength, PK_TYPE_11B, - pDevice->byTopCCKBasicRate, bNeedAck, uFragIdx, cbLastFragm= entSize, uMACfragNum, byFBOption)); - buf->duration_a_f0 =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATA= DUR_A_F0, cbFrameLength, byPktType, - wCurrentRate, bNeedAck, uFragIdx, cbLastFragmentSize, uMACfragN= um, byFBOption)); - buf->duration_a_f1 =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATA= DUR_A_F1, cbFrameLength, byPktType, - wCurrentRate, bNeedAck, uFragIdx, cbLastFragmentSize, uMACfragNu= m, byFBOption)); + buf->duration_a =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR= _A, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, cbLastFragmentSize, + uMACfragNum, byFBOption)); + buf->duration_b =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR= _B, + cbFrameLength, PK_TYPE_11B, + pDevice->byTopCCKBasicRate, + bNeedAck, uFragIdx, + cbLastFragmentSize, + uMACfragNum, byFBOption)); + buf->duration_a_f0 =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATA= DUR_A_F0, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, + cbLastFragmentSize, + uMACfragNum, byFBOption)); + buf->duration_a_f1 =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATA= DUR_A_F1, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, + cbLastFragmentSize, + uMACfragNum, byFBOption)); =20 buf->time_stamp_off_a =3D vnt_time_stamp_off(pDevice, wCurrentRate); buf->time_stamp_off_b =3D vnt_time_stamp_off(pDevice, pDevice->byTopCCKB= asicRate); @@ -531,12 +555,24 @@ static __le16 s_uFillDataHead(struct vnt_private *pDe= vice, byPktType, &buf->a); =20 /* Get Duration and TimeStampOff */ - buf->duration =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_= A, cbFrameLength, byPktType, - wCurrentRate, bNeedAck, uFragIdx, cbLastFragmentSize, uMACfra= gNum, byFBOption)); - buf->duration_f0 =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATAD= UR_A_F0, cbFrameLength, byPktType, - wCurrentRate, bNeedAck, uFragIdx, cbLastFragmentSize, uMAC= fragNum, byFBOption)); - buf->duration_f1 =3D cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATAD= UR_A_F1, cbFrameLength, byPktType, - wCurrentRate, bNeedAck, uFragIdx, cbLastFragmentSize, uMACfragNu= m, byFBOption)); + buf->duration =3D + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, cbLastFragmentSize, + uMACfragNum, byFBOption)); + buf->duration_f0 =3D + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A_F0, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, cbLastFragmentSize, + uMACfragNum, byFBOption)); + buf->duration_f1 =3D + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A_F1, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, cbLastFragmentSize, + uMACfragNum, byFBOption)); buf->time_stamp_off =3D vnt_time_stamp_off(pDevice, wCurrentRate); return buf->duration; } @@ -552,10 +588,11 @@ static __le16 s_uFillDataHead(struct vnt_private *pDe= vice, } else { /* Get Duration and TimeStampOff */ buf->duration =3D - cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A, cbFrameLength,= byPktType, - wCurrentRate, bNeedAck, uFragIdx, - cbLastFragmentSize, uMACfragNum, - byFBOption)); + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_A, + cbFrameLength, byPktType, + wCurrentRate, bNeedAck, + uFragIdx, cbLastFragmentSize, + uMACfragNum, byFBOption)); } =20 buf->time_stamp_off =3D vnt_time_stamp_off(pDevice, wCurrentRate); @@ -573,10 +610,10 @@ static __le16 s_uFillDataHead(struct vnt_private *pDe= vice, } else { /* Get Duration and TimeStampOff */ buf->duration =3D - cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_B, cbFrameLength, = byPktType, - wCurrentRate, bNeedAck, uFragIdx, - cbLastFragmentSize, uMACfragNum, - byFBOption)); + cpu_to_le16((u16)s_uGetDataDuration(pDevice, DATADUR_B, cbFrameLength, + byPktType, wCurrentRate, bNeedAck, + uFragIdx, cbLastFragmentSize, + uMACfragNum, byFBOption)); } =20 buf->time_stamp_off =3D vnt_time_stamp_off(pDevice, wCurrentRate); --=20 2.34.1 From nobody Wed Apr 8 06:37:59 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 57761FA3742 for ; Fri, 28 Oct 2022 17:41:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230131AbiJ1Rle (ORCPT ); Fri, 28 Oct 2022 13:41:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45210 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230045AbiJ1RlU (ORCPT ); Fri, 28 Oct 2022 13:41:20 -0400 Received: from mail-lf1-x136.google.com (mail-lf1-x136.google.com [IPv6:2a00:1450:4864:20::136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 35AAB1C73C2 for ; Fri, 28 Oct 2022 10:41:19 -0700 (PDT) Received: by mail-lf1-x136.google.com with SMTP id f37so9408550lfv.8 for ; Fri, 28 Oct 2022 10:41:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=c9xsV8c/rBmZYI1wjay++VlFqX2UEzreuAkhbJUXoYI=; b=Q7ovpXj8nzicoiZMPipmokBviSOJOXWtwqw7l/jw8HuyNs5tr7nB6GZEohZpgryiMk 3i0uTgtlzHq/ynIVnB+hwPJda7oY61fLe5tUnDp+UFi+gkPpBwi/gwtcdl8Uu2GcxGvX rUMaBvQn7eX30nBu5VOlui7Op4wMiDUuMVSqJlOP/yoTXoywwGMiV8TFg41DNrIgTX3U rn0R3SYvucO8U4Ftuwcko0OUa+7UdqF6JhkKlWFuKqh8erQVRzhc6MH/JdJ+qSDDBKXp Sg/HJp+a7apNw6gGDly+fbLyAaLTsC12npl3c3kn+ZMbXphMC3pSGPtnisvfz+HsZ1Jg yZww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=c9xsV8c/rBmZYI1wjay++VlFqX2UEzreuAkhbJUXoYI=; b=h0wwM3af0UEbJhJ5RRDeh0l2BkPN9g4HZAbsdWbbYqyzAfmmff+PG/4T2NtatqwN6f 680xz68UPj2QaV2lKhkjbP62kYO9mHxJV/niz/3yRdDkvsA5tuU6I/HR57jgesmxHmPW LYifJDi2wtwLglSfkTQrKdUZEHeX1Imutf/i6SMokqojAceu7XGme5AtLhnbju9zGJcl vvUmCh2wKoeB1dIU4GBmVTvzH6vzfgZIlteg4fB88atiIJZimPvLhDxOHXs7io9Avm0E Ke3uNGYyD1cYLolBo/NxNdLZ6ajw74qmoSBXYvqdasbsny5y8+CysggbQVEv4CGZJVrN 72tw== X-Gm-Message-State: ACrzQf3Me2ABn6iw2kMQGuTRoJI7Tepw49Vc83MYrEca6JVM/WPzJFby NeSjFxY738qcTUiMoJiBTns= X-Google-Smtp-Source: AMsMyM6ivENusPAVvUREDUBdbb1+bSwSeL7Bja5/zRmZgRFqwjiz4CO/AvhEQJhWNpvXUPoxJxkBag== X-Received: by 2002:a05:6512:3e13:b0:499:1829:5181 with SMTP id i19-20020a0565123e1300b0049918295181mr179706lfv.71.1666978877414; Fri, 28 Oct 2022 10:41:17 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id s2-20020a2eb622000000b0026dfdcbccdasm725322ljn.14.2022.10.28.10.41.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 10:41:17 -0700 (PDT) From: Tanjuate Brunostar To: gregkh@linuxfoundation.org Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH v8 4/6] staging: vt6655: refactor long lines of code in s_vGenerateTxParamete Date: Fri, 28 Oct 2022 17:40:56 +0000 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" fix checkpatch errors by refactoring long lines of code in the function: s_= vGenerateTxParameter Signed-off-by: Tanjuate Brunostar --- drivers/staging/vt6655/rxtx.c | 68 ++++++++++++++++++++++++----------- 1 file changed, 47 insertions(+), 21 deletions(-) diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 7b6571ba7c36..475526b73e1a 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -834,7 +834,9 @@ static void s_vFillCTSHead(struct vnt_private *pDevice, } =20 if (byPktType =3D=3D PK_TYPE_11GB || byPktType =3D=3D PK_TYPE_11GA) { - if (byFBOption !=3D AUTO_FB_NONE && uDMAIdx !=3D TYPE_ATIMDMA && uDMAIdx= !=3D TYPE_BEACONDMA) { + if (byFBOption !=3D AUTO_FB_NONE && + uDMAIdx !=3D TYPE_ATIMDMA && + uDMAIdx !=3D TYPE_BEACONDMA) { /* Auto Fall back */ struct vnt_cts_fb *buf =3D pvCTS; /* Get SignalField, ServiceField & Length */ @@ -873,7 +875,11 @@ static void s_vFillCTSHead(struct vnt_private *pDevice, =20 ether_addr_copy(buf->data.ra, pDevice->abyCurrentNetAddr); - } else { /* if (byFBOption !=3D AUTO_FB_NONE && uDMAIdx !=3D TYPE_ATIMDM= A && uDMAIdx !=3D TYPE_BEACONDMA) */ + } else { + /* if (byFBOption !=3D AUTO_FB_NONE && + * uDMAIdx !=3D TYPE_ATIMDMA && + * uDMAIdx !=3D TYPE_BEACONDMA) + */ struct vnt_cts *buf =3D pvCTS; /* Get SignalField, ServiceField & Length */ vnt_get_phy_field(pDevice, uCTSFrameLen, @@ -959,50 +965,70 @@ static void s_vGenerateTxParameter(struct vnt_private= *pDevice, /* Fill RsvTime */ struct vnt_rrv_time_rts *buf =3D pvRrvTime; =20 - buf->rts_rrv_time_aa =3D get_rtscts_time(pDevice, 2, byPktType, cbFrame= Size, wCurrentRate); - buf->rts_rrv_time_ba =3D get_rtscts_time(pDevice, 1, byPktType, cbFrame= Size, wCurrentRate); - buf->rts_rrv_time_bb =3D get_rtscts_time(pDevice, 0, byPktType, cbFrame= Size, wCurrentRate); - buf->rrv_time_a =3D vnt_rxtx_rsvtime_le16(pDevice, byPktType, cbFrameSi= ze, wCurrentRate, bNeedACK); - buf->rrv_time_b =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrame= Size, pDevice->byTopCCKBasicRate, bNeedACK); - - s_vFillRTSHead(pDevice, byPktType, pvRTS, cbFrameSize, bNeedACK, bDisCR= C, psEthHeader, wCurrentRate, byFBOption); + buf->rts_rrv_time_aa =3D get_rtscts_time(pDevice, 2, byPktType, cbFrame= Size, + wCurrentRate); + buf->rts_rrv_time_ba =3D get_rtscts_time(pDevice, 1, byPktType, cbFrame= Size, + wCurrentRate); + buf->rts_rrv_time_bb =3D get_rtscts_time(pDevice, 0, byPktType, cbFrame= Size, + wCurrentRate); + buf->rrv_time_a =3D vnt_rxtx_rsvtime_le16(pDevice, byPktType, cbFrameSi= ze, + wCurrentRate, bNeedACK); + buf->rrv_time_b =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrame= Size, + pDevice->byTopCCKBasicRate, + bNeedACK); + + s_vFillRTSHead(pDevice, byPktType, pvRTS, cbFrameSize, bNeedACK, bDisCR= C, + psEthHeader, wCurrentRate, byFBOption); } else {/* RTS_needless, PCF mode */ struct vnt_rrv_time_cts *buf =3D pvRrvTime; =20 - buf->rrv_time_a =3D vnt_rxtx_rsvtime_le16(pDevice, byPktType, cbFrameSi= ze, wCurrentRate, bNeedACK); - buf->rrv_time_b =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrame= Size, pDevice->byTopCCKBasicRate, bNeedACK); - buf->cts_rrv_time_ba =3D get_rtscts_time(pDevice, 3, byPktType, cbFrame= Size, wCurrentRate); + buf->rrv_time_a =3D vnt_rxtx_rsvtime_le16(pDevice, byPktType, cbFrameSi= ze, + wCurrentRate, bNeedACK); + buf->rrv_time_b =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrame= Size, + pDevice->byTopCCKBasicRate, + bNeedACK); + buf->cts_rrv_time_ba =3D get_rtscts_time(pDevice, 3, byPktType, cbFrame= Size, + wCurrentRate); =20 /* Fill CTS */ - s_vFillCTSHead(pDevice, uDMAIdx, byPktType, pvCTS, cbFrameSize, bNeedAC= K, bDisCRC, wCurrentRate, byFBOption); + s_vFillCTSHead(pDevice, uDMAIdx, byPktType, pvCTS, cbFrameSize, bNeedAC= K, + bDisCRC, wCurrentRate, byFBOption); } } else if (byPktType =3D=3D PK_TYPE_11A) { if (pvRTS) {/* RTS_need, non PCF mode */ struct vnt_rrv_time_ab *buf =3D pvRrvTime; =20 - buf->rts_rrv_time =3D get_rtscts_time(pDevice, 2, byPktType, cbFrameSiz= e, wCurrentRate); - buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, byPktType, cbFrameSize= , wCurrentRate, bNeedACK); + buf->rts_rrv_time =3D get_rtscts_time(pDevice, 2, byPktType, cbFrameSiz= e, + wCurrentRate); + buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, byPktType, cbFrameSize, + wCurrentRate, bNeedACK); =20 /* Fill RTS */ - s_vFillRTSHead(pDevice, byPktType, pvRTS, cbFrameSize, bNeedACK, bDisCR= C, psEthHeader, wCurrentRate, byFBOption); + s_vFillRTSHead(pDevice, byPktType, pvRTS, cbFrameSize, bNeedACK, bDisCR= C, + psEthHeader, wCurrentRate, byFBOption); } else if (!pvRTS) {/* RTS_needless, non PCF mode */ struct vnt_rrv_time_ab *buf =3D pvRrvTime; =20 - buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11A, cbFrameSi= ze, wCurrentRate, bNeedACK); + buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11A, cbFrameSi= ze, + wCurrentRate, bNeedACK); } } else if (byPktType =3D=3D PK_TYPE_11B) { if (pvRTS) {/* RTS_need, non PCF mode */ struct vnt_rrv_time_ab *buf =3D pvRrvTime; =20 - buf->rts_rrv_time =3D get_rtscts_time(pDevice, 0, byPktType, cbFrameSiz= e, wCurrentRate); - buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrameSi= ze, wCurrentRate, bNeedACK); + buf->rts_rrv_time =3D get_rtscts_time(pDevice, 0, byPktType, cbFrameSiz= e, + wCurrentRate); + buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrameSi= ze, + wCurrentRate, bNeedACK); =20 /* Fill RTS */ - s_vFillRTSHead(pDevice, byPktType, pvRTS, cbFrameSize, bNeedACK, bDisCR= C, psEthHeader, wCurrentRate, byFBOption); + s_vFillRTSHead(pDevice, byPktType, pvRTS, cbFrameSize, bNeedACK, bDisCR= C, + psEthHeader, wCurrentRate, byFBOption); } else { /* RTS_needless, non PCF mode */ struct vnt_rrv_time_ab *buf =3D pvRrvTime; =20 - buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrameSi= ze, wCurrentRate, bNeedACK); + buf->rrv_time =3D vnt_rxtx_rsvtime_le16(pDevice, PK_TYPE_11B, cbFrameSi= ze, + wCurrentRate, bNeedACK); } } } --=20 2.34.1 From nobody Wed Apr 8 06:37:59 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1B66BECAAA1 for ; Fri, 28 Oct 2022 17:41:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230149AbiJ1Rli (ORCPT ); Fri, 28 Oct 2022 13:41:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45296 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230058AbiJ1RlW (ORCPT ); Fri, 28 Oct 2022 13:41:22 -0400 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3157A1C8414 for ; Fri, 28 Oct 2022 10:41:21 -0700 (PDT) Received: by mail-lf1-x129.google.com with SMTP id be13so9460908lfb.4 for ; Fri, 28 Oct 2022 10:41:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=mk+TiPiUxsPwinI95K1okpiLhPr3fYQEuz6nvFqNMpk=; b=oVgrX1WfK/pyZO3gKslamY9vOam0VT3uo1zgC67sM2hWKvshVm/DooNvDhsIwPY62j dFmwSeqqscgkJ+35IGIUZTRgIOKclXofJq2CwoGpKNa5wzukYheu2o7vwblUH0XO1dmx SLa/YBT2B0OuZAUqWaBx4bKhTvd3oThuleT44YB26lj8+AuBLU4Heee50Lg67LuPwCRk krbv3MXqs/u0VF6a0NrYcQbSnT5QVgdPpXpdT/d+1T+xtwGiAgq3YfOQugGAfNKu5Eg2 FLlnOuorExVuA+lioluRUHRsgRBkHqbGmmUVqmJAtDNKcDtdMXGkUAJ2ced1tNryxRYs h4Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mk+TiPiUxsPwinI95K1okpiLhPr3fYQEuz6nvFqNMpk=; b=3TUUhRFIUl/dgOi3+O/kPlk2bdIAOEXSbGCHezk4WBpdiNANSeSEY9hH9p1QvQn5DM 1i9PBJWW+ih8l2q+iKADp62fDwYAVqofF+nfhxNu8x4WR15YkwMOgUlNxnia8i48jQj4 a3jv9aDrcUQUTBYne0J8WS6WhEf1KS+edUicmKULO9NSPCA158/8LuRydt/nSyEQwBR8 Xj3ElY6PCEU5vww5LhRWVwjhRPOiXz3QKVQwr6xT1uZnRBApsyWkE67YSITuBhQ/Se5v ZUg5Xqc/q15pxvYq70CVwLzXuFarS9GK4UCSvimLi4aIQSBOld498MQ84RBWlyCTLX+5 BsEg== X-Gm-Message-State: ACrzQf1cU8apERZPYurFskFeY7btCNG5nbS+2y0/jT14c5okY0xt+Gfu +xoqnV5CPrwnIlXtm67LEDY92S0epCEOPg== X-Google-Smtp-Source: AMsMyM72em/id+unPHyhlqAc6Ux8M2VrhsivqgkZKU172PDef31RGhJzFDsiHs4thxMLfXHfM0aCTA== X-Received: by 2002:a05:6512:1096:b0:4a2:f71:60ea with SMTP id j22-20020a056512109600b004a20f7160eamr210615lfg.232.1666978879539; Fri, 28 Oct 2022 10:41:19 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id s2-20020a2eb622000000b0026dfdcbccdasm725322ljn.14.2022.10.28.10.41.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 10:41:19 -0700 (PDT) From: Tanjuate Brunostar To: gregkh@linuxfoundation.org Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH v8 5/6] staging: vt6655: refactor long lines of code in the rest of the file Date: Fri, 28 Oct 2022 17:40:57 +0000 Message-Id: <71c411a68c9c54b20e7fa687f736acac50b33b5e.1666978292.git.tanjubrunostar0@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" fix checkpatch errors by refactoring long lines of code in the rest of the file Signed-off-by: Tanjuate Brunostar --- drivers/staging/vt6655/rxtx.c | 86 +++++++++++++++++++++++------------ 1 file changed, 57 insertions(+), 29 deletions(-) diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 475526b73e1a..6a4fcb16b674 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -1102,44 +1102,59 @@ static unsigned int s_cbFillTxBufHead(struct vnt_pr= ivate *pDevice, if (byFBOption =3D=3D AUTO_FB_NONE) { if (bRTS) {/* RTS_need */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_rts)); - pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rr= v_time_rts) + cbMICHDR); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_rts)); + pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_rts) + cbMICHDR); pvCTS =3D NULL; - pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct v= nt_rrv_time_rts) + - cbMICHDR + sizeof(struct vnt_rts_g)); + pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_rts) + + cbMICHDR + sizeof(struct vnt_rts_g)); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_rts) + cbMICHDR + sizeof(struct vnt_rts_g) + sizeof(struct vnt_tx_datahead_g); } else { /* RTS_needless */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_cts)); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_cts)); pvRTS =3D NULL; - pvCTS =3D (void *) (pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_r= rv_time_cts) + cbMICHDR); + pvCTS =3D (void *) (pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_cts) + cbMICHDR); pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + - sizeof(struct vnt_rrv_time_cts) + cbMICHDR + sizeof(struct vnt_cts)); + sizeof(struct vnt_rrv_time_cts) + cbMICHDR + + sizeof(struct vnt_cts)); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_cts) + - cbMICHDR + sizeof(struct vnt_cts) + sizeof(struct vnt_tx_datahead_g= ); + cbMICHDR + sizeof(struct vnt_cts) + + sizeof(struct vnt_tx_datahead_g); } } else { /* Auto Fall Back */ if (bRTS) {/* RTS_need */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_rts)); - pvRTS =3D (void *) (pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_r= rv_time_rts) + cbMICHDR); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_rts)); + pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_rts) + cbMICHDR); pvCTS =3D NULL; - pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct v= nt_rrv_time_rts) + + pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_rts) + cbMICHDR + sizeof(struct vnt_rts_g_fb)); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_rts) + - cbMICHDR + sizeof(struct vnt_rts_g_fb) + sizeof(struct vnt_tx_datahea= d_g_fb); + cbMICHDR + sizeof(struct vnt_rts_g_fb) + + sizeof(struct vnt_tx_datahead_g_fb); } else { /* RTS_needless */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_cts)); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_cts)); pvRTS =3D NULL; - pvCTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rr= v_time_cts) + cbMICHDR); - pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct = vnt_rrv_time_cts) + + pvCTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_cts) + cbMICHDR); + pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_cts) + cbMICHDR + sizeof(struct vnt_cts_fb)); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_cts) + - cbMICHDR + sizeof(struct vnt_cts_fb) + sizeof(struct vnt_tx_datahead_= g_fb); + cbMICHDR + sizeof(struct vnt_cts_fb) + + sizeof(struct vnt_tx_datahead_g_fb); } } /* Auto Fall Back */ } else {/* 802.11a/b packet */ @@ -1147,19 +1162,25 @@ static unsigned int s_cbFillTxBufHead(struct vnt_pr= ivate *pDevice, if (byFBOption =3D=3D AUTO_FB_NONE) { if (bRTS) { pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_ab)); - pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rr= v_time_ab) + cbMICHDR); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab)); + pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab) + cbMICHDR); pvCTS =3D NULL; pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + - sizeof(struct vnt_rrv_time_ab) + cbMICHDR + sizeof(struct vnt_rts_ab)= ); + sizeof(struct vnt_rrv_time_ab) + cbMICHDR + + sizeof(struct vnt_rts_ab)); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_ab) + - cbMICHDR + sizeof(struct vnt_rts_ab) + sizeof(struct vnt_tx_datahead_= ab); + cbMICHDR + sizeof(struct vnt_rts_ab) + + sizeof(struct vnt_tx_datahead_ab); } else { /* RTS_needless, need MICHDR */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_ab)); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab)); pvRTS =3D NULL; pvCTS =3D NULL; - pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct v= nt_rrv_time_ab) + cbMICHDR); + pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab) + cbMICHDR); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_ab) + cbMICHDR + sizeof(struct vnt_tx_datahead_ab); } @@ -1167,19 +1188,25 @@ static unsigned int s_cbFillTxBufHead(struct vnt_pr= ivate *pDevice, /* Auto Fall Back */ if (bRTS) { /* RTS_need */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_ab)); - pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rr= v_time_ab) + cbMICHDR); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab)); + pvRTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab) + cbMICHDR); pvCTS =3D NULL; pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + - sizeof(struct vnt_rrv_time_ab) + cbMICHDR + sizeof(struct vnt_rts_a_f= b)); + sizeof(struct vnt_rrv_time_ab) + cbMICHDR + + sizeof(struct vnt_rts_a_fb)); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_ab) + - cbMICHDR + sizeof(struct vnt_rts_a_fb) + sizeof(struct vnt_tx_datahea= d_a_fb); + cbMICHDR + sizeof(struct vnt_rts_a_fb) + + sizeof(struct vnt_tx_datahead_a_fb); } else { /* RTS_needless */ pvRrvTime =3D (void *)(pbyTxBufferAddr + wTxBufSize); - pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + size= of(struct vnt_rrv_time_ab)); + pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab)); pvRTS =3D NULL; pvCTS =3D NULL; - pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct v= nt_rrv_time_ab) + cbMICHDR); + pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + + sizeof(struct vnt_rrv_time_ab) + cbMICHDR); cbHeaderLength =3D wTxBufSize + sizeof(struct vnt_rrv_time_ab) + cbMICHDR + sizeof(struct vnt_tx_datahead_a_fb); } @@ -1195,7 +1222,8 @@ static unsigned int s_cbFillTxBufHead(struct vnt_priv= ate *pDevice, cbFrameSize, bNeedACK, uDMAIdx, hdr, pDevice->wCurrentRate); /* Fill DataHead */ uDuration =3D s_uFillDataHead(pDevice, byPktType, pvTxDataHd, cbFrameSize= , uDMAIdx, bNeedACK, - 0, 0, uMACfragNum, byFBOption, pDevice->wCurrentRate, is_pspoll); + 0, 0, uMACfragNum, byFBOption, pDevice->wCurrentRate, + is_pspoll); =20 hdr->duration_id =3D uDuration; =20 --=20 2.34.1 From nobody Wed Apr 8 06:37:59 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4D996C38A02 for ; Fri, 28 Oct 2022 17:41:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230162AbiJ1Rlu (ORCPT ); Fri, 28 Oct 2022 13:41:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230133AbiJ1Rlg (ORCPT ); Fri, 28 Oct 2022 13:41:36 -0400 Received: from mail-lf1-x130.google.com (mail-lf1-x130.google.com [IPv6:2a00:1450:4864:20::130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4EBE11C8429 for ; Fri, 28 Oct 2022 10:41:23 -0700 (PDT) Received: by mail-lf1-x130.google.com with SMTP id d25so9012405lfb.7 for ; Fri, 28 Oct 2022 10:41:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=rEOapcrR5Veb7GbTiYOEkCV8uEMgF6llwclPcWMWYnY=; b=WwpzTb+iSq6Qsli6fJJxH5RQUDLYQyiO/o/MYSY7N6z6Jgy7MnZDUMas5mg81ALVRU U9T+vGeMiZ9roVRA2qpTydAQIdk1t3tDGdzk9YwOlbQeoD0kTTQh4t9LEDoNMx0uPYUh Vblgj/rFbI49KtSCueFoLBsrw8IVvjT3ZndLVhm3vVKyjMlTei/GDb+Cz3CGMz+IC2fp NemWWWwFPvEbcIEKDuQs/UI5ENn0OH0zOgeEYOkVuuPThVMmaT+m1G58U4z/3PUgaf7q 1lV10rq4luUROPgOkU5Xx4CNlewTfleno1ZSAKecNSfrCFK3sttSgyBc2HjEVgGNboCQ kPrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=rEOapcrR5Veb7GbTiYOEkCV8uEMgF6llwclPcWMWYnY=; b=tjXYsNwlTyvZHvtKS0emYzo/5rDxJ8hDgBOPkKeA+h84BsonNnL3P+Dje1mJpH0Hb0 bIXtvRqnC4cmEzlc1JrMy0aQUjsNdd28Y0lmEmWSE3NiATt2IbJ0lYfUIIEM6osIT8bA tTpQZQiglfVWE+0/8OUui3j55U4PWyJKiQZmd3wd9pyZTn6EXwsiwQ6cgU5ZePl5gsda TJzvkmU9/aNb7OzmCAfn5W3YAjwTKOHzLlsNJH+vYwyZo2z1wEfgDzfx/M2AUaclIArz Fgu2y4YPJMCMid6bZzZ6aOHlLTUI/qUW19bA63BiA5QmbXmZ4aa7LXEu/Smg/E4FmfD9 WR8Q== X-Gm-Message-State: ACrzQf04wVrNQcRjjDeMS/+0l7Qv8GDiyK9o42bPUpQoa8ZzHBVYp1d6 pdQkoZwHb18tTLVU6Oil0lU= X-Google-Smtp-Source: AMsMyM747L5KEH03pFOFU1iKA7oJhO99+AfcwLCrcR1oGZdD9jQGbBCHe3gO74b5rWsGQv8HY23AUw== X-Received: by 2002:ac2:4a6f:0:b0:4b0:1e5a:9287 with SMTP id q15-20020ac24a6f000000b004b01e5a9287mr203825lfp.156.1666978881713; Fri, 28 Oct 2022 10:41:21 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id s2-20020a2eb622000000b0026dfdcbccdasm725322ljn.14.2022.10.28.10.41.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 10:41:21 -0700 (PDT) From: Tanjuate Brunostar To: gregkh@linuxfoundation.org Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH v8 6/6] staging: vt6655: fix lines of code ending in a '(' Date: Fri, 28 Oct 2022 17:40:58 +0000 Message-Id: <45d10b850cef8ed5db7042311dbe19bcba185396.1666978292.git.tanjubrunostar0@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" fix checkpatch errors related to lines ending with a '(' by joining some lines of code and indenting properly to increase visibility Signed-off-by: Tanjuate Brunostar --- drivers/staging/vt6655/rxtx.c | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/drivers/staging/vt6655/rxtx.c b/drivers/staging/vt6655/rxtx.c index 6a4fcb16b674..d585435520b3 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -1118,7 +1118,7 @@ static unsigned int s_cbFillTxBufHead(struct vnt_priv= ate *pDevice, pMICHDR =3D (struct vnt_mic_hdr *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rrv_time_cts)); pvRTS =3D NULL; - pvCTS =3D (void *) (pbyTxBufferAddr + wTxBufSize + + pvCTS =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rrv_time_cts) + cbMICHDR); pvTxDataHd =3D (void *)(pbyTxBufferAddr + wTxBufSize + sizeof(struct vnt_rrv_time_cts) + cbMICHDR + @@ -1296,10 +1296,8 @@ static void vnt_fill_txkey(struct ieee80211_hdr *hdr= , u8 *key_buffer, ether_addr_copy(mic_hdr->addr2, hdr->addr2); ether_addr_copy(mic_hdr->addr3, hdr->addr3); =20 - mic_hdr->frame_control =3D cpu_to_le16( - le16_to_cpu(hdr->frame_control) & 0xc78f); - mic_hdr->seq_ctrl =3D cpu_to_le16( - le16_to_cpu(hdr->seq_ctrl) & 0xf); + mic_hdr->frame_control =3D cpu_to_le16(le16_to_cpu(hdr->frame_control) &= 0xc78f); + mic_hdr->seq_ctrl =3D cpu_to_le16(le16_to_cpu(hdr->seq_ctrl) & 0xf); =20 if (ieee80211_has_a4(hdr->frame_control)) ether_addr_copy(mic_hdr->addr4, hdr->addr4); @@ -1470,9 +1468,9 @@ static int vnt_beacon_xmit(struct vnt_private *priv, =20 /* Get Duration and TimeStampOff */ short_head->duration =3D - cpu_to_le16((u16)s_uGetDataDuration(priv, DATADUR_B, - frame_size, PK_TYPE_11A, current_rate, - false, 0, 0, 1, AUTO_FB_NONE)); + cpu_to_le16((u16)s_uGetDataDuration(priv, DATADUR_B, frame_size, + PK_TYPE_11A, current_rate, false, + 0, 0, 1, AUTO_FB_NONE)); =20 short_head->time_stamp_off =3D vnt_time_stamp_off(priv, current_rate); @@ -1486,9 +1484,9 @@ static int vnt_beacon_xmit(struct vnt_private *priv, =20 /* Get Duration and TimeStampOff */ short_head->duration =3D - cpu_to_le16((u16)s_uGetDataDuration(priv, DATADUR_B, - frame_size, PK_TYPE_11B, current_rate, - false, 0, 0, 1, AUTO_FB_NONE)); + cpu_to_le16((u16)s_uGetDataDuration(priv, DATADUR_B, frame_size, + PK_TYPE_11B, current_rate, false, + 0, 0, 1, AUTO_FB_NONE)); =20 short_head->time_stamp_off =3D vnt_time_stamp_off(priv, current_rate); --=20 2.34.1