From nobody Wed Apr 8 01:36:45 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 A09B7C433FE for ; Thu, 20 Oct 2022 18:29:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230243AbiJTS3v (ORCPT ); Thu, 20 Oct 2022 14:29:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56624 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230154AbiJTS3o (ORCPT ); Thu, 20 Oct 2022 14:29:44 -0400 Received: from mail-lj1-x231.google.com (mail-lj1-x231.google.com [IPv6:2a00:1450:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 68A08220C3 for ; Thu, 20 Oct 2022 11:29:42 -0700 (PDT) Received: by mail-lj1-x231.google.com with SMTP id a6so500137ljq.5 for ; Thu, 20 Oct 2022 11:29:42 -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=0vK0LqI42j1feZQYGTo54nlQs1yB+CHMNY80qJ318mw=; b=V5uouJkpXo5YnGqGgm0X4G5fN6kZ5qa5JO5BKOHgyw6b6My3uSgebuqkfEtuyI9g8m MRl8i9djA2KT0N0JN3+AsL02bSHPuq/Fim1c/T50qdtFiESqbJ8ZGzplULQzxl1K9FOm cXgQvv8E7N1WztPCjaeUm2/6j4gwvotKrQSA5LvMq6mf6P9HFLZEWGf0OUSh2XktiLnI FBwaedOmH+c7qblmFCZKoMGsbZaZJNNp9hYfFoKQznQXrIWB+aPwt4VuAU7sLv31Ox+H Ri/28C21aMqlMefY+RRZY48aMVM4pfZBiO9IGvy0DDNKqb1lqQAhmTgE0T3D+sha6Jvl 0itg== 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=0vK0LqI42j1feZQYGTo54nlQs1yB+CHMNY80qJ318mw=; b=nIAL9c7qbpgPRCRNTPpOlC2foS9MH+PxJ3c5NnJi2oTz9Xp2hDpWPP4wE3GZOEpZYE edqUN8PJ3VSMVXfR3iNC2iuuQNj5s8cUYesSmBj8gwxrMfRSYXfSuN47WHYbaeRq2Zqb lNdVl5021M39IBKVgP/ko9WStww3qVYpGEbjpMksrRTMQ+h4rLo7p49B9eAYWzebb3Yj X7L+EG3BmhGX9TMYQxEMMi0oY3MmI/5IPOgGwmlOrtuW+IJ2+5NG21IiqUEp4+JDd1Z9 JMenN32e66Vfb+hau7PP3K3EygOfhCg4nC5rUqtb2lt98mNDSp4WD+FKTMN0QW9MneI0 MwpA== X-Gm-Message-State: ACrzQf1SFZWNiWrw7O5zV4xNIlW8+Xh6dINXYWTZpPFFT4hWG4a7bfHO nKfQM1A6HesfEJWsM+n3zD4= X-Google-Smtp-Source: AMsMyM6VwEgu16/pFiUhrpMANJF6xKbtWEFYS0CB5CzFpgoCmCg9Yj6V882nb8ISRVJm6nmUmDmFCA== X-Received: by 2002:a05:651c:a11:b0:26f:db4e:e7a6 with SMTP id k17-20020a05651c0a1100b0026fdb4ee7a6mr5468084ljq.361.1666290580639; Thu, 20 Oct 2022 11:29:40 -0700 (PDT) Received: from elroy-temp-vm.gaiao0uenmiufjlowqgp5yxwdh.gvxx.internal.cloudapp.net ([20.240.130.248]) by smtp.googlemail.com with ESMTPSA id h10-20020a0565123c8a00b00497a3e11608sm2797216lfv.303.2022.10.20.11.29.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Oct 2022 11:29:40 -0700 (PDT) From: Tanjuate Brunostar To: forest@alittletooquiet.net Cc: greg@kroah.com, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, outreachy@lists.linux.dev, Tanjuate Brunostar Subject: [PATCH 3/6] staging: vt6655: refactor long lines of code in s_uFillDataHead Date: Thu, 20 Oct 2022 18:27:43 +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 01e72999831b..dc853b83459b 100644 --- a/drivers/staging/vt6655/rxtx.c +++ b/drivers/staging/vt6655/rxtx.c @@ -484,19 +484,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; } @@ -509,14 +518,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); @@ -534,12 +558,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; } @@ -555,10 +591,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); @@ -576,10 +613,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