linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: John Whitmore <johnfwhitmore@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: devel@driverdev.osuosl.org, gregkh@linuxfoundation.org,
	John Whitmore <johnfwhitmore@gmail.com>
Subject: [PATCH 02/17] staging:rtl8192u: Refactor SEQUENCE_CONTROL - Style
Date: Tue, 21 Aug 2018 18:15:22 +0100	[thread overview]
Message-ID: <20180821171537.9330-3-johnfwhitmore@gmail.com> (raw)
In-Reply-To: <20180821171537.9330-1-johnfwhitmore@gmail.com>

Remove the 'typedef' from union SEQUENCE_CONTROL. This clears a
checkpatch issue with defining new types.

Additionally renamed the union to lowercase to comply with coding
standard.

These are coding style changes which should not impact runtime
code execution.

typedef union _SEQUENCE_CONTROL{
+union sequence_control {

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
---
 drivers/staging/rtl8192u/ieee80211/rtl819x_BA.h     | 6 +++---
 drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_BA.h b/drivers/staging/rtl8192u/ieee80211/rtl819x_BA.h
index 8a74faedf6d6..446de58f1849 100644
--- a/drivers/staging/rtl8192u/ieee80211/rtl819x_BA.h
+++ b/drivers/staging/rtl8192u/ieee80211/rtl819x_BA.h
@@ -22,13 +22,13 @@ struct ieee80211_ADDBA_Req{
 } __attribute__ ((packed));
 */
 //Is this need?I put here just to make it easier to define structure BA_RECORD //WB
-typedef union _SEQUENCE_CONTROL{
+union sequence_control {
 	u16 ShortData;
 	struct {
 		u16	FragNum:4;
 		u16	SeqNum:12;
 	} field;
-} SEQUENCE_CONTROL, *PSEQUENCE_CONTROL;
+};
 
 typedef union _BA_PARAM_SET {
 	u8 charData[2];
@@ -57,7 +57,7 @@ typedef struct _BA_RECORD {
 	u8				DialogToken;
 	BA_PARAM_SET		BaParamSet;
 	u16				BaTimeoutValue;
-	SEQUENCE_CONTROL	BaStartSeqCtrl;
+	union sequence_control	BaStartSeqCtrl;
 } BA_RECORD, *PBA_RECORD;
 
 #endif //end _BATYPE_H_
diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c b/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c
index 01b631c2a180..c1fe42e0893c 100644
--- a/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c
+++ b/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c
@@ -324,7 +324,7 @@ int ieee80211_rx_ADDBAReq(struct ieee80211_device *ieee, struct sk_buff *skb)
 	PBA_RECORD pBA = NULL;
 	PBA_PARAM_SET	pBaParamSet = NULL;
 	u16 *pBaTimeoutVal = NULL;
-	PSEQUENCE_CONTROL pBaStartSeqCtrl = NULL;
+	union sequence_control *pBaStartSeqCtrl = NULL;
 	struct rx_ts_record  *pTS = NULL;
 
 	if (skb->len < sizeof(struct rtl_80211_hdr_3addr) + 9) {
@@ -344,7 +344,7 @@ int ieee80211_rx_ADDBAReq(struct ieee80211_device *ieee, struct sk_buff *skb)
 	pDialogToken = tag + 2;  //category+action
 	pBaParamSet = (PBA_PARAM_SET)(tag + 3);   //+DialogToken
 	pBaTimeoutVal = (u16 *)(tag + 5);
-	pBaStartSeqCtrl = (PSEQUENCE_CONTROL)(req + 7);
+	pBaStartSeqCtrl = (union sequence_control *)(req + 7);
 
 	netdev_info(ieee->dev, "====================>rx ADDBAREQ from :%pM\n", dst);
 //some other capability is not ready now.
-- 
2.18.0


  parent reply	other threads:[~2018-08-21 17:15 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-21 17:15 [PATCH 00/17] staging:rtl8192u: Coding Style changes John Whitmore
2018-08-21 17:15 ` [PATCH 01/17] staging:rtl8192u: Remove unused defines - Style John Whitmore
2018-08-27 17:27   ` Greg KH
2018-08-27 19:21     ` John Whitmore
2018-08-27 19:30       ` Greg KH
2018-08-21 17:15 ` John Whitmore [this message]
2018-08-21 17:15 ` [PATCH 03/17] staging:rtl8192u: Rename ShortData " John Whitmore
2018-08-21 17:15 ` [PATCH 04/17] staging:rtl8192u: Rename member variables " John Whitmore
2018-08-21 17:15 ` [PATCH 05/17] staging:rtl8192u: Refactor BA_PARAM_SET " John Whitmore
2018-08-21 17:15 ` [PATCH 06/17] staging:rtl8192u: Remove charData and rename shortData " John Whitmore
2018-08-21 17:15 ` [PATCH 07/17] staging:rtl8192u: Rename ba_param_set members " John Whitmore
2018-08-21 17:15 ` [PATCH 08/17] staging:rtl8192u: Refactor DELBA_PARAM_SET " John Whitmore
2018-08-21 17:15 ` [PATCH 09/17] staging:rtl8192u: Refactor union delba_param_set " John Whitmore
2018-08-21 17:15 ` [PATCH 10/17] staging:rtl8192u: Refactor struct BA_RECORD " John Whitmore
2018-08-21 17:15 ` [PATCH 11/17] staging:rtl8192u: Rename member variable Timer " John Whitmore
2018-08-21 17:15 ` [PATCH 12/17] staging:rtl8192u: Rename bValid " John Whitmore
2018-08-21 17:15 ` [PATCH 13/17] staging:rtl8192u: Rename DialogToken " John Whitmore
2018-08-21 17:15 ` [PATCH 14/17] staging:rtl8192u: Rename BaParamSet " John Whitmore
2018-08-21 17:15 ` [PATCH 15/17] staging:rtl8192u: Rename BaTimeoutValue " John Whitmore
2018-08-21 17:15 ` [PATCH 16/17] staging:rtl8192u: Rename BaStartSeqCtrl " John Whitmore
2018-08-21 17:15 ` [PATCH 17/17] staging:rtl8192u: Remove commented out code and indent " John Whitmore
2018-08-23  7:44 ` [PATCH 00/17] staging:rtl8192u: Coding Style changes Dan Carpenter

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=20180821171537.9330-3-johnfwhitmore@gmail.com \
    --to=johnfwhitmore@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).