Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1fc5af16 authored by Ruslan Pisarev's avatar Ruslan Pisarev Committed by Greg Kroah-Hartman
Browse files

Staging: rtl8192u: fix comments and space coding style issue in dot11d.h



This is a patch to the dot11d.h file that fixed up a comments and space
Errors found by the checkpatch.pl tools

Signed-off-by: default avatarRuslan Pisarev <ruslan@rpisarev.org.ua>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 1695eb36
Loading
Loading
Loading
Loading
+26 −26
Original line number Diff line number Diff line
@@ -4,9 +4,6 @@
#ifdef ENABLE_DOT11D
#include "ieee80211.h"

//#define ENABLE_DOT11D

//#define DOT11D_MAX_CHNL_NUM 83

typedef struct _CHNL_TXPOWER_TRIPLE {
	u8 FirstChnl;
@@ -21,27 +18,30 @@ typedef enum _DOT11D_STATE {
} DOT11D_STATE;

typedef struct _RT_DOT11D_INFO {
	//DECLARE_RT_OBJECT(RT_DOT11D_INFO);
	/* DECLARE_RT_OBJECT(RT_DOT11D_INFO); */

	bool bEnabled; // dot11MultiDomainCapabilityEnabled
	bool bEnabled; /* dot11MultiDomainCapabilityEnabled */

	u16 CountryIeLen; // > 0 if CountryIeBuf[] contains valid country information element.
	u16 CountryIeLen; /* > 0 if CountryIeBuf[] contains valid country information element. */
	u8  CountryIeBuf[MAX_IE_LEN];
	u8  CountryIeSrcAddr[6]; // Source AP of the country IE.
	u8  CountryIeSrcAddr[6]; /* Source AP of the country IE. */
	u8  CountryIeWatchdog;

	u8  channel_map[MAX_CHANNEL_NUMBER+1];  //!!!Value 0: Invalid, 1: Valid (active scan), 2: Valid (passive scan)
	//u8  ChnlListLen; // #Bytes valid in ChnlList[].
	//u8  ChnlList[DOT11D_MAX_CHNL_NUM];
	u8  channel_map[MAX_CHANNEL_NUMBER+1];  /* !Value 0: Invalid, 1: Valid (active scan), 2: Valid (passive scan) */
	u8  MaxTxPwrDbmList[MAX_CHANNEL_NUMBER+1];

	DOT11D_STATE State;
} RT_DOT11D_INFO, *PRT_DOT11D_INFO;
#define eqMacAddr(a,b)		( ((a)[0]==(b)[0] && (a)[1]==(b)[1] && (a)[2]==(b)[2] && (a)[3]==(b)[3] && (a)[4]==(b)[4] && (a)[5]==(b)[5]) ? 1:0 )
#define cpMacAddr(des,src)	      ((des)[0]=(src)[0],(des)[1]=(src)[1],(des)[2]=(src)[2],(des)[3]=(src)[3],(des)[4]=(src)[4],(des)[5]=(src)[5])
#define eqMacAddr(a, b)		(((a)[0] == (b)[0] && \
	(a)[1] == (b)[1] && (a)[2] == (b)[2] && (a)[3] == (b)[3] && \
	(a)[4] == (b)[4] && (a)[5] == (b)[5]) ? 1 : 0)
#define cpMacAddr(des, src)	      ((des)[0] = (src)[0], \
	(des)[1] = (src)[1], (des)[2] = (src)[2], \
	(des)[3] = (src)[3], (des)[4] = (src)[4], \
	(des)[5] = (src)[5])
#define GET_DOT11D_INFO(__pIeeeDev) ((PRT_DOT11D_INFO)((__pIeeeDev)->pDot11dInfo))

#define IS_DOT11D_ENABLE(__pIeeeDev) GET_DOT11D_INFO(__pIeeeDev)->bEnabled
#define IS_DOT11D_ENABLE(__pIeeeDev) (GET_DOT11D_INFO(__pIeeeDev)->bEnabled)
#define IS_COUNTRY_IE_VALID(__pIeeeDev) (GET_DOT11D_INFO(__pIeeeDev)->CountryIeLen > 0)

#define IS_EQUAL_CIE_SRC(__pIeeeDev, __pTa) eqMacAddr(GET_DOT11D_INFO(__pIeeeDev)->CountryIeSrcAddr, __pTa)
@@ -53,9 +53,9 @@ typedef struct _RT_DOT11D_INFO {
	(!memcmp(GET_DOT11D_INFO(__pIeeeDev)->CountryIeBuf, (__Ie).Octet, (__Ie).Length)))

#define CIE_WATCHDOG_TH 1
#define GET_CIE_WATCHDOG(__pIeeeDev) GET_DOT11D_INFO(__pIeeeDev)->CountryIeWatchdog
#define GET_CIE_WATCHDOG(__pIeeeDev) (GET_DOT11D_INFO(__pIeeeDev)->CountryIeWatchdog)
#define RESET_CIE_WATCHDOG(__pIeeeDev) GET_CIE_WATCHDOG(__pIeeeDev) = 0
#define UPDATE_CIE_WATCHDOG(__pIeeeDev) ++GET_CIE_WATCHDOG(__pIeeeDev)
#define UPDATE_CIE_WATCHDOG(__pIeeeDev) (++GET_CIE_WATCHDOG(__pIeeeDev))

#define IS_DOT11D_STATE_DONE(__pIeeeDev) (GET_DOT11D_INFO(__pIeeeDev)->State == DOT11D_STATE_DONE)

@@ -98,5 +98,5 @@ int ToLegalChannel(
	struct ieee80211_device *dev,
	u8 channel
);
#endif //ENABLE_DOT11D
#endif // #ifndef __INC_DOT11D_H
#endif /* ENABLE_DOT11D */
#endif /* #ifndef __INC_DOT11D_H */