LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Phillip Potter <phil@philpotter.co.uk>
To: gregkh@linuxfoundation.org
Cc: Larry.Finger@lwfinger.net, straube.linux@gmail.com,
	martin@kaiser.cx, fmdefrancesco@gmail.com,
	linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: [PATCH v2 3/3] staging: r8188eu: perform cleanup in rtl8188e_Add_RateATid
Date: Tue, 17 Aug 2021 00:44:59 +0100	[thread overview]
Message-ID: <20210816234459.132239-4-phil@philpotter.co.uk> (raw)
In-Reply-To: <20210816234459.132239-1-phil@philpotter.co.uk>

Perform some cleanup items in the rtl8188e_Add_RateATid function:
(1) Rename variable shortGIrate to short_gi_rate to comply with kernel
    camel case rules.
(2) Introduce additional whitespace around certain operators in the
    function, to make it clearer what is happening.

Signed-off-by: Phillip Potter <phil@philpotter.co.uk>
---
 drivers/staging/r8188eu/hal/rtl8188e_cmd.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/drivers/staging/r8188eu/hal/rtl8188e_cmd.c b/drivers/staging/r8188eu/hal/rtl8188e_cmd.c
index 77c057e276a5..8d03b24dc5af 100644
--- a/drivers/staging/r8188eu/hal/rtl8188e_cmd.c
+++ b/drivers/staging/r8188eu/hal/rtl8188e_cmd.c
@@ -155,25 +155,25 @@ void rtl8188e_Add_RateATid(struct adapter *pAdapter, u32 bitmap, u8 arg, u8 rssi
 {
 	struct hal_data_8188e *haldata = GET_HAL_DATA(pAdapter);
 
-	u8 macid, raid, shortGIrate = false;
+	u8 macid, raid, short_gi_rate = false;
 
-	macid = arg&0x1f;
+	macid = arg & 0x1f;
 
-	raid = (bitmap>>28) & 0x0f;
+	raid = (bitmap >> 28) & 0x0f;
 	bitmap &= 0x0fffffff;
 
 	if (rssi_level != DM_RATR_STA_INIT)
 		bitmap = ODM_Get_Rate_Bitmap(&haldata->odmpriv, macid, bitmap, rssi_level);
 
-	bitmap |= ((raid<<28)&0xf0000000);
+	bitmap |= ((raid << 28) & 0xf0000000);
 
-	shortGIrate = (arg&BIT(5)) ? true : false;
+	short_gi_rate = (arg & BIT(5)) ? true : false;
 
-	raid = (bitmap>>28) & 0x0f;
+	raid = (bitmap >> 28) & 0x0f;
 
 	bitmap &= 0x0fffffff;
 
-	ODM_RA_UpdateRateInfo_8188E(&haldata->odmpriv, macid, raid, bitmap, shortGIrate);
+	ODM_RA_UpdateRateInfo_8188E(&haldata->odmpriv, macid, raid, bitmap, short_gi_rate);
 }
 
 void rtl8188e_set_FwPwrMode_cmd(struct adapter *adapt, u8 Mode)
-- 
2.31.1


  parent reply	other threads:[~2021-08-16 23:45 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-16 23:44 [PATCH v2 0/3] staging: r8188eu: changes to rtl8188e_Add_RateATid Phillip Potter
2021-08-16 23:44 ` [PATCH v2 1/3] staging: r8188eu: remove set but unused variable from rtl8188e_Add_RateATid Phillip Potter
2021-08-17  7:01   ` Michael Straube
2021-08-16 23:44 ` [PATCH v2 2/3] staging: r8188eu: remove unneeded DBG_88E call " Phillip Potter
2021-08-17  7:02   ` Michael Straube
2021-08-16 23:44 ` Phillip Potter [this message]
2021-08-17  7:05   ` [PATCH v2 3/3] staging: r8188eu: perform cleanup in rtl8188e_Add_RateATid Michael Straube
2021-08-17 18:02     ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210816234459.132239-4-phil@philpotter.co.uk \
    --to=phil@philpotter.co.uk \
    --cc=Larry.Finger@lwfinger.net \
    --cc=fmdefrancesco@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    --cc=martin@kaiser.cx \
    --cc=straube.linux@gmail.com \
    --subject='Re: [PATCH v2 3/3] staging: r8188eu: perform cleanup in rtl8188e_Add_RateATid' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).