Skip to contentSkip to conversation

Staging: rtl8192u: ieeee80211: Add sapace before '{' and after '}'

PATCH In review Hatice ERTÜRK 4 participants 6 messages Mar 2, 2015 – Mar 3, 2015 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Staging: rtl8192u: ieeee80211: Add sapace before '{' and after '}'

Space required before the open brace '{' and after the close brace '}' This Error found with checkpatch.pl

---
 .../staging/rtl8192u/ieee80211/ieee80211_softmac.c | 184 ++++++++++-----------
 1 file changed, 92 insertions(+), 92 deletions(-)
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +92 -92
index 057d4d1..2c53763 100644
@@ -62,7 +62,7 @@ static void ieee80211_MFIE_Brate(struct ieee80211_device *ieee, u8 **tag_p)
 {
 	u8 *tag = *tag_p;
 
-	if (ieee->modulation & IEEE80211_CCK_MODULATION){
+	if (ieee->modulation & IEEE80211_CCK_MODULATION) {
 		*tag++ = MFIE_TYPE_RATES;
 		*tag++ = 4;
 		*tag++ = IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_1MB;
@@ -79,7 +79,7 @@ static void ieee80211_MFIE_Grate(struct ieee80211_device *ieee, u8 **tag_p)
 {
 	u8 *tag = *tag_p;
 
-		if (ieee->modulation & IEEE80211_OFDM_MODULATION){
+		if (ieee->modulation & IEEE80211_OFDM_MODULATION) {
 
 		*tag++ = MFIE_TYPE_RATES_EX;
 		*tag++ = 8;
@@ -192,7 +192,7 @@ static u8 MgntQuery_MgntFrameTxRate(struct ieee80211_device *ieee)
 	else
 		rate = ieee->basic_rate & 0x7f;
 
-	if (rate == 0){
+	if (rate == 0) {
 		/* 2005.01.26, by rcnjko. */
 		if (ieee->mode == IEEE_A||
 		   ieee->mode== IEEE_N_5G||
@@ -237,10 +237,10 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee
 	tcb_desc->bTxDisableRateFallBack = 1;
 	tcb_desc->bTxUseDriverAssingedRate = 1;
 
-	if (single){
-		if (ieee->queue_stop){
+	if (single) {
+		if (ieee->queue_stop) {
 			enqueue_mgmt(ieee, skb);
-		}else{
+		} else {
 			header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0]<<4);
 
 			if (ieee->seq_ctrl[0] == 0xFFF)
@@ -255,7 +255,7 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee
 		}
 
 		spin_unlock_irqrestore(&ieee->lock, flags);
-	}else{
+	} else {
 		spin_unlock_irqrestore(&ieee->lock, flags);
 		spin_lock_irqsave(&ieee->mgmt_tx_lock, flags);
 
@@ -293,7 +293,7 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i
 		(struct ieee80211_hdr_3addr  *) skb->data;
 
 
-	if (single){
+	if (single) {
 
 		header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0] << 4);
 
@@ -306,7 +306,7 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i
 		ieee->dev->trans_start = jiffies;
 		ieee->softmac_data_hard_start_xmit(skb,ieee->dev,ieee->basic_rate);
 
-	}else{
+	} else {
 
 		header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0] << 4);
 
@@ -369,7 +369,7 @@ static void ieee80211_send_beacon(struct ieee80211_device *ieee)
 	/* unsigned long flags; */
 	skb = ieee80211_get_beacon_(ieee);
 
-	if (skb){
+	if (skb) {
 		softmac_mgmt_xmit(skb, ieee);
 		ieee->softmac_stats.tx_beacons++;
 		/* dev_kfree_skb_any(skb); edit by thomas */
@@ -378,7 +378,7 @@ static void ieee80211_send_beacon(struct ieee80211_device *ieee)
 		(MSECS( ieee->current_network.beacon_interval -5));
 
 	spin_lock_irqsave(&ieee->beacon_lock,flags); */
-	if (ieee->beacon_txing && ieee->ieee_up){
+	if (ieee->beacon_txing && ieee->ieee_up) {
 		/* if(!timer_pending(&ieee->beacon_timer))
 			add_timer(&ieee->beacon_timer); */
 		mod_timer(&ieee->beacon_timer,jiffies+(MSECS(ieee->current_network.beacon_interval-5)));
@@ -404,7 +404,7 @@ static void ieee80211_send_probe(struct ieee80211_device *ieee)
 	struct sk_buff *skb;
 
 	skb = ieee80211_probe_req(ieee);
-	if (skb){
+	if (skb) {
 		softmac_mgmt_xmit(skb, ieee);
 		ieee->softmac_stats.tx_probe_rq++;
 		/* dev_kfree_skb_any(skb); edit by thomas */
@@ -413,7 +413,7 @@ static void ieee80211_send_probe(struct ieee80211_device *ieee)
 
 static void ieee80211_send_probe_requests(struct ieee80211_device *ieee)
 {
-	if (ieee->active_scan && (ieee->softmac_features & IEEE_SOFTMAC_PROBERQ)){
+	if (ieee->active_scan && (ieee->softmac_features & IEEE_SOFTMAC_PROBERQ)) {
 		ieee80211_send_probe(ieee);
 		ieee80211_send_probe(ieee);
 	}
@@ -433,11 +433,11 @@ void ieee80211_softmac_scan_syncro(struct ieee80211_device *ieee)
 	while (1)
 	{
 
-		do{
+		do {
 			ch++;
 			if (ch > MAX_CHANNEL_NUMBER)
 				goto out; /* scan completed */
-		}while (!channel_map[ch]);
+		} while (!channel_map[ch]);
 
 		/* this function can be called in two situations
 		 * 1- We have switched to ad-hoc mode and we are
@@ -478,7 +478,7 @@ void ieee80211_softmac_scan_syncro(struct ieee80211_device *ieee)
 
 	}
 out:
-	if (ieee->state < IEEE80211_LINKED){
+	if (ieee->state < IEEE80211_LINKED) {
 		ieee->actscanning = false;
 		up(&ieee->scan_sem);
 	}
@@ -501,7 +501,7 @@ static void ieee80211_softmac_scan_wq(struct work_struct *work)
 	if (!ieee->ieee_up)
 		return;
 	down(&ieee->scan_sem);
-	do{
+	do {
 		ieee->current_network.channel =
 			(ieee->current_network.channel + 1) % MAX_CHANNEL_NUMBER;
 		if (watchdog++ > MAX_CHANNEL_NUMBER)
@@ -512,7 +512,7 @@ static void ieee80211_softmac_scan_wq(struct work_struct *work)
 				goto out; /* no good chans */
 			}
 		}
-	}while (!channel_map[ieee->current_network.channel]);
+	} while (!channel_map[ieee->current_network.channel]);
 	if (ieee->scanning == 0 )
 		goto out;
 	ieee->set_chan(ieee->dev, ieee->current_network.channel);
@@ -587,7 +587,7 @@ static void ieee80211_softmac_stop_scan(struct ieee80211_device *ieee)
 	down(&ieee->scan_sem);
 	/* spin_lock_irqsave(&ieee->lock, flags); */
 
-	if (ieee->scanning == 1){
+	if (ieee->scanning == 1) {
 		ieee->scanning = 0;
 
 		cancel_delayed_work(&ieee->softmac_scan_wq);
@@ -616,12 +616,12 @@ static void ieee80211_start_scan(struct ieee80211_device *ieee)
 			RESET_CIE_WATCHDOG(ieee);
 		}
 	}
-	if (ieee->softmac_features & IEEE_SOFTMAC_SCAN){
-		if (ieee->scanning == 0){
+	if (ieee->softmac_features & IEEE_SOFTMAC_SCAN) {
+		if (ieee->scanning == 0) {
 			ieee->scanning = 1;
 			queue_delayed_work(ieee->wq, &ieee->softmac_scan_wq, 0);
 		}
-	}else
+	} else
 		ieee->start_scan(ieee->dev);
 
 }
@@ -803,7 +803,7 @@ static struct sk_buff *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d
 	*(tag++) = 1;
 	*(tag++) = ieee->current_network.channel;
 
-	if (atim_len){
+	if (atim_len) {
 		*(tag++) = MFIE_TYPE_IBSS_SET;
 		*(tag++) = 2;
 
@@ -812,12 +812,12 @@ static struct sk_buff *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d
 		tag+=2;
 	}
 
-	if (erp_len){
+	if (erp_len) {
 		*(tag++) = MFIE_TYPE_ERP;
 		*(tag++) = 1;
 		*(tag++) = erpinfo_content;
 	}
-	if (rate_ex_len){
+	if (rate_ex_len) {
 		*(tag++) = MFIE_TYPE_RATES_EX;
 		*(tag++) = rate_ex_len-2;
 		memcpy(tag, ieee->current_network.rates_ex, rate_ex_len-2);
@@ -1169,7 +1169,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 		tag += osCcxVerNum.Length;
 	}
 	/* HT cap element */
-	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){
+	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) {
 		if (ieee->pHTInfo->ePeerHTSpecVer != HT_SPEC_VER_EWC)
 		{
 			tag = skb_put(skb, ht_cap_len);
@@ -1183,7 +1183,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 
 	/* choose what wpa_supplicant gives to associate. */
 	tag = skb_put(skb, wpa_ie_len);
-	if (wpa_ie_len){
+	if (wpa_ie_len) {
 		memcpy(tag, ieee->wpa_ie, ieee->wpa_ie_len);
 	}
 
@@ -1198,7 +1198,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 	}
 #endif
 
-	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){
+	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) {
 		if (ieee->pHTInfo->ePeerHTSpecVer == HT_SPEC_VER_EWC)
 		{
 			tag = skb_put(skb, ht_cap_len);
@@ -1208,7 +1208,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 			tag += ht_cap_len -2;
 		}
 
-		if (ieee->pHTInfo->bCurrentRT2RTAggregation){
+		if (ieee->pHTInfo->bCurrentRT2RTAggregation) {
 			tag = skb_put(skb, realtek_ie_len);
 			*tag++ = MFIE_TYPE_GENERIC;
 			*tag++ = realtek_ie_len - 2;
@@ -1234,10 +1234,10 @@ void ieee80211_associate_abort(struct ieee80211_device *ieee)
 	 * Here we will check if there are good nets to associate
 	 * with, so we retry or just get back to NO_LINK and scanning
 	 */
-	if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING){
+	if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING) {
 		IEEE80211_DEBUG_MGMT("Authentication failed\n");
 		ieee->softmac_stats.no_auth_rs++;
-	}else{
+	} else {
 		IEEE80211_DEBUG_MGMT("Association failed\n");
 		ieee->softmac_stats.no_ass_rs++;
 	}
@@ -1274,7 +1274,7 @@ static void ieee80211_associate_step1(struct ieee80211_device *ieee)
 		/* printk(KERN_WARNING "Sending authentication request\n"); */
 		softmac_mgmt_xmit(skb, ieee);
 		/* BUGON when you try to add_timer twice, using mod_timer may be better, john0709 */
-		if (!timer_pending(&ieee->associate_timer)){
+		if (!timer_pending(&ieee->associate_timer)) {
 			ieee->associate_timer.expires = jiffies + (HZ / 2);
 			add_timer(&ieee->associate_timer);
 		}
@@ -1338,11 +1338,11 @@ static void ieee80211_associate_complete_wq(struct work_struct *work)
 	struct ieee80211_device *ieee = container_of(work, struct ieee80211_device, associate_complete_wq);
 	printk(KERN_INFO "Associated successfully\n");
 	if (ieee80211_is_54g(&ieee->current_network) &&
-		(ieee->modulation & IEEE80211_OFDM_MODULATION)){
+		(ieee->modulation & IEEE80211_OFDM_MODULATION)) {
 
 		ieee->rate = 108;
 		printk(KERN_INFO"Using G rates:%d\n", ieee->rate);
-	}else{
+	} else {
 		ieee->rate = 22;
 		printk(KERN_INFO"Using B rates:%d\n", ieee->rate);
 	}
@@ -1365,7 +1365,7 @@ static void ieee80211_associate_complete_wq(struct work_struct *work)
 		ieee->LinkDetectInfo.NumRecvDataInPeriod= 1;
 	}
 	ieee->link_change(ieee->dev);
-	if (ieee->is_silent_reset == 0){
+	if (ieee->is_silent_reset == 0) {
 		printk("============>normal associate\n");
 	notify_wx_assoc_event(ieee);
 	}
@@ -1431,7 +1431,7 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 		return;
 
 
-	if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode == IW_MODE_ADHOC){
+	if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode == IW_MODE_ADHOC) {
 		/* if the user specified the AP MAC, we need also the essid
 		 * This could be obtained by beacons or, if the network does not
 		 * broadcast it, it can be put manually.
@@ -1459,13 +1459,13 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 				/* if the essid is hidden replace it with the
 				* essid provided by the user.
 				*/
-				if (!ssidbroad){
+				if (!ssidbroad) {
 					strncpy(tmp_ssid, ieee->current_network.ssid, IW_ESSID_MAX_SIZE);
 					tmp_ssid_len = ieee->current_network.ssid_len;
 				}
 				memcpy(&ieee->current_network, net, sizeof(struct ieee80211_network));
 
-				if (!ssidbroad){
+				if (!ssidbroad) {
 					strncpy(ieee->current_network.ssid, tmp_ssid, IW_ESSID_MAX_SIZE);
 					ieee->current_network.ssid_len = tmp_ssid_len;
 				}
@@ -1473,7 +1473,7 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 
 				/* ieee->pHTInfo->IOTAction = 0; */
 				HTResetIOTSetting(ieee->pHTInfo);
-				if (ieee->iw_mode == IW_MODE_INFRA){
+				if (ieee->iw_mode == IW_MODE_INFRA) {
 					/* Join the network for the first time */
 					ieee->AsocRetryCount = 0;
 					/* for HT by amy 080514 */
@@ -1492,13 +1492,13 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 
 					ieee->state = IEEE80211_ASSOCIATING;
 					queue_work(ieee->wq, &ieee->associate_procedure_wq);
-				}else{
+				} else {
 					if (ieee80211_is_54g(&ieee->current_network) &&
-						(ieee->modulation & IEEE80211_OFDM_MODULATION)){
+						(ieee->modulation & IEEE80211_OFDM_MODULATION)) {
 						ieee->rate = 108;
 						ieee->SetWirelessMode(ieee->dev, IEEE_G);
 						printk(KERN_INFO"Using G rates\n");
-					}else{
+					} else {
 						ieee->rate = 22;
 						ieee->SetWirelessMode(ieee->dev, IEEE_B);
 						printk(KERN_INFO"Using B rates\n");
@@ -1542,16 +1542,16 @@ static inline u16 auth_parse(struct sk_buff *skb, u8 **challenge, int *chlen)
 {
 	struct ieee80211_authentication *a;
 	u8 *t;
-	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))){
+	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))) {
 		IEEE80211_DEBUG_MGMT("invalid len in auth resp: %d\n",skb->len);
 		return 0xcafe;
 	}
 	*challenge = NULL;
 	a = (struct ieee80211_authentication *) skb->data;
-	if (skb->len > (sizeof(struct ieee80211_authentication) +3)){
+	if (skb->len > (sizeof(struct ieee80211_authentication) +3)) {
 		t = skb->data + sizeof(struct ieee80211_authentication);
 
-		if (*(t++) == MFIE_TYPE_CHALLENGE){
+		if (*(t++) == MFIE_TYPE_CHALLENGE) {
 			*chlen = *(t++);
 			*challenge = kmemdup(t, *chlen, GFP_ATOMIC);
 			if (!*challenge)
@@ -1568,7 +1568,7 @@ static int auth_rq_parse(struct sk_buff *skb, u8 *dest)
 {
 	struct ieee80211_authentication *a;
 
-	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))){
+	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))) {
 		IEEE80211_DEBUG_MGMT("invalid len in auth request: %d\n",skb->len);
 		return -1;
 	}
@@ -1601,8 +1601,8 @@ static short probe_rq_parse(struct ieee80211_device *ieee, struct sk_buff *skb,
 
 	tag = skb->data + sizeof (struct ieee80211_hdr_3addr  );
 
-	while (tag+1 < skbend){
-		if (*tag == 0){
+	while (tag+1 < skbend) {
+		if (*tag == 0) {
 			ssid = tag+2;
 			ssidlen = *(tag+1);
 			break;
@@ -1643,7 +1643,7 @@ static inline u16 assoc_parse(struct ieee80211_device *ieee, struct sk_buff *skb
 	struct ieee80211_assoc_response_frame *response_head;
 	u16 status_code;
 
-	if (skb->len <  sizeof(struct ieee80211_assoc_response_frame)){
+	if (skb->len <  sizeof(struct ieee80211_assoc_response_frame)) {
 		IEEE80211_DEBUG_MGMT("invalid len in auth resp: %d\n", skb->len);
 		return 0xcafe;
 	}
@@ -1658,7 +1658,7 @@ static inline u16 assoc_parse(struct ieee80211_device *ieee, struct sk_buff *skb
 	    (ieee->current_network.mode == IEEE_N_24G) &&
 	    (ieee->AsocRetryCount++ < (RT_ASOC_RETRY_LIMIT-1)))) {
 		 ieee->pHTInfo->IOTAction |= HT_IOT_ACT_PURE_N_MODE;
-	}else {
+	} else {
 		 ieee->AsocRetryCount = 0;
 	}
 
@@ -1673,7 +1673,7 @@ ieee80211_rx_probe_rq(struct ieee80211_device *ieee, struct sk_buff *skb)
 	/* IEEE80211DMESG("Rx probe"); */
 	ieee->softmac_stats.rx_probe_rq++;
 	/* DMESG("Dest is "MACSTR, MAC2STR(dest)); */
-	if (probe_rq_parse(ieee, skb, dest)){
+	if (probe_rq_parse(ieee, skb, dest)) {
 		/* IEEE80211DMESG("Was for me!"); */
 		ieee->softmac_stats.tx_probe_rs++;
 		ieee80211_resp_to_probe(ieee, dest);
@@ -1704,7 +1704,7 @@ ieee80211_rx_assoc_rq(struct ieee80211_device *ieee, struct sk_buff *skb)
 	/* unsigned long flags; */
 
 	ieee->softmac_stats.rx_ass_rq++;
-	if (assoc_rq_parse(skb,dest) != -1){
+	if (assoc_rq_parse(skb,dest) != -1) {
 		ieee80211_resp_to_assoc_rq(ieee, dest);
 	}
 
@@ -1756,13 +1756,13 @@ static short ieee80211_sta_ps_sleep(struct ieee80211_device *ieee, u32 *time_h,
 		(ieee->mgmt_queue_tail != ieee->mgmt_queue_head))
 		return 0;
 
-	if (time_l){
+	if (time_l) {
 		*time_l = ieee->current_network.last_dtim_sta_time[0]
 			+ (ieee->current_network.beacon_interval
 			* ieee->current_network.dtim_period) * 1000;
 	}
 
-	if (time_h){
+	if (time_h) {
 		*time_h = ieee->current_network.last_dtim_sta_time[1];
 		if (time_l && *time_l < ieee->current_network.last_dtim_sta_time[0])
 			*time_h += 1;
@@ -1800,16 +1800,16 @@ static inline void ieee80211_sta_ps(struct ieee80211_device *ieee)
 	if (sleep == 0)
 		goto out;
 
-	if (sleep == 1){
+	if (sleep == 1) {
 
 		if (ieee->sta_sleep == 1)
 			ieee->enter_sleep_state(ieee->dev, th, tl);
 
-		else if (ieee->sta_sleep == 0){
+		else if (ieee->sta_sleep == 0) {
 			/* printk("send null 1\n"); */
 			spin_lock_irqsave(&ieee->mgmt_tx_lock, flags2);
 
-			if (ieee->ps_is_queue_empty(ieee->dev)){
+			if (ieee->ps_is_queue_empty(ieee->dev)) {
 
 
 				ieee->sta_sleep = 2;
@@ -1826,7 +1826,7 @@ static inline void ieee80211_sta_ps(struct ieee80211_device *ieee)
 		}
 
 
-	}else if (sleep == 2){
+	} else if (sleep == 2) {
 /* #warning CHECK_LOCK_HERE */
 		spin_lock_irqsave(&ieee->mgmt_tx_lock, flags2);
 
@@ -1842,8 +1842,8 @@ out:
 
 void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl)
 {
-	if (ieee->sta_sleep == 0){
-		if (nl){
+	if (ieee->sta_sleep == 0) {
+		if (nl) {
 			printk("Warning: driver is probably failing to report TX ps error\n");
 			ieee->ps_request_tx_ack(ieee->dev);
 			ieee80211_sta_ps_send_null_frame(ieee, 0);
@@ -1857,7 +1857,7 @@ void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl)
 
 	ieee->sta_sleep = 0;
 
-	if (nl){
+	if (nl) {
 		ieee->ps_request_tx_ack(ieee->dev);
 		ieee80211_sta_ps_send_null_frame(ieee, 0);
 	}
@@ -1869,9 +1869,9 @@ void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success)
 
 	spin_lock_irqsave(&ieee->lock, flags);
 
-	if (ieee->sta_sleep == 2){
+	if (ieee->sta_sleep == 2) {
 		/* Null frame with PS bit set */
-		if (success){
+		if (success) {
 			ieee->sta_sleep = 1;
 			ieee->enter_sleep_state(ieee->dev,ieee->ps_th,ieee->ps_tl);
 		}
@@ -2014,7 +2014,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 
 	case IEEE80211_STYPE_AUTH:
 
-		if (ieee->softmac_features & IEEE_SOFTMAC_ASSOCIATE){
+		if (ieee->softmac_features & IEEE_SOFTMAC_ASSOCIATE) {
 			if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING &&
 			ieee->iw_mode == IW_MODE_INFRA){
 
@@ -2022,7 +2022,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 
 					errcode = auth_parse(skb, &challenge, &chlen);
 					if (!errcode) {
-						if (ieee->open_wep || !challenge){
+						if (ieee->open_wep || !challenge) {
 							ieee->state = IEEE80211_ASSOCIATING_AUTHENTICATED;
 							ieee->softmac_stats.rx_auth_rs_ok++;
 							if (!(ieee->pHTInfo->IOTAction&HT_IOT_ACT_PURE_N_MODE))
@@ -2048,7 +2048,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 								/* N mode setting */
 								ieee->SetWirelessMode(ieee->dev, \
 										ieee->current_network.mode);
-							}else{
+							} else {
 								/* b/g mode setting */
 								/*TODO*/
 								ieee->SetWirelessMode(ieee->dev, IEEE_G);
@@ -2063,16 +2063,16 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 								ieee->bHalfWirelessN24GMode = false;
 
 							ieee80211_associate_step2(ieee);
-						}else{
+						} else {
 							ieee80211_auth_challenge(ieee, challenge, chlen);
 						}
-					}else{
+					} else {
 						ieee->softmac_stats.rx_auth_rs_err++;
 						IEEE80211_DEBUG_MGMT("Authentication response status code 0x%x",errcode);
 						ieee80211_associate_abort(ieee);
 					}
 
-				}else if (ieee->iw_mode == IW_MODE_MASTER){
+				} else if (ieee->iw_mode == IW_MODE_MASTER) {
 					ieee80211_rx_auth_rq(ieee, skb);
 				}
 			}
@@ -2176,7 +2176,7 @@ void ieee80211_softmac_xmit(struct ieee80211_txb *txb, struct ieee80211_device *
 #else
 			skb_queue_tail(&ieee->skb_waitQ[queue_index], txb->fragments[i]);
 #endif
-		}else{
+		} else {
 			ieee->softmac_data_hard_start_xmit(
 					txb->fragments[i],
 					ieee->dev, ieee->rate);
@@ -2200,10 +2200,10 @@ static void ieee80211_resume_tx(struct ieee80211_device *ieee)
 	int i;
 	for (i = ieee->tx_pending.frag; i < ieee->tx_pending.txb->nr_frags; i++) {
 
-		if (ieee->queue_stop){
+		if (ieee->queue_stop) {
 			ieee->tx_pending.frag = i;
 			return;
-		}else{
+		} else {
 
 			ieee->softmac_data_hard_start_xmit(
 				ieee->tx_pending.txb->fragments[i],
@@ -2226,7 +2226,7 @@ void ieee80211_reset_queue(struct ieee80211_device *ieee)
 
 	spin_lock_irqsave(&ieee->lock, flags);
 	init_mgmt_queue(ieee);
-	if (ieee->tx_pending.txb){
+	if (ieee->tx_pending.txb) {
 		ieee80211_txb_free(ieee->tx_pending.txb);
 		ieee->tx_pending.txb = NULL;
 	}
@@ -2248,8 +2248,8 @@ void ieee80211_wake_queue(struct ieee80211_device *ieee)
 
 	ieee->queue_stop = 0;
 
-	if (ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE){
-		while (!ieee->queue_stop && (skb = dequeue_mgmt(ieee))){
+	if (ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE) {
+		while (!ieee->queue_stop && (skb = dequeue_mgmt(ieee))) {
 
 			header = (struct ieee80211_hdr_3addr  *) skb->data;
 
@@ -2267,7 +2267,7 @@ void ieee80211_wake_queue(struct ieee80211_device *ieee)
 	if (!ieee->queue_stop && ieee->tx_pending.txb)
 		ieee80211_resume_tx(ieee);
 
-	if (!ieee->queue_stop && netif_queue_stopped(ieee->dev)){
+	if (!ieee->queue_stop && netif_queue_stopped(ieee->dev)) {
 		ieee->softmac_stats.swtxawake++;
 		netif_wake_queue(ieee->dev);
 	}
@@ -2282,7 +2282,7 @@ void ieee80211_stop_queue(struct ieee80211_device *ieee)
 	/* unsigned long flags;
 	spin_lock_irqsave(&ieee->lock,flags); */
 
-	if (! netif_queue_stopped(ieee->dev)){
+	if (! netif_queue_stopped(ieee->dev)) {
 		netif_stop_queue(ieee->dev);
 		ieee->softmac_stats.swtxstop++;
 	}
@@ -2303,7 +2303,7 @@ void ieee80211_start_master_bss(struct ieee80211_device *ieee)
 {
 	ieee->assoc_id = 1;
 
-	if (ieee->current_network.ssid_len == 0){
+	if (ieee->current_network.ssid_len == 0) {
 		strncpy(ieee->current_network.ssid,
 			IEEE80211_DEFAULT_TX_ESSID,
 			IW_ESSID_MAX_SIZE);
@@ -2327,7 +2327,7 @@ void ieee80211_start_master_bss(struct ieee80211_device *ieee)
 
 static void ieee80211_start_monitor_mode(struct ieee80211_device *ieee)
 {
-	if (ieee->raw_tx){
+	if (ieee->raw_tx) {
 
 		if (ieee->data_hard_resume)
 			ieee->data_hard_resume(ieee->dev);
@@ -2347,13 +2347,13 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 	 * (abort) this wq (when syncro scanning) before sleeping
 	 * on the semaphore
 	 */
-	if (!ieee->proto_started){
+	if (!ieee->proto_started) {
 		printk("==========oh driver down return\n");
 		return;
 	}
 	down(&ieee->wx_sem);
 
-	if (ieee->current_network.ssid_len == 0){
+	if (ieee->current_network.ssid_len == 0) {
 		strcpy(ieee->current_network.ssid, IEEE80211_DEFAULT_TX_ESSID);
 		ieee->current_network.ssid_len = strlen(IEEE80211_DEFAULT_TX_ESSID);
 		ieee->ssid_set = 1;
@@ -2384,12 +2384,12 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 		ieee80211_start_scan_syncro(ieee);
 
 	/* the network definitively is not here.. create a new cell */
-	if (ieee->state == IEEE80211_NOLINK){
+	if (ieee->state == IEEE80211_NOLINK) {
 		printk("creating new IBSS cell\n");
 		if (!ieee->wap_set)
 			ieee80211_randomize_cell(ieee);
 
-		if (ieee->modulation & IEEE80211_CCK_MODULATION){
+		if (ieee->modulation & IEEE80211_CCK_MODULATION) {
 
 			ieee->current_network.rates_len = 4;
 
@@ -2398,10 +2398,10 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 			ieee->current_network.rates[2] = IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_5MB;
 			ieee->current_network.rates[3] = IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_11MB;
 
-		}else
+		} else
 			ieee->current_network.rates_len = 0;
 
-		if (ieee->modulation & IEEE80211_OFDM_MODULATION){
+		if (ieee->modulation & IEEE80211_OFDM_MODULATION) {
 			ieee->current_network.rates_ex_len = 8;
 
 			ieee->current_network.rates_ex[0] = IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_6MB;
@@ -2414,7 +2414,7 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 			ieee->current_network.rates_ex[7] = IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_54MB;
 
 			ieee->rate = 108;
-		}else{
+		} else {
 			ieee->current_network.rates_ex_len = 0;
 			ieee->rate = 22;
 		}
@@ -2481,7 +2481,7 @@ void ieee80211_start_bss(struct ieee80211_device *ieee)
 	 */
 	spin_lock_irqsave(&ieee->lock, flags);
 
-	if (ieee->state == IEEE80211_NOLINK){
+	if (ieee->state == IEEE80211_NOLINK) {
 		ieee->actscanning = true;
 		ieee80211_start_scan(ieee);
 	}
@@ -2635,12 +2635,12 @@ void ieee80211_start_protocol(struct ieee80211_device *ieee)
 
 	ieee->proto_started = 1;
 
-	if (ieee->current_network.channel == 0){
-		do{
+	if (ieee->current_network.channel == 0) {
+		do {
 			ch++;
 			if (ch > MAX_CHANNEL_NUMBER)
 				return; /* no channel found */
-		}while (!GET_DOT11D_INFO(ieee)->channel_map[ch]);
+		} while (!GET_DOT11D_INFO(ieee)->channel_map[ch]);
 		ieee->current_network.channel = ch;
 	}
 
@@ -2856,12 +2856,12 @@ static int ieee80211_wpa_set_auth_algs(struct ieee80211_device *ieee, int value)
 		sec.auth_mode = WLAN_AUTH_SHARED_KEY;
 		ieee->open_wep = 0;
 		ieee->auth_mode = 1;
-	} else if (value & AUTH_ALG_OPEN_SYSTEM){
+	} else if (value & AUTH_ALG_OPEN_SYSTEM) {
 		sec.auth_mode = WLAN_AUTH_OPEN;
 		ieee->open_wep = 1;
 		ieee->auth_mode = 0;
 	}
-	else if (value & IW_AUTH_ALG_LEAP){
+	else if (value & IW_AUTH_ALG_LEAP) {
 		sec.auth_mode = WLAN_AUTH_LEAP;
 		ieee->open_wep = 1;
 		ieee->auth_mode = 2;
Signature · 1 line
1.9.1
#1 lore raw
Quoted 8 lines · Hatice ERTÜRK

Space required before the open brace '{' and after the close brace '}' This Error found with checkpatch.pl

---
 .../staging/rtl8192u/ieee80211/ieee80211_softmac.c | 184 ++++++++++-----------
 1 file changed, 92 insertions(+), 92 deletions(-)

This one looks good

Jes

#2 lore raw
In reply to Hatice ERTÜRK
Quoted 2 lines · Hatice ERTÜRK

Space required before the open brace '{' and after the close brace '}' This Error found with checkpatch.pl

I think that this is a v2, but you have not indicated that?

julia

Quoted 716 lines
---
 .../staging/rtl8192u/ieee80211/ieee80211_softmac.c | 184 ++++++++++-----------
 1 file changed, 92 insertions(+), 92 deletions(-)
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +92 -93
index 057d4d1..2c53763 100644
@@ -62,7 +62,7 @@ static void ieee80211_MFIE_Brate(struct ieee80211_device *ieee, u8 **tag_p)
 {
 	u8 *tag = *tag_p;
 
-	if (ieee->modulation & IEEE80211_CCK_MODULATION){
+	if (ieee->modulation & IEEE80211_CCK_MODULATION) {
 		*tag++ = MFIE_TYPE_RATES;
 		*tag++ = 4;
 		*tag++ = IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_1MB;
@@ -79,7 +79,7 @@ static void ieee80211_MFIE_Grate(struct ieee80211_device *ieee, u8 **tag_p)
 {
 	u8 *tag = *tag_p;
 
-		if (ieee->modulation & IEEE80211_OFDM_MODULATION){
+		if (ieee->modulation & IEEE80211_OFDM_MODULATION) {
 
 		*tag++ = MFIE_TYPE_RATES_EX;
 		*tag++ = 8;
@@ -192,7 +192,7 @@ static u8 MgntQuery_MgntFrameTxRate(struct ieee80211_device *ieee)
 	else
 		rate = ieee->basic_rate & 0x7f;
 
-	if (rate == 0){
+	if (rate == 0) {
 		/* 2005.01.26, by rcnjko. */
 		if (ieee->mode == IEEE_A||
 		   ieee->mode== IEEE_N_5G||
@@ -237,10 +237,10 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee
 	tcb_desc->bTxDisableRateFallBack = 1;
 	tcb_desc->bTxUseDriverAssingedRate = 1;
 
-	if (single){
-		if (ieee->queue_stop){
+	if (single) {
+		if (ieee->queue_stop) {
 			enqueue_mgmt(ieee, skb);
-		}else{
+		} else {
 			header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0]<<4);
 
 			if (ieee->seq_ctrl[0] == 0xFFF)
@@ -255,7 +255,7 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee
 		}
 
 		spin_unlock_irqrestore(&ieee->lock, flags);
-	}else{
+	} else {
 		spin_unlock_irqrestore(&ieee->lock, flags);
 		spin_lock_irqsave(&ieee->mgmt_tx_lock, flags);
 
@@ -293,7 +293,7 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i
 		(struct ieee80211_hdr_3addr  *) skb->data;
 
 
-	if (single){
+	if (single) {
 
 		header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0] << 4);
 
@@ -306,7 +306,7 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i
 		ieee->dev->trans_start = jiffies;
 		ieee->softmac_data_hard_start_xmit(skb,ieee->dev,ieee->basic_rate);
 
-	}else{
+	} else {
 
 		header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0] << 4);
 
@@ -369,7 +369,7 @@ static void ieee80211_send_beacon(struct ieee80211_device *ieee)
 	/* unsigned long flags; */
 	skb = ieee80211_get_beacon_(ieee);
 
-	if (skb){
+	if (skb) {
 		softmac_mgmt_xmit(skb, ieee);
 		ieee->softmac_stats.tx_beacons++;
 		/* dev_kfree_skb_any(skb); edit by thomas */
@@ -378,7 +378,7 @@ static void ieee80211_send_beacon(struct ieee80211_device *ieee)
 		(MSECS( ieee->current_network.beacon_interval -5));
 
 	spin_lock_irqsave(&ieee->beacon_lock,flags); */
-	if (ieee->beacon_txing && ieee->ieee_up){
+	if (ieee->beacon_txing && ieee->ieee_up) {
 		/* if(!timer_pending(&ieee->beacon_timer))
 			add_timer(&ieee->beacon_timer); */
 		mod_timer(&ieee->beacon_timer,jiffies+(MSECS(ieee->current_network.beacon_interval-5)));
@@ -404,7 +404,7 @@ static void ieee80211_send_probe(struct ieee80211_device *ieee)
 	struct sk_buff *skb;
 
 	skb = ieee80211_probe_req(ieee);
-	if (skb){
+	if (skb) {
 		softmac_mgmt_xmit(skb, ieee);
 		ieee->softmac_stats.tx_probe_rq++;
 		/* dev_kfree_skb_any(skb); edit by thomas */
@@ -413,7 +413,7 @@ static void ieee80211_send_probe(struct ieee80211_device *ieee)
 
 static void ieee80211_send_probe_requests(struct ieee80211_device *ieee)
 {
-	if (ieee->active_scan && (ieee->softmac_features & IEEE_SOFTMAC_PROBERQ)){
+	if (ieee->active_scan && (ieee->softmac_features & IEEE_SOFTMAC_PROBERQ)) {
 		ieee80211_send_probe(ieee);
 		ieee80211_send_probe(ieee);
 	}
@@ -433,11 +433,11 @@ void ieee80211_softmac_scan_syncro(struct ieee80211_device *ieee)
 	while (1)
 	{
 
-		do{
+		do {
 			ch++;
 			if (ch > MAX_CHANNEL_NUMBER)
 				goto out; /* scan completed */
-		}while (!channel_map[ch]);
+		} while (!channel_map[ch]);
 
 		/* this function can be called in two situations
 		 * 1- We have switched to ad-hoc mode and we are
@@ -478,7 +478,7 @@ void ieee80211_softmac_scan_syncro(struct ieee80211_device *ieee)
 
 	}
 out:
-	if (ieee->state < IEEE80211_LINKED){
+	if (ieee->state < IEEE80211_LINKED) {
 		ieee->actscanning = false;
 		up(&ieee->scan_sem);
 	}
@@ -501,7 +501,7 @@ static void ieee80211_softmac_scan_wq(struct work_struct *work)
 	if (!ieee->ieee_up)
 		return;
 	down(&ieee->scan_sem);
-	do{
+	do {
 		ieee->current_network.channel =
 			(ieee->current_network.channel + 1) % MAX_CHANNEL_NUMBER;
 		if (watchdog++ > MAX_CHANNEL_NUMBER)
@@ -512,7 +512,7 @@ static void ieee80211_softmac_scan_wq(struct work_struct *work)
 				goto out; /* no good chans */
 			}
 		}
-	}while (!channel_map[ieee->current_network.channel]);
+	} while (!channel_map[ieee->current_network.channel]);
 	if (ieee->scanning == 0 )
 		goto out;
 	ieee->set_chan(ieee->dev, ieee->current_network.channel);
@@ -587,7 +587,7 @@ static void ieee80211_softmac_stop_scan(struct ieee80211_device *ieee)
 	down(&ieee->scan_sem);
 	/* spin_lock_irqsave(&ieee->lock, flags); */
 
-	if (ieee->scanning == 1){
+	if (ieee->scanning == 1) {
 		ieee->scanning = 0;
 
 		cancel_delayed_work(&ieee->softmac_scan_wq);
@@ -616,12 +616,12 @@ static void ieee80211_start_scan(struct ieee80211_device *ieee)
 			RESET_CIE_WATCHDOG(ieee);
 		}
 	}
-	if (ieee->softmac_features & IEEE_SOFTMAC_SCAN){
-		if (ieee->scanning == 0){
+	if (ieee->softmac_features & IEEE_SOFTMAC_SCAN) {
+		if (ieee->scanning == 0) {
 			ieee->scanning = 1;
 			queue_delayed_work(ieee->wq, &ieee->softmac_scan_wq, 0);
 		}
-	}else
+	} else
 		ieee->start_scan(ieee->dev);
 
 }
@@ -803,7 +803,7 @@ static struct sk_buff *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d
 	*(tag++) = 1;
 	*(tag++) = ieee->current_network.channel;
 
-	if (atim_len){
+	if (atim_len) {
 		*(tag++) = MFIE_TYPE_IBSS_SET;
 		*(tag++) = 2;
 
@@ -812,12 +812,12 @@ static struct sk_buff *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d
 		tag+=2;
 	}
 
-	if (erp_len){
+	if (erp_len) {
 		*(tag++) = MFIE_TYPE_ERP;
 		*(tag++) = 1;
 		*(tag++) = erpinfo_content;
 	}
-	if (rate_ex_len){
+	if (rate_ex_len) {
 		*(tag++) = MFIE_TYPE_RATES_EX;
 		*(tag++) = rate_ex_len-2;
 		memcpy(tag, ieee->current_network.rates_ex, rate_ex_len-2);
@@ -1169,7 +1169,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 		tag += osCcxVerNum.Length;
 	}
 	/* HT cap element */
-	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){
+	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) {
 		if (ieee->pHTInfo->ePeerHTSpecVer != HT_SPEC_VER_EWC)
 		{
 			tag = skb_put(skb, ht_cap_len);
@@ -1183,7 +1183,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 
 	/* choose what wpa_supplicant gives to associate. */
 	tag = skb_put(skb, wpa_ie_len);
-	if (wpa_ie_len){
+	if (wpa_ie_len) {
 		memcpy(tag, ieee->wpa_ie, ieee->wpa_ie_len);
 	}
 
@@ -1198,7 +1198,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 	}
 #endif
 
-	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){
+	if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) {
 		if (ieee->pHTInfo->ePeerHTSpecVer == HT_SPEC_VER_EWC)
 		{
 			tag = skb_put(skb, ht_cap_len);
@@ -1208,7 +1208,7 @@ inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco
 			tag += ht_cap_len -2;
 		}
 
-		if (ieee->pHTInfo->bCurrentRT2RTAggregation){
+		if (ieee->pHTInfo->bCurrentRT2RTAggregation) {
 			tag = skb_put(skb, realtek_ie_len);
 			*tag++ = MFIE_TYPE_GENERIC;
 			*tag++ = realtek_ie_len - 2;
@@ -1234,10 +1234,10 @@ void ieee80211_associate_abort(struct ieee80211_device *ieee)
 	 * Here we will check if there are good nets to associate
 	 * with, so we retry or just get back to NO_LINK and scanning
 	 */
-	if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING){
+	if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING) {
 		IEEE80211_DEBUG_MGMT("Authentication failed\n");
 		ieee->softmac_stats.no_auth_rs++;
-	}else{
+	} else {
 		IEEE80211_DEBUG_MGMT("Association failed\n");
 		ieee->softmac_stats.no_ass_rs++;
 	}
@@ -1274,7 +1274,7 @@ static void ieee80211_associate_step1(struct ieee80211_device *ieee)
 		/* printk(KERN_WARNING "Sending authentication request\n"); */
 		softmac_mgmt_xmit(skb, ieee);
 		/* BUGON when you try to add_timer twice, using mod_timer may be better, john0709 */
-		if (!timer_pending(&ieee->associate_timer)){
+		if (!timer_pending(&ieee->associate_timer)) {
 			ieee->associate_timer.expires = jiffies + (HZ / 2);
 			add_timer(&ieee->associate_timer);
 		}
@@ -1338,11 +1338,11 @@ static void ieee80211_associate_complete_wq(struct work_struct *work)
 	struct ieee80211_device *ieee = container_of(work, struct ieee80211_device, associate_complete_wq);
 	printk(KERN_INFO "Associated successfully\n");
 	if (ieee80211_is_54g(&ieee->current_network) &&
-		(ieee->modulation & IEEE80211_OFDM_MODULATION)){
+		(ieee->modulation & IEEE80211_OFDM_MODULATION)) {
 
 		ieee->rate = 108;
 		printk(KERN_INFO"Using G rates:%d\n", ieee->rate);
-	}else{
+	} else {
 		ieee->rate = 22;
 		printk(KERN_INFO"Using B rates:%d\n", ieee->rate);
 	}
@@ -1365,7 +1365,7 @@ static void ieee80211_associate_complete_wq(struct work_struct *work)
 		ieee->LinkDetectInfo.NumRecvDataInPeriod= 1;
 	}
 	ieee->link_change(ieee->dev);
-	if (ieee->is_silent_reset == 0){
+	if (ieee->is_silent_reset == 0) {
 		printk("============>normal associate\n");
 	notify_wx_assoc_event(ieee);
 	}
@@ -1431,7 +1431,7 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 		return;
 
 
-	if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode == IW_MODE_ADHOC){
+	if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode == IW_MODE_ADHOC) {
 		/* if the user specified the AP MAC, we need also the essid
 		 * This could be obtained by beacons or, if the network does not
 		 * broadcast it, it can be put manually.
@@ -1459,13 +1459,13 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 				/* if the essid is hidden replace it with the
 				* essid provided by the user.
 				*/
-				if (!ssidbroad){
+				if (!ssidbroad) {
 					strncpy(tmp_ssid, ieee->current_network.ssid, IW_ESSID_MAX_SIZE);
 					tmp_ssid_len = ieee->current_network.ssid_len;
 				}
 				memcpy(&ieee->current_network, net, sizeof(struct ieee80211_network));
 
-				if (!ssidbroad){
+				if (!ssidbroad) {
 					strncpy(ieee->current_network.ssid, tmp_ssid, IW_ESSID_MAX_SIZE);
 					ieee->current_network.ssid_len = tmp_ssid_len;
 				}
@@ -1473,7 +1473,7 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 
 				/* ieee->pHTInfo->IOTAction = 0; */
 				HTResetIOTSetting(ieee->pHTInfo);
-				if (ieee->iw_mode == IW_MODE_INFRA){
+				if (ieee->iw_mode == IW_MODE_INFRA) {
 					/* Join the network for the first time */
 					ieee->AsocRetryCount = 0;
 					/* for HT by amy 080514 */
@@ -1492,13 +1492,13 @@ inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee
 
 					ieee->state = IEEE80211_ASSOCIATING;
 					queue_work(ieee->wq, &ieee->associate_procedure_wq);
-				}else{
+				} else {
 					if (ieee80211_is_54g(&ieee->current_network) &&
-						(ieee->modulation & IEEE80211_OFDM_MODULATION)){
+						(ieee->modulation & IEEE80211_OFDM_MODULATION)) {
 						ieee->rate = 108;
 						ieee->SetWirelessMode(ieee->dev, IEEE_G);
 						printk(KERN_INFO"Using G rates\n");
-					}else{
+					} else {
 						ieee->rate = 22;
 						ieee->SetWirelessMode(ieee->dev, IEEE_B);
 						printk(KERN_INFO"Using B rates\n");
@@ -1542,16 +1542,16 @@ static inline u16 auth_parse(struct sk_buff *skb, u8 **challenge, int *chlen)
 {
 	struct ieee80211_authentication *a;
 	u8 *t;
-	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))){
+	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))) {
 		IEEE80211_DEBUG_MGMT("invalid len in auth resp: %d\n",skb->len);
 		return 0xcafe;
 	}
 	*challenge = NULL;
 	a = (struct ieee80211_authentication *) skb->data;
-	if (skb->len > (sizeof(struct ieee80211_authentication) +3)){
+	if (skb->len > (sizeof(struct ieee80211_authentication) +3)) {
 		t = skb->data + sizeof(struct ieee80211_authentication);
 
-		if (*(t++) == MFIE_TYPE_CHALLENGE){
+		if (*(t++) == MFIE_TYPE_CHALLENGE) {
 			*chlen = *(t++);
 			*challenge = kmemdup(t, *chlen, GFP_ATOMIC);
 			if (!*challenge)
@@ -1568,7 +1568,7 @@ static int auth_rq_parse(struct sk_buff *skb, u8 *dest)
 {
 	struct ieee80211_authentication *a;
 
-	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))){
+	if (skb->len <  (sizeof(struct ieee80211_authentication)-sizeof(struct ieee80211_info_element))) {
 		IEEE80211_DEBUG_MGMT("invalid len in auth request: %d\n",skb->len);
 		return -1;
 	}
@@ -1601,8 +1601,8 @@ static short probe_rq_parse(struct ieee80211_device *ieee, struct sk_buff *skb,
 
 	tag = skb->data + sizeof (struct ieee80211_hdr_3addr  );
 
-	while (tag+1 < skbend){
-		if (*tag == 0){
+	while (tag+1 < skbend) {
+		if (*tag == 0) {
 			ssid = tag+2;
 			ssidlen = *(tag+1);
 			break;
@@ -1643,7 +1643,7 @@ static inline u16 assoc_parse(struct ieee80211_device *ieee, struct sk_buff *skb
 	struct ieee80211_assoc_response_frame *response_head;
 	u16 status_code;
 
-	if (skb->len <  sizeof(struct ieee80211_assoc_response_frame)){
+	if (skb->len <  sizeof(struct ieee80211_assoc_response_frame)) {
 		IEEE80211_DEBUG_MGMT("invalid len in auth resp: %d\n", skb->len);
 		return 0xcafe;
 	}
@@ -1658,7 +1658,7 @@ static inline u16 assoc_parse(struct ieee80211_device *ieee, struct sk_buff *skb
 	    (ieee->current_network.mode == IEEE_N_24G) &&
 	    (ieee->AsocRetryCount++ < (RT_ASOC_RETRY_LIMIT-1)))) {
 		 ieee->pHTInfo->IOTAction |= HT_IOT_ACT_PURE_N_MODE;
-	}else {
+	} else {
 		 ieee->AsocRetryCount = 0;
 	}
 
@@ -1673,7 +1673,7 @@ ieee80211_rx_probe_rq(struct ieee80211_device *ieee, struct sk_buff *skb)
 	/* IEEE80211DMESG("Rx probe"); */
 	ieee->softmac_stats.rx_probe_rq++;
 	/* DMESG("Dest is "MACSTR, MAC2STR(dest)); */
-	if (probe_rq_parse(ieee, skb, dest)){
+	if (probe_rq_parse(ieee, skb, dest)) {
 		/* IEEE80211DMESG("Was for me!"); */
 		ieee->softmac_stats.tx_probe_rs++;
 		ieee80211_resp_to_probe(ieee, dest);
@@ -1704,7 +1704,7 @@ ieee80211_rx_assoc_rq(struct ieee80211_device *ieee, struct sk_buff *skb)
 	/* unsigned long flags; */
 
 	ieee->softmac_stats.rx_ass_rq++;
-	if (assoc_rq_parse(skb,dest) != -1){
+	if (assoc_rq_parse(skb,dest) != -1) {
 		ieee80211_resp_to_assoc_rq(ieee, dest);
 	}
 
@@ -1756,13 +1756,13 @@ static short ieee80211_sta_ps_sleep(struct ieee80211_device *ieee, u32 *time_h,
 		(ieee->mgmt_queue_tail != ieee->mgmt_queue_head))
 		return 0;
 
-	if (time_l){
+	if (time_l) {
 		*time_l = ieee->current_network.last_dtim_sta_time[0]
 			+ (ieee->current_network.beacon_interval
 			* ieee->current_network.dtim_period) * 1000;
 	}
 
-	if (time_h){
+	if (time_h) {
 		*time_h = ieee->current_network.last_dtim_sta_time[1];
 		if (time_l && *time_l < ieee->current_network.last_dtim_sta_time[0])
 			*time_h += 1;
@@ -1800,16 +1800,16 @@ static inline void ieee80211_sta_ps(struct ieee80211_device *ieee)
 	if (sleep == 0)
 		goto out;
 
-	if (sleep == 1){
+	if (sleep == 1) {
 
 		if (ieee->sta_sleep == 1)
 			ieee->enter_sleep_state(ieee->dev, th, tl);
 
-		else if (ieee->sta_sleep == 0){
+		else if (ieee->sta_sleep == 0) {
 			/* printk("send null 1\n"); */
 			spin_lock_irqsave(&ieee->mgmt_tx_lock, flags2);
 
-			if (ieee->ps_is_queue_empty(ieee->dev)){
+			if (ieee->ps_is_queue_empty(ieee->dev)) {
 
 
 				ieee->sta_sleep = 2;
@@ -1826,7 +1826,7 @@ static inline void ieee80211_sta_ps(struct ieee80211_device *ieee)
 		}
 
 
-	}else if (sleep == 2){
+	} else if (sleep == 2) {
 /* #warning CHECK_LOCK_HERE */
 		spin_lock_irqsave(&ieee->mgmt_tx_lock, flags2);
 
@@ -1842,8 +1842,8 @@ out:
 
 void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl)
 {
-	if (ieee->sta_sleep == 0){
-		if (nl){
+	if (ieee->sta_sleep == 0) {
+		if (nl) {
 			printk("Warning: driver is probably failing to report TX ps error\n");
 			ieee->ps_request_tx_ack(ieee->dev);
 			ieee80211_sta_ps_send_null_frame(ieee, 0);
@@ -1857,7 +1857,7 @@ void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl)
 
 	ieee->sta_sleep = 0;
 
-	if (nl){
+	if (nl) {
 		ieee->ps_request_tx_ack(ieee->dev);
 		ieee80211_sta_ps_send_null_frame(ieee, 0);
 	}
@@ -1869,9 +1869,9 @@ void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success)
 
 	spin_lock_irqsave(&ieee->lock, flags);
 
-	if (ieee->sta_sleep == 2){
+	if (ieee->sta_sleep == 2) {
 		/* Null frame with PS bit set */
-		if (success){
+		if (success) {
 			ieee->sta_sleep = 1;
 			ieee->enter_sleep_state(ieee->dev,ieee->ps_th,ieee->ps_tl);
 		}
@@ -2014,7 +2014,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 
 	case IEEE80211_STYPE_AUTH:
 
-		if (ieee->softmac_features & IEEE_SOFTMAC_ASSOCIATE){
+		if (ieee->softmac_features & IEEE_SOFTMAC_ASSOCIATE) {
 			if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING &&
 			ieee->iw_mode == IW_MODE_INFRA){
 
@@ -2022,7 +2022,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 
 					errcode = auth_parse(skb, &challenge, &chlen);
 					if (!errcode) {
-						if (ieee->open_wep || !challenge){
+						if (ieee->open_wep || !challenge) {
 							ieee->state = IEEE80211_ASSOCIATING_AUTHENTICATED;
 							ieee->softmac_stats.rx_auth_rs_ok++;
 							if (!(ieee->pHTInfo->IOTAction&HT_IOT_ACT_PURE_N_MODE))
@@ -2048,7 +2048,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 								/* N mode setting */
 								ieee->SetWirelessMode(ieee->dev, \
 										ieee->current_network.mode);
-							}else{
+							} else {
 								/* b/g mode setting */
 								/*TODO*/
 								ieee->SetWirelessMode(ieee->dev, IEEE_G);
@@ -2063,16 +2063,16 @@ ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,
 								ieee->bHalfWirelessN24GMode = false;
 
 							ieee80211_associate_step2(ieee);
-						}else{
+						} else {
 							ieee80211_auth_challenge(ieee, challenge, chlen);
 						}
-					}else{
+					} else {
 						ieee->softmac_stats.rx_auth_rs_err++;
 						IEEE80211_DEBUG_MGMT("Authentication response status code 0x%x",errcode);
 						ieee80211_associate_abort(ieee);
 					}
 
-				}else if (ieee->iw_mode == IW_MODE_MASTER){
+				} else if (ieee->iw_mode == IW_MODE_MASTER) {
 					ieee80211_rx_auth_rq(ieee, skb);
 				}
 			}
@@ -2176,7 +2176,7 @@ void ieee80211_softmac_xmit(struct ieee80211_txb *txb, struct ieee80211_device *
 #else
 			skb_queue_tail(&ieee->skb_waitQ[queue_index], txb->fragments[i]);
 #endif
-		}else{
+		} else {
 			ieee->softmac_data_hard_start_xmit(
 					txb->fragments[i],
 					ieee->dev, ieee->rate);
@@ -2200,10 +2200,10 @@ static void ieee80211_resume_tx(struct ieee80211_device *ieee)
 	int i;
 	for (i = ieee->tx_pending.frag; i < ieee->tx_pending.txb->nr_frags; i++) {
 
-		if (ieee->queue_stop){
+		if (ieee->queue_stop) {
 			ieee->tx_pending.frag = i;
 			return;
-		}else{
+		} else {
 
 			ieee->softmac_data_hard_start_xmit(
 				ieee->tx_pending.txb->fragments[i],
@@ -2226,7 +2226,7 @@ void ieee80211_reset_queue(struct ieee80211_device *ieee)
 
 	spin_lock_irqsave(&ieee->lock, flags);
 	init_mgmt_queue(ieee);
-	if (ieee->tx_pending.txb){
+	if (ieee->tx_pending.txb) {
 		ieee80211_txb_free(ieee->tx_pending.txb);
 		ieee->tx_pending.txb = NULL;
 	}
@@ -2248,8 +2248,8 @@ void ieee80211_wake_queue(struct ieee80211_device *ieee)
 
 	ieee->queue_stop = 0;
 
-	if (ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE){
-		while (!ieee->queue_stop && (skb = dequeue_mgmt(ieee))){
+	if (ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE) {
+		while (!ieee->queue_stop && (skb = dequeue_mgmt(ieee))) {
 
 			header = (struct ieee80211_hdr_3addr  *) skb->data;
 
@@ -2267,7 +2267,7 @@ void ieee80211_wake_queue(struct ieee80211_device *ieee)
 	if (!ieee->queue_stop && ieee->tx_pending.txb)
 		ieee80211_resume_tx(ieee);
 
-	if (!ieee->queue_stop && netif_queue_stopped(ieee->dev)){
+	if (!ieee->queue_stop && netif_queue_stopped(ieee->dev)) {
 		ieee->softmac_stats.swtxawake++;
 		netif_wake_queue(ieee->dev);
 	}
@@ -2282,7 +2282,7 @@ void ieee80211_stop_queue(struct ieee80211_device *ieee)
 	/* unsigned long flags;
 	spin_lock_irqsave(&ieee->lock,flags); */
 
-	if (! netif_queue_stopped(ieee->dev)){
+	if (! netif_queue_stopped(ieee->dev)) {
 		netif_stop_queue(ieee->dev);
 		ieee->softmac_stats.swtxstop++;
 	}
@@ -2303,7 +2303,7 @@ void ieee80211_start_master_bss(struct ieee80211_device *ieee)
 {
 	ieee->assoc_id = 1;
 
-	if (ieee->current_network.ssid_len == 0){
+	if (ieee->current_network.ssid_len == 0) {
 		strncpy(ieee->current_network.ssid,
 			IEEE80211_DEFAULT_TX_ESSID,
 			IW_ESSID_MAX_SIZE);
@@ -2327,7 +2327,7 @@ void ieee80211_start_master_bss(struct ieee80211_device *ieee)
 
 static void ieee80211_start_monitor_mode(struct ieee80211_device *ieee)
 {
-	if (ieee->raw_tx){
+	if (ieee->raw_tx) {
 
 		if (ieee->data_hard_resume)
 			ieee->data_hard_resume(ieee->dev);
@@ -2347,13 +2347,13 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 	 * (abort) this wq (when syncro scanning) before sleeping
 	 * on the semaphore
 	 */
-	if (!ieee->proto_started){
+	if (!ieee->proto_started) {
 		printk("==========oh driver down return\n");
 		return;
 	}
 	down(&ieee->wx_sem);
 
-	if (ieee->current_network.ssid_len == 0){
+	if (ieee->current_network.ssid_len == 0) {
 		strcpy(ieee->current_network.ssid, IEEE80211_DEFAULT_TX_ESSID);
 		ieee->current_network.ssid_len = strlen(IEEE80211_DEFAULT_TX_ESSID);
 		ieee->ssid_set = 1;
@@ -2384,12 +2384,12 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 		ieee80211_start_scan_syncro(ieee);
 
 	/* the network definitively is not here.. create a new cell */
-	if (ieee->state == IEEE80211_NOLINK){
+	if (ieee->state == IEEE80211_NOLINK) {
 		printk("creating new IBSS cell\n");
 		if (!ieee->wap_set)
 			ieee80211_randomize_cell(ieee);
 
-		if (ieee->modulation & IEEE80211_CCK_MODULATION){
+		if (ieee->modulation & IEEE80211_CCK_MODULATION) {
 
 			ieee->current_network.rates_len = 4;
 
@@ -2398,10 +2398,10 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 			ieee->current_network.rates[2] = IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_5MB;
 			ieee->current_network.rates[3] = IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_11MB;
 
-		}else
+		} else
 			ieee->current_network.rates_len = 0;
 
-		if (ieee->modulation & IEEE80211_OFDM_MODULATION){
+		if (ieee->modulation & IEEE80211_OFDM_MODULATION) {
 			ieee->current_network.rates_ex_len = 8;
 
 			ieee->current_network.rates_ex[0] = IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_6MB;
@@ -2414,7 +2414,7 @@ static void ieee80211_start_ibss_wq(struct work_struct *work)
 			ieee->current_network.rates_ex[7] = IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_54MB;
 
 			ieee->rate = 108;
-		}else{
+		} else {
 			ieee->current_network.rates_ex_len = 0;
 			ieee->rate = 22;
 		}
@@ -2481,7 +2481,7 @@ void ieee80211_start_bss(struct ieee80211_device *ieee)
 	 */
 	spin_lock_irqsave(&ieee->lock, flags);
 
-	if (ieee->state == IEEE80211_NOLINK){
+	if (ieee->state == IEEE80211_NOLINK) {
 		ieee->actscanning = true;
 		ieee80211_start_scan(ieee);
 	}
@@ -2635,12 +2635,12 @@ void ieee80211_start_protocol(struct ieee80211_device *ieee)
 
 	ieee->proto_started = 1;
 
-	if (ieee->current_network.channel == 0){
-		do{
+	if (ieee->current_network.channel == 0) {
+		do {
 			ch++;
 			if (ch > MAX_CHANNEL_NUMBER)
 				return; /* no channel found */
-		}while (!GET_DOT11D_INFO(ieee)->channel_map[ch]);
+		} while (!GET_DOT11D_INFO(ieee)->channel_map[ch]);
 		ieee->current_network.channel = ch;
 	}
 
@@ -2856,12 +2856,12 @@ static int ieee80211_wpa_set_auth_algs(struct ieee80211_device *ieee, int value)
 		sec.auth_mode = WLAN_AUTH_SHARED_KEY;
 		ieee->open_wep = 0;
 		ieee->auth_mode = 1;
-	} else if (value & AUTH_ALG_OPEN_SYSTEM){
+	} else if (value & AUTH_ALG_OPEN_SYSTEM) {
 		sec.auth_mode = WLAN_AUTH_OPEN;
 		ieee->open_wep = 1;
 		ieee->auth_mode = 0;
 	}
-	else if (value & IW_AUTH_ALG_LEAP){
+	else if (value & IW_AUTH_ALG_LEAP) {
 		sec.auth_mode = WLAN_AUTH_LEAP;
 		ieee->open_wep = 1;
 		ieee->auth_mode = 2;
--

1.9.1

--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1425316465-16949-1-git-send-email-haticeerturk27%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

#3 lore raw

This is a another patch. I told you. This patch contains also adding spaces before ' {' and the other ' (' adding spaces before. That's why another patch.

2 Mart 2015 Pazartesi 21:36:36 UTC+2 tarihinde Julia Lawall yazdı:

Quoted 894 lines · Hatice ERTÜRK
Quoted 3 lines

Space required before the open brace '{' and after the close brace '}' This Error found with checkpatch.pl

I think that this is a v2, but you have not indicated that?

julia

Quoted 3 lines
Signed-off-by Hatice ERTURK <[email protected] <javascript:>>

---

 .../staging/rtl8192u/ieee80211/ieee80211_softmac.c | 184 

++++++++++-----------

Review

Quoted 3 lines
 1 file changed, 92 insertions(+), 92 deletions(-) 
(quoted diff) +0 -0

b/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_MFIE_Brate(struct

Quoted 4 lines

index 057d4d1..2c53763 100644

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -62,7 +62,7 @@ static void ieee80211_MFIE_Brate(struct 

ieee80211_device *ieee, u8 **tag_p)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_MFIE_Brate(struct ieee80211_device *ieee, u8 **tag_p)

Quoted 8 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
 { 
         u8 *tag = *tag_p; 
 
-        if (ieee->modulation & IEEE80211_CCK_MODULATION){ 
+        if (ieee->modulation & IEEE80211_CCK_MODULATION) { 
                 *tag++ = MFIE_TYPE_RATES; 
                 *tag++ = 4; 
                 *tag++ = IEEE80211_BASIC_RATE_MASK | 

IEEE80211_CCK_RATE_1MB;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_MFIE_Grate(struct

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -79,7 +79,7 @@ static void ieee80211_MFIE_Grate(struct 

ieee80211_device *ieee, u8 **tag_p)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static u8 MgntQuery_MgntFrameTxRate(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
 { 
         u8 *tag = *tag_p; 
 
-                if (ieee->modulation & IEEE80211_OFDM_MODULATION){ 
+                if (ieee->modulation & IEEE80211_OFDM_MODULATION) { 
 
                 *tag++ = MFIE_TYPE_RATES_EX; 
                 *tag++ = 8; 
@@ -192,7 +192,7 @@ static u8 MgntQuery_MgntFrameTxRate(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_mgmt_xmit(struct sk_buff *skb,

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         else 
                 rate = ieee->basic_rate & 0x7f; 
 
-        if (rate == 0){ 
+        if (rate == 0) { 
                 /* 2005.01.26, by rcnjko. */ 
                 if (ieee->mode == IEEE_A|| 
                    ieee->mode== IEEE_N_5G|| 
@@ -237,10 +237,10 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, 

struct ieee80211_device *ieee

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee

Quoted 11 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +3 -3
         tcb_desc->bTxDisableRateFallBack = 1; 
         tcb_desc->bTxUseDriverAssingedRate = 1; 
 
-        if (single){ 
-                if (ieee->queue_stop){ 
+        if (single) { 
+                if (ieee->queue_stop) { 
                         enqueue_mgmt(ieee, skb); 
-                }else{ 
+                } else { 
                         header->seq_ctl = 

cpu_to_le16(ieee->seq_ctrl[0]<<4);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_mgmt_xmit(struct sk_buff *skb,

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         if (ieee->seq_ctrl[0] == 0xFFF) 
@@ -255,7 +255,7 @@ inline void softmac_mgmt_xmit(struct sk_buff *skb, 

struct ieee80211_device *ieee

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_ps_mgmt_xmit(struct sk_buff

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 } 
 
                 spin_unlock_irqrestore(&ieee->lock, flags); 
-        }else{ 
+        } else { 
                 spin_unlock_irqrestore(&ieee->lock, flags); 
                 spin_lock_irqsave(&ieee->mgmt_tx_lock, flags); 
 
@@ -293,7 +293,7 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff 

*skb, struct ieee80211_device *i

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_ps_mgmt_xmit(struct sk_buff

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 (struct ieee80211_hdr_3addr  *) skb->data; 
 
 
-        if (single){ 
+        if (single) { 
 
                 header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0] << 4); 
 
@@ -306,7 +306,7 @@ inline void softmac_ps_mgmt_xmit(struct sk_buff 

*skb, struct ieee80211_device *i

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_ps_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *i · line 308

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 ieee->dev->trans_start = jiffies; 
 
                 ieee->softmac_data_hard_start_xmit(skb,ieee->dev,ieee->basic_rate); 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_beacon(struct

Quoted 7 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-        }else{ 
+        } else { 
 
                 header->seq_ctl = cpu_to_le16(ieee->seq_ctrl[0] << 4); 
 
@@ -369,7 +369,7 @@ static void ieee80211_send_beacon(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_beacon(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         /* unsigned long flags; */ 
         skb = ieee80211_get_beacon_(ieee); 
 
-        if (skb){ 
+        if (skb) { 
                 softmac_mgmt_xmit(skb, ieee); 
                 ieee->softmac_stats.tx_beacons++; 
                 /* dev_kfree_skb_any(skb); edit by thomas */ 
@@ -378,7 +378,7 @@ static void ieee80211_send_beacon(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_beacon(struct ieee80211_device *ieee)

Quoted 8 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 (MSECS( ieee->current_network.beacon_interval -5)); 
 
         spin_lock_irqsave(&ieee->beacon_lock,flags); */ 
-        if (ieee->beacon_txing && ieee->ieee_up){ 
+        if (ieee->beacon_txing && ieee->ieee_up) { 
                 /* if(!timer_pending(&ieee->beacon_timer)) 
                         add_timer(&ieee->beacon_timer); */ 
 
                 mod_timer(&ieee->beacon_timer,jiffies+(MSECS(ieee->current_network.beacon_interval-5))); 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_probe(struct

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -404,7 +404,7 @@ static void ieee80211_send_probe(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_probe(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         struct sk_buff *skb; 
 
         skb = ieee80211_probe_req(ieee); 
-        if (skb){ 
+        if (skb) { 
                 softmac_mgmt_xmit(skb, ieee); 
                 ieee->softmac_stats.tx_probe_rq++; 
                 /* dev_kfree_skb_any(skb); edit by thomas */ 
@@ -413,7 +413,7 @@ static void ieee80211_send_probe(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_probe(struct · line 413

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
 static void ieee80211_send_probe_requests(struct ieee80211_device 

*ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_probe(struct · line 415

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
 { 
-        if (ieee->active_scan && (ieee->softmac_features & 

IEEE_SOFTMAC_PROBERQ)){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_send_probe(struct · line 415

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+        if (ieee->active_scan && (ieee->softmac_features & 

IEEE_SOFTMAC_PROBERQ)) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_softmac_scan_syncro(struct

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 ieee80211_send_probe(ieee); 
                 ieee80211_send_probe(ieee); 
         } 
@@ -433,11 +433,11 @@ void ieee80211_softmac_scan_syncro(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_softmac_scan_syncro(struct

Quoted 14 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
         while (1) 
         { 
 
-                do{ 
+                do { 
                         ch++; 
                         if (ch > MAX_CHANNEL_NUMBER) 
                                 goto out; /* scan completed */ 
-                }while (!channel_map[ch]); 
+                } while (!channel_map[ch]); 
 
                 /* this function can be called in two situations 
                  * 1- We have switched to ad-hoc mode and we are 
@@ -478,7 +478,7 @@ void ieee80211_softmac_scan_syncro(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_softmac_scan_wq(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         } 
 out: 
-        if (ieee->state < IEEE80211_LINKED){ 
+        if (ieee->state < IEEE80211_LINKED) { 
                 ieee->actscanning = false; 
                 up(&ieee->scan_sem); 
         } 
@@ -501,7 +501,7 @@ static void ieee80211_softmac_scan_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_softmac_scan_wq(struct work_struct *work)

Quoted 7 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         if (!ieee->ieee_up) 
                 return; 
         down(&ieee->scan_sem); 
-        do{ 
+        do { 
                 ieee->current_network.channel = 
                         (ieee->current_network.channel + 1) % 

MAX_CHANNEL_NUMBER;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_softmac_scan_wq(struct

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 if (watchdog++ > MAX_CHANNEL_NUMBER) 
@@ -512,7 +512,7 @@ static void ieee80211_softmac_scan_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_softmac_stop_scan(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                                 goto out; /* no good chans */ 
                         } 
                 } 
-        }while (!channel_map[ieee->current_network.channel]); 
+        } while (!channel_map[ieee->current_network.channel]); 
         if (ieee->scanning == 0 ) 
                 goto out; 
         ieee->set_chan(ieee->dev, ieee->current_network.channel); 
@@ -587,7 +587,7 @@ static void ieee80211_softmac_stop_scan(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_scan(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         down(&ieee->scan_sem); 
         /* spin_lock_irqsave(&ieee->lock, flags); */ 
 
-        if (ieee->scanning == 1){ 
+        if (ieee->scanning == 1) { 
                 ieee->scanning = 0; 
 
                 cancel_delayed_work(&ieee->softmac_scan_wq); 
@@ -616,12 +616,12 @@ static void ieee80211_start_scan(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_scan(struct ieee80211_device *ieee)

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
                         RESET_CIE_WATCHDOG(ieee); 
                 } 
         } 
-        if (ieee->softmac_features & IEEE_SOFTMAC_SCAN){ 
-                if (ieee->scanning == 0){ 
+        if (ieee->softmac_features & IEEE_SOFTMAC_SCAN) { 
+                if (ieee->scanning == 0) { 
                         ieee->scanning = 1; 
                         queue_delayed_work(ieee->wq, 

&ieee->softmac_scan_wq, 0);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static struct sk_buff *ieee80211_probe_resp(struct

Quoted 7 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 } 
-        }else 
+        } else 
                 ieee->start_scan(ieee->dev); 
 
 } 
@@ -803,7 +803,7 @@ static struct sk_buff *ieee80211_probe_resp(struct 

ieee80211_device *ieee, u8 *d

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static struct sk_buff *ieee80211_probe_resp(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         *(tag++) = 1; 
         *(tag++) = ieee->current_network.channel; 
 
-        if (atim_len){ 
+        if (atim_len) { 
                 *(tag++) = MFIE_TYPE_IBSS_SET; 
                 *(tag++) = 2; 
 
@@ -812,12 +812,12 @@ static struct sk_buff *ieee80211_probe_resp(struct 

ieee80211_device *ieee, u8 *d

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
                 tag+=2; 
         } 
 
-        if (erp_len){ 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static struct sk_buff *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d

Quoted 10 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -1
+        if (erp_len) { 
                 *(tag++) = MFIE_TYPE_ERP; 
                 *(tag++) = 1; 
                 *(tag++) = erpinfo_content; 
         } 
-        if (rate_ex_len){ 
+        if (rate_ex_len) { 
                 *(tag++) = MFIE_TYPE_RATES_EX; 
                 *(tag++) = rate_ex_len-2; 
                 memcpy(tag, ieee->current_network.rates_ex, 

rate_ex_len-2);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -1169,7 +1169,7 @@ inline struct sk_buff 

*ieee80211_association_req(struct ieee80211_network *beaco

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff *ieee80211_association_req(struct ieee80211_network *beaco

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
                 tag += osCcxVerNum.Length; 
         } 
         /* HT cap element */ 
-        if 

(ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff · line 1172

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+        if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) 

{

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 if (ieee->pHTInfo->ePeerHTSpecVer != HT_SPEC_VER_EWC) 
                 { 
                         tag = skb_put(skb, ht_cap_len); 
@@ -1183,7 +1183,7 @@ inline struct sk_buff 

*ieee80211_association_req(struct ieee80211_network *beaco

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         /* choose what wpa_supplicant gives to associate. */ 
         tag = skb_put(skb, wpa_ie_len); 
-        if (wpa_ie_len){ 
+        if (wpa_ie_len) { 
                 memcpy(tag, ieee->wpa_ie, ieee->wpa_ie_len); 
         } 
 
@@ -1198,7 +1198,7 @@ inline struct sk_buff 

*ieee80211_association_req(struct ieee80211_network *beaco

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff · line 1201

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
         } 
 #endif 
 
-        if 

(ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff · line 1201

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+        if (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) 

{

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline struct sk_buff

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 if (ieee->pHTInfo->ePeerHTSpecVer == HT_SPEC_VER_EWC) 
                 { 
                         tag = skb_put(skb, ht_cap_len); 
@@ -1208,7 +1208,7 @@ inline struct sk_buff 

*ieee80211_association_req(struct ieee80211_network *beaco

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_associate_abort(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                         tag += ht_cap_len -2; 
                 } 
 
-                if (ieee->pHTInfo->bCurrentRT2RTAggregation){ 
+                if (ieee->pHTInfo->bCurrentRT2RTAggregation) { 
                         tag = skb_put(skb, realtek_ie_len); 
                         *tag++ = MFIE_TYPE_GENERIC; 
                         *tag++ = realtek_ie_len - 2; 
@@ -1234,10 +1234,10 @@ void ieee80211_associate_abort(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_associate_step1(struct

Quoted 13 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
          * Here we will check if there are good nets to associate 
          * with, so we retry or just get back to NO_LINK and scanning 
          */ 
-        if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING){ 
+        if (ieee->state == IEEE80211_ASSOCIATING_AUTHENTICATING) { 
                 IEEE80211_DEBUG_MGMT("Authentication failed\n"); 
                 ieee->softmac_stats.no_auth_rs++; 
-        }else{ 
+        } else { 
                 IEEE80211_DEBUG_MGMT("Association failed\n"); 
                 ieee->softmac_stats.no_ass_rs++; 
         } 
@@ -1274,7 +1274,7 @@ static void ieee80211_associate_step1(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_associate_step1(struct · line 1274

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 /* printk(KERN_WARNING "Sending authentication 

request\n"); */

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_associate_step1(struct · line 1276

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 softmac_mgmt_xmit(skb, ieee); 
                 /* BUGON when you try to add_timer twice, using 

mod_timer may be better, john0709 */

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_associate_step1(struct ieee80211_device *ieee)

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                if (!timer_pending(&ieee->associate_timer)){ 
+                if (!timer_pending(&ieee->associate_timer)) { 
                         ieee->associate_timer.expires = jiffies + (HZ / 

2);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         add_timer(&ieee->associate_timer); 
                 } 
@@ -1338,11 +1338,11 @@ static void 

ieee80211_associate_complete_wq(struct work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void · line 1338

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
         struct ieee80211_device *ieee = container_of(work, struct 

ieee80211_device, associate_complete_wq);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_associate_complete_wq(struct

Quoted 13 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
         printk(KERN_INFO "Associated successfully\n"); 
         if (ieee80211_is_54g(&ieee->current_network) && 
-                (ieee->modulation & IEEE80211_OFDM_MODULATION)){ 
+                (ieee->modulation & IEEE80211_OFDM_MODULATION)) { 
 
                 ieee->rate = 108; 
                 printk(KERN_INFO"Using G rates:%d\n", ieee->rate); 
-        }else{ 
+        } else { 
                 ieee->rate = 22; 
                 printk(KERN_INFO"Using B rates:%d\n", ieee->rate); 
         } 
@@ -1365,7 +1365,7 @@ static void ieee80211_associate_complete_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 ieee->LinkDetectInfo.NumRecvDataInPeriod= 1; 
         } 
         ieee->link_change(ieee->dev); 
-        if (ieee->is_silent_reset == 0){ 
+        if (ieee->is_silent_reset == 0) { 
                 printk("============>normal associate\n"); 
         notify_wx_assoc_event(ieee); 
         } 
@@ -1431,7 +1431,7 @@ inline void ieee80211_softmac_new_net(struct 

ieee80211_device *ieee, struct ieee

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1434

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
                 return; 
 
 
-        if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode == 

IW_MODE_ADHOC){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1434

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+        if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode == 

IW_MODE_ADHOC) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1435

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 /* if the user specified the AP MAC, we need also the 

essid

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1436

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                  * This could be obtained by beacons or, if the network 

does not

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                  * broadcast it, it can be put manually. 
@@ -1459,13 +1459,13 @@ inline void ieee80211_softmac_new_net(struct 

ieee80211_device *ieee, struct ieee

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1459

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                 /* if the essid is hidden replace it 

with the

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee

Quoted 5 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                                 * essid provided by the user. 
                                 */ 
-                                if (!ssidbroad){ 
+                                if (!ssidbroad) { 
                                         strncpy(tmp_ssid, 

ieee->current_network.ssid, IW_ESSID_MAX_SIZE);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1464

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                         tmp_ssid_len = 

ieee->current_network.ssid_len;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1466

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                 } 
                                 memcpy(&ieee->current_network, net, 

sizeof(struct ieee80211_network));

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee · line 1467

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                                if (!ssidbroad){ 
+                                if (!ssidbroad) { 
 
                                         strncpy(ieee->current_network.ssid, 

tmp_ssid, IW_ESSID_MAX_SIZE);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1469

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                         ieee->current_network.ssid_len 

= tmp_ssid_len;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                 } 
@@ -1473,7 +1473,7 @@ inline void ieee80211_softmac_new_net(struct 

ieee80211_device *ieee, struct ieee

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct ieee

Quoted 6 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                                 /* ieee->pHTInfo->IOTAction = 0; */ 
                                 HTResetIOTSetting(ieee->pHTInfo); 
-                                if (ieee->iw_mode == IW_MODE_INFRA){ 
+                                if (ieee->iw_mode == IW_MODE_INFRA) { 
                                         /* Join the network for the 

first time */

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                         ieee->AsocRetryCount = 0; 
                                         /* for HT by amy 080514 */ 
@@ -1492,13 +1492,13 @@ inline void ieee80211_softmac_new_net(struct 

ieee80211_device *ieee, struct ieee

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1492

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                         ieee->state = 

IEEE80211_ASSOCIATING;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1493

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                         queue_work(ieee->wq, 

&ieee->associate_procedure_wq);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                                }else{ 
+                                } else { 
                                         if 

(ieee80211_is_54g(&ieee->current_network) &&

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1496

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
-                                                (ieee->modulation & 

IEEE80211_OFDM_MODULATION)){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1496

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+                                                (ieee->modulation & 

IEEE80211_OFDM_MODULATION)) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1498

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                                 ieee->rate = 108; 
 
                                                 ieee->SetWirelessMode(ieee->dev, 

IEEE_G);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1499

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                                 printk(KERN_INFO"Using 

G rates\n");

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_associate_complete_wq(struct work_struct *work)

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                                        }else{ 
+                                        } else { 
                                                 ieee->rate = 22; 
 
                                                 ieee->SetWirelessMode(ieee->dev, 

IEEE_B);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void ieee80211_softmac_new_net(struct · line 1503

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                                 printk(KERN_INFO"Using 

B rates\n");

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 auth_parse(struct sk_buff

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -1542,16 +1542,16 @@ static inline u16 auth_parse(struct sk_buff 

*skb, u8 **challenge, int *chlen)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 auth_parse(struct sk_buff *skb, u8 **challenge, int *chlen)

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
 { 
         struct ieee80211_authentication *a; 
         u8 *t; 
-        if (skb->len <  (sizeof(struct 

ieee80211_authentication)-sizeof(struct ieee80211_info_element))){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 auth_parse(struct sk_buff · line 1545

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+        if (skb->len <  (sizeof(struct 

ieee80211_authentication)-sizeof(struct ieee80211_info_element))) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 auth_parse(struct sk_buff · line 1546

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 IEEE80211_DEBUG_MGMT("invalid len in auth resp: 

%d\n",skb->len);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 auth_parse(struct sk_buff *skb, u8 **challenge, int *chlen)

Quoted 7 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 return 0xcafe; 
         } 
         *challenge = NULL; 
         a = (struct ieee80211_authentication *) skb->data; 
-        if (skb->len > (sizeof(struct ieee80211_authentication) +3)){ 
+        if (skb->len > (sizeof(struct ieee80211_authentication) +3)) { 
                 t = skb->data + sizeof(struct 

ieee80211_authentication);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static int auth_rq_parse(struct sk_buff *skb, u8

Quoted 7 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                if (*(t++) == MFIE_TYPE_CHALLENGE){ 
+                if (*(t++) == MFIE_TYPE_CHALLENGE) { 
                         *chlen = *(t++); 
                         *challenge = kmemdup(t, *chlen, GFP_ATOMIC); 
                         if (!*challenge) 
@@ -1568,7 +1568,7 @@ static int auth_rq_parse(struct sk_buff *skb, u8 

*dest)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 auth_parse(struct sk_buff *skb, u8 **challenge, int *chlen)

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
 { 
         struct ieee80211_authentication *a; 
 
-        if (skb->len <  (sizeof(struct 

ieee80211_authentication)-sizeof(struct ieee80211_info_element))){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static int auth_rq_parse(struct sk_buff *skb, u8 · line 1571

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+        if (skb->len <  (sizeof(struct 

ieee80211_authentication)-sizeof(struct ieee80211_info_element))) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static int auth_rq_parse(struct sk_buff *skb, u8 · line 1572

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 IEEE80211_DEBUG_MGMT("invalid len in auth request: 

%d\n",skb->len);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static short probe_rq_parse(struct

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 return -1; 
         } 
@@ -1601,8 +1601,8 @@ static short probe_rq_parse(struct 

ieee80211_device *ieee, struct sk_buff *skb,

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 assoc_parse(struct

Quoted 11 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
         tag = skb->data + sizeof (struct ieee80211_hdr_3addr  ); 
 
-        while (tag+1 < skbend){ 
-                if (*tag == 0){ 
+        while (tag+1 < skbend) { 
+                if (*tag == 0) { 
                         ssid = tag+2; 
                         ssidlen = *(tag+1); 
                         break; 
@@ -1643,7 +1643,7 @@ static inline u16 assoc_parse(struct 

ieee80211_device *ieee, struct sk_buff *skb

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 assoc_parse(struct ieee80211_device *ieee, struct sk_buff *skb

Quoted 5 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         struct ieee80211_assoc_response_frame *response_head; 
         u16 status_code; 
 
-        if (skb->len <  sizeof(struct ieee80211_assoc_response_frame)){ 
+        if (skb->len <  sizeof(struct ieee80211_assoc_response_frame)) 

{

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 assoc_parse(struct · line 1647

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 IEEE80211_DEBUG_MGMT("invalid len in auth resp: %d\n", 

skb->len);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline u16 assoc_parse(struct

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 return 0xcafe; 
         } 
@@ -1658,7 +1658,7 @@ static inline u16 assoc_parse(struct 

ieee80211_device *ieee, struct sk_buff *skb

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_probe_rq(struct ieee80211_device

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
             (ieee->current_network.mode == IEEE_N_24G) && 
             (ieee->AsocRetryCount++ < (RT_ASOC_RETRY_LIMIT-1)))) { 
                  ieee->pHTInfo->IOTAction |= HT_IOT_ACT_PURE_N_MODE; 
-        }else { 
+        } else { 
                  ieee->AsocRetryCount = 0; 
         } 
 
@@ -1673,7 +1673,7 @@ ieee80211_rx_probe_rq(struct ieee80211_device 

*ieee, struct sk_buff *skb)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_assoc_rq(struct ieee80211_device

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         /* IEEE80211DMESG("Rx probe"); */ 
         ieee->softmac_stats.rx_probe_rq++; 
         /* DMESG("Dest is "MACSTR, MAC2STR(dest)); */ 
-        if (probe_rq_parse(ieee, skb, dest)){ 
+        if (probe_rq_parse(ieee, skb, dest)) { 
                 /* IEEE80211DMESG("Was for me!"); */ 
                 ieee->softmac_stats.tx_probe_rs++; 
                 ieee80211_resp_to_probe(ieee, dest); 
@@ -1704,7 +1704,7 @@ ieee80211_rx_assoc_rq(struct ieee80211_device 

*ieee, struct sk_buff *skb)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static short ieee80211_sta_ps_sleep(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         /* unsigned long flags; */ 
 
         ieee->softmac_stats.rx_ass_rq++; 
-        if (assoc_rq_parse(skb,dest) != -1){ 
+        if (assoc_rq_parse(skb,dest) != -1) { 
                 ieee80211_resp_to_assoc_rq(ieee, dest); 
         } 
 
@@ -1756,13 +1756,13 @@ static short ieee80211_sta_ps_sleep(struct 

ieee80211_device *ieee, u32 *time_h,

Quoted 4 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
                 (ieee->mgmt_queue_tail != ieee->mgmt_queue_head)) 
                 return 0; 
 
-        if (time_l){ 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static short ieee80211_sta_ps_sleep(struct ieee80211_device *ieee, u32 *time_h,

Quoted 10 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -1
+        if (time_l) { 
                 *time_l = ieee->current_network.last_dtim_sta_time[0] 
                         + (ieee->current_network.beacon_interval 
                         * ieee->current_network.dtim_period) * 1000; 
         } 
 
-        if (time_h){ 
+        if (time_h) { 
                 *time_h = ieee->current_network.last_dtim_sta_time[1]; 
                 if (time_l && *time_l < 

ieee->current_network.last_dtim_sta_time[0])

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline void ieee80211_sta_ps(struct

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         *time_h += 1; 
@@ -1800,16 +1800,16 @@ static inline void ieee80211_sta_ps(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static inline void ieee80211_sta_ps(struct

Quoted 20 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +3 -3
         if (sleep == 0) 
                 goto out; 
 
-        if (sleep == 1){ 
+        if (sleep == 1) { 
 
                 if (ieee->sta_sleep == 1) 
                         ieee->enter_sleep_state(ieee->dev, th, tl); 
 
-                else if (ieee->sta_sleep == 0){ 
+                else if (ieee->sta_sleep == 0) { 
                         /* printk("send null 1\n"); */ 
                         spin_lock_irqsave(&ieee->mgmt_tx_lock, flags2); 
 
-                        if (ieee->ps_is_queue_empty(ieee->dev)){ 
+                        if (ieee->ps_is_queue_empty(ieee->dev)) { 
 
 
                                 ieee->sta_sleep = 2; 
@@ -1826,7 +1826,7 @@ static inline void ieee80211_sta_ps(struct 

ieee80211_device *ieee)

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                 } 
 
 
-        }else if (sleep == 2){ 
+        } else if (sleep == 2) { 
 /* #warning CHECK_LOCK_HERE */ 
                 spin_lock_irqsave(&ieee->mgmt_tx_lock, flags2); 
 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c out: · line 1847

Quoted 8 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
@@ -1842,8 +1842,8 @@ out: 
 
 void ieee80211_sta_wakeup(struct ieee80211_device *ieee, short nl) 
 { 
-        if (ieee->sta_sleep == 0){ 
-                if (nl){ 
+        if (ieee->sta_sleep == 0) { 
+                if (nl) { 
                         printk("Warning: driver is probably failing to 

report TX ps error\n");

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_sta_wakeup(struct ieee80211_device

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         ieee->ps_request_tx_ack(ieee->dev); 
                         ieee80211_sta_ps_send_null_frame(ieee, 0); 
@@ -1857,7 +1857,7 @@ void ieee80211_sta_wakeup(struct ieee80211_device 

*ieee, short nl)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_ps_tx_ack(struct ieee80211_device

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         ieee->sta_sleep = 0; 
 
-        if (nl){ 
+        if (nl) { 
                 ieee->ps_request_tx_ack(ieee->dev); 
                 ieee80211_sta_ps_send_null_frame(ieee, 0); 
         } 
@@ -1869,9 +1869,9 @@ void ieee80211_ps_tx_ack(struct ieee80211_device 

*ieee, short success)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_ps_tx_ack(struct ieee80211_device *ieee, short success)

Quoted 10 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
         spin_lock_irqsave(&ieee->lock, flags); 
 
-        if (ieee->sta_sleep == 2){ 
+        if (ieee->sta_sleep == 2) { 
                 /* Null frame with PS bit set */ 
-                if (success){ 
+                if (success) { 
                         ieee->sta_sleep = 1; 
 
                         ieee->enter_sleep_state(ieee->dev,ieee->ps_th,ieee->ps_tl); 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 } 
@@ -2014,7 +2014,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device 

*ieee, struct sk_buff *skb,

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device *ieee, struct sk_buff *skb,

Quoted 6 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         case IEEE80211_STYPE_AUTH: 
 
-                if (ieee->softmac_features & IEEE_SOFTMAC_ASSOCIATE){ 
+                if (ieee->softmac_features & IEEE_SOFTMAC_ASSOCIATE) { 
                         if (ieee->state == 

IEEE80211_ASSOCIATING_AUTHENTICATING &&

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         ieee->iw_mode == IW_MODE_INFRA){ 
 
@@ -2022,7 +2022,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device 

*ieee, struct sk_buff *skb,

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device · line 2022

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                         errcode = auth_parse(skb, 

&challenge, &chlen);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device · line 2024

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -1
                                         if (!errcode) { 
-                                                if (ieee->open_wep || 

!challenge){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device · line 2024

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -0
+                                                if (ieee->open_wep || 

!challenge) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device · line 2025

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                                         ieee->state = 

IEEE80211_ASSOCIATING_AUTHENTICATED;

Quoted 1 line
                                                         ieee->softmac_stats.rx_auth_rs_ok++; 
Quoted 1 line

if

(!(ieee->pHTInfo->IOTAction&HT_IOT_ACT_PURE_N_MODE))

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -2048,7 +2048,7 @@ ieee80211_rx_frame_softmac(struct ieee80211_device 

*ieee, struct sk_buff *skb,

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct ieee80211_device · line 2048

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                                                                 /* N 

mode setting */

Quoted 1 line
                                                                 ieee->SetWirelessMode(ieee->dev, 

\

Quoted 1 line
                                                                                 ieee->current_network.mode); 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c inline void softmac_mgmt_xmit(struct sk_buff *skb, struct ieee80211_device *ieee

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                                                        }else{ 
+                                                        } else { 
                                                                 /* b/g 

mode setting */

Quoted 1 line
                                                                 /*TODO*/ 
Quoted 1 line
                                                                 ieee->SetWirelessMode(ieee->dev, 

IEEE_G);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c ieee80211_rx_frame_softmac(struct

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -2063,16 +2063,16 @@ ieee80211_rx_frame_softmac(struct 

ieee80211_device *ieee, struct sk_buff *skb,

Quoted 1 line
                                                                 ieee->bHalfWirelessN24GMode 

= false;

Quoted 2 lines
                                                         ieee80211_associate_step2(ieee); 

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c

Quoted 3 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                                                }else{ 
+                                                } else { 
                                                         ieee80211_auth_challenge(ieee, 

challenge, chlen);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c

Quoted 4 lines
                                                 } 
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
-                                        }else{ 
+                                        } else { 
                                                 ieee->softmac_stats.rx_auth_rs_err++; 
Quoted 1 line

IEEE80211_DEBUG_MGMT("Authentication
response status code 0x%x",errcode);

Quoted 1 line
                                                 ieee80211_associate_abort(ieee); 
Quoted 3 lines
                                         } 

- }else if (ieee->iw_mode ==

IW_MODE_MASTER){

Quoted 1 line

+ } else if (ieee->iw_mode ==

IW_MODE_MASTER) {

Quoted 1 line
                                         ieee80211_rx_auth_rq(ieee, 

skb);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_softmac_xmit(struct ieee80211_txb

Quoted 3 lines
                                 } 
                         } 
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -2176,7 +2176,7 @@ void ieee80211_softmac_xmit(struct ieee80211_txb 

*txb, struct ieee80211_device *

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_softmac_xmit(struct ieee80211_txb · line 2177

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
 #else 
                         skb_queue_tail(&ieee->skb_waitQ[queue_index], 

txb->fragments[i]);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_resume_tx(struct

Quoted 7 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
 #endif 
-                }else{ 
+                } else { 
                         ieee->softmac_data_hard_start_xmit( 
                                         txb->fragments[i], 
                                         ieee->dev, ieee->rate); 
@@ -2200,10 +2200,10 @@ static void ieee80211_resume_tx(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_resume_tx(struct · line 2201

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
         int i; 
         for (i = ieee->tx_pending.frag; i < 

ieee->tx_pending.txb->nr_frags; i++) {

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_reset_queue(struct ieee80211_device

Quoted 11 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
-                if (ieee->queue_stop){ 
+                if (ieee->queue_stop) { 
                         ieee->tx_pending.frag = i; 
                         return; 
-                }else{ 
+                } else { 
 
                         ieee->softmac_data_hard_start_xmit( 
                                 ieee->tx_pending.txb->fragments[i], 
@@ -2226,7 +2226,7 @@ void ieee80211_reset_queue(struct ieee80211_device 

*ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_wake_queue(struct ieee80211_device

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         spin_lock_irqsave(&ieee->lock, flags); 
         init_mgmt_queue(ieee); 
-        if (ieee->tx_pending.txb){ 
+        if (ieee->tx_pending.txb) { 
                 ieee80211_txb_free(ieee->tx_pending.txb); 
                 ieee->tx_pending.txb = NULL; 
         } 
@@ -2248,8 +2248,8 @@ void ieee80211_wake_queue(struct ieee80211_device 

*ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_wake_queue(struct ieee80211_device *ieee)

Quoted 5 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -2
         ieee->queue_stop = 0; 
 
-        if (ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE){ 
-                while (!ieee->queue_stop && (skb = 

dequeue_mgmt(ieee))){

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_wake_queue(struct ieee80211_device · line 2251

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -0
+        if (ieee->softmac_features & IEEE_SOFTMAC_SINGLE_QUEUE) { 
+                while (!ieee->queue_stop && (skb = dequeue_mgmt(ieee))) 

{

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_wake_queue(struct ieee80211_device · line 2252

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         header = (struct ieee80211_hdr_3addr  *) 

skb->data;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_wake_queue(struct ieee80211_device

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -2267,7 +2267,7 @@ void ieee80211_wake_queue(struct ieee80211_device 

*ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_stop_queue(struct ieee80211_device

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         if (!ieee->queue_stop && ieee->tx_pending.txb) 
                 ieee80211_resume_tx(ieee); 
 
-        if (!ieee->queue_stop && netif_queue_stopped(ieee->dev)){ 
+        if (!ieee->queue_stop && netif_queue_stopped(ieee->dev)) { 
                 ieee->softmac_stats.swtxawake++; 
                 netif_wake_queue(ieee->dev); 
         } 
@@ -2282,7 +2282,7 @@ void ieee80211_stop_queue(struct ieee80211_device 

*ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_start_master_bss(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
         /* unsigned long flags; 
         spin_lock_irqsave(&ieee->lock,flags); */ 
 
-        if (! netif_queue_stopped(ieee->dev)){ 
+        if (! netif_queue_stopped(ieee->dev)) { 
                 netif_stop_queue(ieee->dev); 
                 ieee->softmac_stats.swtxstop++; 
         } 
@@ -2303,7 +2303,7 @@ void ieee80211_start_master_bss(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_start_master_bss(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
 { 
         ieee->assoc_id = 1; 
 
-        if (ieee->current_network.ssid_len == 0){ 
+        if (ieee->current_network.ssid_len == 0) { 
                 strncpy(ieee->current_network.ssid, 
                         IEEE80211_DEFAULT_TX_ESSID, 
                         IW_ESSID_MAX_SIZE); 
@@ -2327,7 +2327,7 @@ void ieee80211_start_master_bss(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
 static void ieee80211_start_monitor_mode(struct ieee80211_device *ieee) 
 { 
-        if (ieee->raw_tx){ 
+        if (ieee->raw_tx) { 
 
                 if (ieee->data_hard_resume) 
                         ieee->data_hard_resume(ieee->dev); 
@@ -2347,13 +2347,13 @@ static void ieee80211_start_ibss_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct work_struct *work)

Quoted 13 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
          * (abort) this wq (when syncro scanning) before sleeping 
          * on the semaphore 
          */ 
-        if (!ieee->proto_started){ 
+        if (!ieee->proto_started) { 
                 printk("==========oh driver down return\n"); 
                 return; 
         } 
         down(&ieee->wx_sem); 
 
-        if (ieee->current_network.ssid_len == 0){ 
+        if (ieee->current_network.ssid_len == 0) { 
                 strcpy(ieee->current_network.ssid, 

IEEE80211_DEFAULT_TX_ESSID);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct · line 2358

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 ieee->current_network.ssid_len = 

strlen(IEEE80211_DEFAULT_TX_ESSID);

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct

Quoted 2 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                 ieee->ssid_set = 1; 
@@ -2384,12 +2384,12 @@ static void ieee80211_start_ibss_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct

Quoted 15 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
                 ieee80211_start_scan_syncro(ieee); 
 
         /* the network definitively is not here.. create a new cell */ 
-        if (ieee->state == IEEE80211_NOLINK){ 
+        if (ieee->state == IEEE80211_NOLINK) { 
                 printk("creating new IBSS cell\n"); 
                 if (!ieee->wap_set) 
                         ieee80211_randomize_cell(ieee); 
 
-                if (ieee->modulation & IEEE80211_CCK_MODULATION){ 
+                if (ieee->modulation & IEEE80211_CCK_MODULATION) { 
 
                         ieee->current_network.rates_len = 4; 
 
@@ -2398,10 +2398,10 @@ static void ieee80211_start_ibss_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct · line 2398

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         ieee->current_network.rates[2] = 

IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_5MB;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct · line 2399

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         ieee->current_network.rates[3] = 

IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_11MB;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct work_struct *work)

Quoted 10 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
-                }else 
+                } else 
                         ieee->current_network.rates_len = 0; 
 
-                if (ieee->modulation & IEEE80211_OFDM_MODULATION){ 
+                if (ieee->modulation & IEEE80211_OFDM_MODULATION) { 
                         ieee->current_network.rates_ex_len = 8; 
 
                         ieee->current_network.rates_ex[0] = 

IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_6MB;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
@@ -2414,7 +2414,7 @@ static void ieee80211_start_ibss_wq(struct 

work_struct *work)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static void ieee80211_start_ibss_wq(struct · line 2414

Quoted 1 line
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +0 -0
                         ieee->current_network.rates_ex[7] = 

IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_54MB;

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_start_bss(struct ieee80211_device

Quoted 8 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
                         ieee->rate = 108; 
-                }else{ 
+                } else { 
                         ieee->current_network.rates_ex_len = 0; 
                         ieee->rate = 22; 
                 } 
@@ -2481,7 +2481,7 @@ void ieee80211_start_bss(struct ieee80211_device 

*ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c void ieee80211_start_protocol(struct

Quoted 9 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +1 -1
          */ 
         spin_lock_irqsave(&ieee->lock, flags); 
 
-        if (ieee->state == IEEE80211_NOLINK){ 
+        if (ieee->state == IEEE80211_NOLINK) { 
                 ieee->actscanning = true; 
                 ieee80211_start_scan(ieee); 
         } 
@@ -2635,12 +2635,12 @@ void ieee80211_start_protocol(struct 

ieee80211_device *ieee)

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c static int ieee80211_wpa_set_auth_algs(struct

Quoted 16 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +3 -3
         ieee->proto_started = 1; 
 
-        if (ieee->current_network.channel == 0){ 
-                do{ 
+        if (ieee->current_network.channel == 0) { 
+                do { 
                         ch++; 
                         if (ch > MAX_CHANNEL_NUMBER) 
                                 return; /* no channel found */ 
-                }while (!GET_DOT11D_INFO(ieee)->channel_map[ch]); 
+                } while (!GET_DOT11D_INFO(ieee)->channel_map[ch]); 
                 ieee->current_network.channel = ch; 
         } 
 
@@ -2856,12 +2856,12 @@ static int ieee80211_wpa_set_auth_algs(struct 

ieee80211_device *ieee, int value)

Quoted 19 lines
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c +2 -2
                 sec.auth_mode = WLAN_AUTH_SHARED_KEY; 
                 ieee->open_wep = 0; 
                 ieee->auth_mode = 1; 
-        } else if (value & AUTH_ALG_OPEN_SYSTEM){ 
+        } else if (value & AUTH_ALG_OPEN_SYSTEM) { 
                 sec.auth_mode = WLAN_AUTH_OPEN; 
                 ieee->open_wep = 1; 
                 ieee->auth_mode = 0; 
         } 
-        else if (value & IW_AUTH_ALG_LEAP){ 
+        else if (value & IW_AUTH_ALG_LEAP) { 
                 sec.auth_mode = WLAN_AUTH_LEAP; 
                 ieee->open_wep = 1; 
                 ieee->auth_mode = 2; 
Signature · 4 lines
1.9.1 

-- 
You received this message because you are subscribed to the Google 

Groups "outreachy-kernel" group.

Quoted 1 line

To unsubscribe from this group and stop receiving emails from it, send

an email to [email protected] <javascript:>.

Quoted 1 line

To post to this group, send email to [email protected]

<javascript:>.

Quoted 1 line

To view this discussion on the web visit

https://groups.google.com/d/msgid/outreachy-kernel/1425316465-16949-1-git-send-email-haticeerturk27%40gmail.com.

Quoted 2 lines

For more options, visit https://groups.google.com/d/optout.

#4 lore raw
Quoted 3 lines · Hatice ERTÜRK

This is a another patch. I told you.  This patch contains also adding spaces before ' {' and the other ' (' adding spaces before. That's why another patch.

OK.

julia

Quoted 692 lines

2 Mart 2015 Pazartesi 21:36:36 UTC+2 tarihinde Julia Lawall yazdı:

      On Mon, 2 Mar 2015, Hatice ERTÜRK wrote:

      > Space required before the open brace '{' and after the close
      brace '}'
      > This Error found with checkpatch.pl

      I think that this is a v2, but you have not indicated that?

      julia

      > Signed-off-by: Hatice ERTURK <[email protected]>
      > ---
      >  .../staging/rtl8192u/ieee80211/ieee80211_softmac.c | 184
      ++++++++++-----------
      >  1 file changed, 92 insertions(+), 92 deletions(-)
      >
      > diff --git
      a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
      b/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
      > index 057d4d1..2c53763 100644
      > --- a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
      > +++ b/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
      > @@ -62,7 +62,7 @@ static void ieee80211_MFIE_Brate(struct
      ieee80211_device *ieee, u8 **tag_p)
      >  {
      >          u8 *tag = *tag_p;
      >
      > -        if (ieee->modulation & IEEE80211_CCK_MODULATION){
      > +        if (ieee->modulation & IEEE80211_CCK_MODULATION) {
      >                  *tag++ = MFIE_TYPE_RATES;
      >                  *tag++ = 4;
      >                  *tag++ = IEEE80211_BASIC_RATE_MASK |
      IEEE80211_CCK_RATE_1MB;
      > @@ -79,7 +79,7 @@ static void ieee80211_MFIE_Grate(struct
      ieee80211_device *ieee, u8 **tag_p)
      >  {
      >          u8 *tag = *tag_p;
      >
      > -                if (ieee->modulation &
      IEEE80211_OFDM_MODULATION){
      > +                if (ieee->modulation &
      IEEE80211_OFDM_MODULATION) {
      >
      >                  *tag++ = MFIE_TYPE_RATES_EX;
      >                  *tag++ = 8;
      > @@ -192,7 +192,7 @@ static u8 MgntQuery_MgntFrameTxRate(struct
      ieee80211_device *ieee)
      >          else
      >                  rate = ieee->basic_rate & 0x7f;
      >
      > -        if (rate == 0){
      > +        if (rate == 0) {
      >                  /* 2005.01.26, by rcnjko. */
      >                  if (ieee->mode == IEEE_A||
      >                     ieee->mode== IEEE_N_5G||
      > @@ -237,10 +237,10 @@ inline void softmac_mgmt_xmit(struct
      sk_buff *skb, struct ieee80211_device *ieee
      >          tcb_desc->bTxDisableRateFallBack = 1;
      >          tcb_desc->bTxUseDriverAssingedRate = 1;
      >
      > -        if (single){
      > -                if (ieee->queue_stop){
      > +        if (single) {
      > +                if (ieee->queue_stop) {
      >                          enqueue_mgmt(ieee, skb);
      > -                }else{
      > +                } else {
      >                          header->seq_ctl =
      cpu_to_le16(ieee->seq_ctrl[0]<<4);
      >
      >                          if (ieee->seq_ctrl[0] == 0xFFF)
      > @@ -255,7 +255,7 @@ inline void softmac_mgmt_xmit(struct
      sk_buff *skb, struct ieee80211_device *ieee
      >                  }
      >
      >                  spin_unlock_irqrestore(&ieee->lock, flags);
      > -        }else{
      > +        } else {
      >                  spin_unlock_irqrestore(&ieee->lock, flags);
      >                  spin_lock_irqsave(&ieee->mgmt_tx_lock,
      flags);
      >
      > @@ -293,7 +293,7 @@ inline void softmac_ps_mgmt_xmit(struct
      sk_buff *skb, struct ieee80211_device *i
      >                  (struct ieee80211_hdr_3addr  *) skb->data;
      >
      >
      > -        if (single){
      > +        if (single) {
      >
      >                  header->seq_ctl =
      cpu_to_le16(ieee->seq_ctrl[0] << 4);
      >
      > @@ -306,7 +306,7 @@ inline void softmac_ps_mgmt_xmit(struct
      sk_buff *skb, struct ieee80211_device *i
      >                  ieee->dev->trans_start = jiffies;
      >                 ieee->softmac_data_hard_start_xmit(skb,ieee->dev,ieee->bas
      ic_rate);
      >
      > -        }else{
      > +        } else {
      >
      >                  header->seq_ctl =
      cpu_to_le16(ieee->seq_ctrl[0] << 4);
      >
      > @@ -369,7 +369,7 @@ static void ieee80211_send_beacon(struct
      ieee80211_device *ieee)
      >          /* unsigned long flags; */
      >          skb = ieee80211_get_beacon_(ieee);
      >
      > -        if (skb){
      > +        if (skb) {
      >                  softmac_mgmt_xmit(skb, ieee);
      >                  ieee->softmac_stats.tx_beacons++;
      >                  /* dev_kfree_skb_any(skb); edit by thomas */
      > @@ -378,7 +378,7 @@ static void ieee80211_send_beacon(struct
      ieee80211_device *ieee)
      >                  (MSECS( ieee->current_network.beacon_interval
      -5));
      >
      >          spin_lock_irqsave(&ieee->beacon_lock,flags); */
      > -        if (ieee->beacon_txing && ieee->ieee_up){
      > +        if (ieee->beacon_txing && ieee->ieee_up) {
      >                  /* if(!timer_pending(&ieee->beacon_timer))
      >                          add_timer(&ieee->beacon_timer); */
      >                 mod_timer(&ieee->beacon_timer,jiffies+(MSECS(ieee->current
      _network.beacon_interval-5)));
      > @@ -404,7 +404,7 @@ static void ieee80211_send_probe(struct
      ieee80211_device *ieee)
      >          struct sk_buff *skb;
      >
      >          skb = ieee80211_probe_req(ieee);
      > -        if (skb){
      > +        if (skb) {
      >                  softmac_mgmt_xmit(skb, ieee);
      >                  ieee->softmac_stats.tx_probe_rq++;
      >                  /* dev_kfree_skb_any(skb); edit by thomas */
      > @@ -413,7 +413,7 @@ static void ieee80211_send_probe(struct
      ieee80211_device *ieee)
      >
      >  static void ieee80211_send_probe_requests(struct
      ieee80211_device *ieee)
      >  {
      > -        if (ieee->active_scan && (ieee->softmac_features &
      IEEE_SOFTMAC_PROBERQ)){
      > +        if (ieee->active_scan && (ieee->softmac_features &
      IEEE_SOFTMAC_PROBERQ)) {
      >                  ieee80211_send_probe(ieee);
      >                  ieee80211_send_probe(ieee);
      >          }
      > @@ -433,11 +433,11 @@ void
      ieee80211_softmac_scan_syncro(struct ieee80211_device *ieee)
      >          while (1)
      >          {
      >
      > -                do{
      > +                do {
      >                          ch++;
      >                          if (ch > MAX_CHANNEL_NUMBER)
      >                                  goto out; /* scan completed
      */
      > -                }while (!channel_map[ch]);
      > +                } while (!channel_map[ch]);
      >
      >                  /* this function can be called in two
      situations
      >                   * 1- We have switched to ad-hoc mode and we
      are
      > @@ -478,7 +478,7 @@ void ieee80211_softmac_scan_syncro(struct
      ieee80211_device *ieee)
      >
      >          }
      >  out:
      > -        if (ieee->state < IEEE80211_LINKED){
      > +        if (ieee->state < IEEE80211_LINKED) {
      >                  ieee->actscanning = false;
      >                  up(&ieee->scan_sem);
      >          }
      > @@ -501,7 +501,7 @@ static void
      ieee80211_softmac_scan_wq(struct work_struct *work)
      >          if (!ieee->ieee_up)
      >                  return;
      >          down(&ieee->scan_sem);
      > -        do{
      > +        do {
      >                  ieee->current_network.channel =
      >                          (ieee->current_network.channel + 1) %
      MAX_CHANNEL_NUMBER;
      >                  if (watchdog++ > MAX_CHANNEL_NUMBER)
      > @@ -512,7 +512,7 @@ static void
      ieee80211_softmac_scan_wq(struct work_struct *work)
      >                                  goto out; /* no good chans */
      >                          }
      >                  }
      > -        }while (!channel_map[ieee->current_network.channel]);
      > +        } while
      (!channel_map[ieee->current_network.channel]);
      >          if (ieee->scanning == 0 )
      >                  goto out;
      >          ieee->set_chan(ieee->dev,
      ieee->current_network.channel);
      > @@ -587,7 +587,7 @@ static void
      ieee80211_softmac_stop_scan(struct ieee80211_device *ieee)
      >          down(&ieee->scan_sem);
      >          /* spin_lock_irqsave(&ieee->lock, flags); */
      >
      > -        if (ieee->scanning == 1){
      > +        if (ieee->scanning == 1) {
      >                  ieee->scanning = 0;
      >
      >                  cancel_delayed_work(&ieee->softmac_scan_wq);
      > @@ -616,12 +616,12 @@ static void ieee80211_start_scan(struct
      ieee80211_device *ieee)
      >                          RESET_CIE_WATCHDOG(ieee);
      >                  }
      >          }
      > -        if (ieee->softmac_features & IEEE_SOFTMAC_SCAN){
      > -                if (ieee->scanning == 0){
      > +        if (ieee->softmac_features & IEEE_SOFTMAC_SCAN) {
      > +                if (ieee->scanning == 0) {
      >                          ieee->scanning = 1;
      >                          queue_delayed_work(ieee->wq,
      &ieee->softmac_scan_wq, 0);
      >                  }
      > -        }else
      > +        } else
      >                  ieee->start_scan(ieee->dev);
      >
      >  }
      > @@ -803,7 +803,7 @@ static struct sk_buff
      *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d
      >          *(tag++) = 1;
      >          *(tag++) = ieee->current_network.channel;
      >
      > -        if (atim_len){
      > +        if (atim_len) {
      >                  *(tag++) = MFIE_TYPE_IBSS_SET;
      >                  *(tag++) = 2;
      >
      > @@ -812,12 +812,12 @@ static struct sk_buff
      *ieee80211_probe_resp(struct ieee80211_device *ieee, u8 *d
      >                  tag+=2;
      >          }
      >
      > -        if (erp_len){
      > +        if (erp_len) {
      >                  *(tag++) = MFIE_TYPE_ERP;
      >                  *(tag++) = 1;
      >                  *(tag++) = erpinfo_content;
      >          }
      > -        if (rate_ex_len){
      > +        if (rate_ex_len) {
      >                  *(tag++) = MFIE_TYPE_RATES_EX;
      >                  *(tag++) = rate_ex_len-2;
      >                  memcpy(tag, ieee->current_network.rates_ex,
      rate_ex_len-2);
      > @@ -1169,7 +1169,7 @@ inline struct sk_buff
      *ieee80211_association_req(struct ieee80211_network *beaco
      >                  tag += osCcxVerNum.Length;
      >          }
      >          /* HT cap element */
      > -        if
      (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){
      > +        if
      (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) {
      >                  if (ieee->pHTInfo->ePeerHTSpecVer !=
      HT_SPEC_VER_EWC)
      >                  {
      >                          tag = skb_put(skb, ht_cap_len);
      > @@ -1183,7 +1183,7 @@ inline struct sk_buff
      *ieee80211_association_req(struct ieee80211_network *beaco
      >
      >          /* choose what wpa_supplicant gives to associate. */
      >          tag = skb_put(skb, wpa_ie_len);
      > -        if (wpa_ie_len){
      > +        if (wpa_ie_len) {
      >                  memcpy(tag, ieee->wpa_ie, ieee->wpa_ie_len);
      >          }
      >
      > @@ -1198,7 +1198,7 @@ inline struct sk_buff
      *ieee80211_association_req(struct ieee80211_network *beaco
      >          }
      >  #endif
      >
      > -        if
      (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT){
      > +        if
      (ieee->pHTInfo->bCurrentHTSupport&&ieee->pHTInfo->bEnableHT) {
      >                  if (ieee->pHTInfo->ePeerHTSpecVer ==
      HT_SPEC_VER_EWC)
      >                  {
      >                          tag = skb_put(skb, ht_cap_len);
      > @@ -1208,7 +1208,7 @@ inline struct sk_buff
      *ieee80211_association_req(struct ieee80211_network *beaco
      >                          tag += ht_cap_len -2;
      >                  }
      >
      > -                if (ieee->pHTInfo->bCurrentRT2RTAggregation){
      > +                if (ieee->pHTInfo->bCurrentRT2RTAggregation)
      {
      >                          tag = skb_put(skb, realtek_ie_len);
      >                          *tag++ = MFIE_TYPE_GENERIC;
      >                          *tag++ = realtek_ie_len - 2;
      > @@ -1234,10 +1234,10 @@ void ieee80211_associate_abort(struct
      ieee80211_device *ieee)
      >           * Here we will check if there are good nets to
      associate
      >           * with, so we retry or just get back to NO_LINK and
      scanning
      >           */
      > -        if (ieee->state ==
      IEEE80211_ASSOCIATING_AUTHENTICATING){
      > +        if (ieee->state ==
      IEEE80211_ASSOCIATING_AUTHENTICATING) {
      >                  IEEE80211_DEBUG_MGMT("Authentication
      failed\n");
      >                  ieee->softmac_stats.no_auth_rs++;
      > -        }else{
      > +        } else {
      >                  IEEE80211_DEBUG_MGMT("Association failed\n");
      >                  ieee->softmac_stats.no_ass_rs++;
      >          }
      > @@ -1274,7 +1274,7 @@ static void
      ieee80211_associate_step1(struct ieee80211_device *ieee)
      >                  /* printk(KERN_WARNING "Sending
      authentication request\n"); */
      >                  softmac_mgmt_xmit(skb, ieee);
      >                  /* BUGON when you try to add_timer twice,
      using mod_timer may be better, john0709 */
      > -                if (!timer_pending(&ieee->associate_timer)){
      > +                if (!timer_pending(&ieee->associate_timer)) {
      >                          ieee->associate_timer.expires =
      jiffies + (HZ / 2);
      >                          add_timer(&ieee->associate_timer);
      >                  }
      > @@ -1338,11 +1338,11 @@ static void
      ieee80211_associate_complete_wq(struct work_struct *work)
      >          struct ieee80211_device *ieee = container_of(work,
      struct ieee80211_device, associate_complete_wq);
      >          printk(KERN_INFO "Associated successfully\n");
      >          if (ieee80211_is_54g(&ieee->current_network) &&
      > -                (ieee->modulation &
      IEEE80211_OFDM_MODULATION)){
      > +                (ieee->modulation &
      IEEE80211_OFDM_MODULATION)) {
      >
      >                  ieee->rate = 108;
      >                  printk(KERN_INFO"Using G rates:%d\n",
      ieee->rate);
      > -        }else{
      > +        } else {
      >                  ieee->rate = 22;
      >                  printk(KERN_INFO"Using B rates:%d\n",
      ieee->rate);
      >          }
      > @@ -1365,7 +1365,7 @@ static void
      ieee80211_associate_complete_wq(struct work_struct *work)
      >                  ieee->LinkDetectInfo.NumRecvDataInPeriod= 1;
      >          }
      >          ieee->link_change(ieee->dev);
      > -        if (ieee->is_silent_reset == 0){
      > +        if (ieee->is_silent_reset == 0) {
      >                  printk("============>normal associate\n");
      >          notify_wx_assoc_event(ieee);
      >          }
      > @@ -1431,7 +1431,7 @@ inline void
      ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct
      ieee
      >                  return;
      >
      >
      > -        if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode
      == IW_MODE_ADHOC){
      > +        if (ieee->iw_mode == IW_MODE_INFRA || ieee->iw_mode
      == IW_MODE_ADHOC) {
      >                  /* if the user specified the AP MAC, we need
      also the essid
      >                   * This could be obtained by beacons or, if
      the network does not
      >                   * broadcast it, it can be put manually.
      > @@ -1459,13 +1459,13 @@ inline void
      ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct
      ieee
      >                                  /* if the essid is hidden
      replace it with the
      >                                  * essid provided by the user.
      >                                  */
      > -                                if (!ssidbroad){
      > +                                if (!ssidbroad) {
      >                                          strncpy(tmp_ssid,
      ieee->current_network.ssid, IW_ESSID_MAX_SIZE);
      >                                          tmp_ssid_len =
      ieee->current_network.ssid_len;
      >                                  }
      >
                                       memcpy(&ieee->current_network,
      net, sizeof(struct ieee80211_network));
      >
      > -                                if (!ssidbroad){
      > +                                if (!ssidbroad) {
      >                                         strncpy(ieee->current_network.ssid
      , tmp_ssid, IW_ESSID_MAX_SIZE);
      >
                                               ieee->current_network.ssid_len
      = tmp_ssid_len;
      >                                  }
      > @@ -1473,7 +1473,7 @@ inline void
      ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct
      ieee
      >
      >                                  /* ieee->pHTInfo->IOTAction =
      0; */
      >
                                       HTResetIOTSetting(ieee->pHTInfo);
      > -                                if (ieee->iw_mode ==
      IW_MODE_INFRA){
      > +                                if (ieee->iw_mode ==
      IW_MODE_INFRA) {
      >                                          /* Join the network
      for the first time */
      >                                          ieee->AsocRetryCount
      = 0;
      >                                          /* for HT by amy
      080514 */
      > @@ -1492,13 +1492,13 @@ inline void
      ieee80211_softmac_new_net(struct ieee80211_device *ieee, struct
      ieee
      >
      >                                          ieee->state =
      IEEE80211_ASSOCIATING;
      >                                          queue_work(ieee->wq,
      &ieee->associate_procedure_wq);
      > -                                }else{
      > +                                } else {
      >                                          if
      (ieee80211_is_54g(&ieee->current_network) &&
      >
      -                                                (ieee->modulation
      & IEEE80211_OFDM_MODULATION)){
      >
      +                                                (ieee->modulation
      & IEEE80211_OFDM_MODULATION)) {
      >                                                  ieee->rate =
      108;
      >                                                 ieee->SetWirelessMode(ieee
      ->dev, IEEE_G);
      >
                                                       printk(KERN_INFO"Using
      G rates\n");
      > -                                        }else{
      > +                                        } else {
      >                                                  ieee->rate =
      22;
      >                                                 ieee->SetWirelessMode(ieee
      ->dev, IEEE_B);
      >
                                                       printk(KERN_INFO"Using
      B rates\n");
      > @@ -1542,16 +1542,16 @@ static inline u16 auth_parse(struct
      sk_buff *skb, u8 **challenge, int *chlen)
      >  {
      >          struct ieee80211_authentication *a;
      >          u8 *t;
      > -        if (skb->len <  (sizeof(struct
      ieee80211_authentication)-sizeof(struct
      ieee80211_info_element))){
      > +        if (skb->len <  (sizeof(struct
      ieee80211_authentication)-sizeof(struct
      ieee80211_info_element))) {
      >                  IEEE80211_DEBUG_MGMT("invalid len in auth
      resp: %d\n",skb->len);
      >                  return 0xcafe;
      >          }
      >          *challenge = NULL;
      >          a = (struct ieee80211_authentication *) skb->data;
      > -        if (skb->len > (sizeof(struct
      ieee80211_authentication) +3)){
      > +        if (skb->len > (sizeof(struct
      ieee80211_authentication) +3)) {
      >                  t = skb->data + sizeof(struct
      ieee80211_authentication);
      >
      > -                if (*(t++) == MFIE_TYPE_CHALLENGE){
      > +                if (*(t++) == MFIE_TYPE_CHALLENGE) {
      >                          *chlen = *(t++);
      >                          *challenge = kmemdup(t, *chlen,
      GFP_ATOMIC);
      >                          if (!*challenge)
      > @@ -1568,7 +1568,7 @@ static int auth_rq_parse(struct sk_buff
      *skb, u8 *dest)
      >  {
      >          struct ieee80211_authentication *a;
      >
      > -        if (skb->len <  (sizeof(struct
      ieee80211_authentication)-sizeof(struct
      ieee80211_info_element))){
      > +        if (skb->len <  (sizeof(struct
      ieee80211_authentication)-sizeof(struct
      ieee80211_info_element))) {
      >                  IEEE80211_DEBUG_MGMT("invalid len in auth
      request: %d\n",skb->len);
      >                  return -1;
      >          }
      > @@ -1601,8 +1601,8 @@ static short probe_rq_parse(struct
      ieee80211_device *ieee, struct sk_buff *skb,
      >
      >          tag = skb->data + sizeof (struct ieee80211_hdr_3addr
       );
      >
      > -        while (tag+1 < skbend){
      > -                if (*tag == 0){
      > +        while (tag+1 < skbend) {
      > +                if (*tag == 0) {
      >                          ssid = tag+2;
      >                          ssidlen = *(tag+1);
      >                          break;
      > @@ -1643,7 +1643,7 @@ static inline u16 assoc_parse(struct
      ieee80211_device *ieee, struct sk_buff *skb
      >          struct ieee80211_assoc_response_frame *response_head;
      >          u16 status_code;
      >
      > -        if (skb->len <  sizeof(struct
      ieee80211_assoc_response_frame)){
      > +        if (skb->len <  sizeof(struct
      ieee80211_assoc_response_frame)) {
      >                  IEEE80211_DEBUG_MGMT("invalid len in auth
      resp: %d\n", skb->len);
      >                  return 0xcafe;
      >          }
      > @@ -1658,7 +1658,7 @@ static inline u16 assoc_parse(struct
      ieee80211_device *ieee, struct sk_buff *skb
      >              (ieee->current_network.mode == IEEE_N_24G) &&
      >              (ieee->AsocRetryCount++ <
      (RT_ASOC_RETRY_LIMIT-1)))) {
      >                   ieee->pHTInfo->IOTAction |=
      HT_IOT_ACT_PURE_N_MODE;
      > -        }else {
      > +        } else {
      >                   ieee->AsocRetryCount = 0;
      >          }
      >
      > @@ -1673,7 +1673,7 @@ ieee80211_rx_probe_rq(struct
      ieee80211_device *ieee, struct sk_buff *skb)
      >          /* IEEE80211DMESG("Rx probe"); */
      >          ieee->softmac_stats.rx_probe_rq++;
      >          /* DMESG("Dest is "MACSTR, MAC2STR(dest)); */
      > -        if (probe_rq_parse(ieee, skb, dest)){
      > +        if (probe_rq_parse(ieee, skb, dest)) {
      >                  /* IEEE80211DMESG("Was for me!"); */
      >                  ieee->softmac_stats.tx_probe_rs++;
      >                  ieee80211_resp_to_probe(ieee, dest);
      > @@ -1704,7 +1704,7 @@ ieee80211_rx_assoc_rq(struct
      ieee80211_device *ieee, struct sk_buff *skb)
      >          /* unsigned long flags; */
      >
      >          ieee->softmac_stats.rx_ass_rq++;
      > -        if (assoc_rq_parse(skb,dest) != -1){
      > +        if (assoc_rq_parse(skb,dest) != -1) {
      >                  ieee80211_resp_to_assoc_rq(ieee, dest);
      >          }
      >
      > @@ -1756,13 +1756,13 @@ static short
      ieee80211_sta_ps_sleep(struct ieee80211_device *ieee, u32
      *time_h,
      >                  (ieee->mgmt_queue_tail !=
      ieee->mgmt_queue_head))
      >                  return 0;
      >
      > -        if (time_l){
      > +        if (time_l) {
      >                  *time_l =
      ieee->current_network.last_dtim_sta_time[0]
      >                          +
      (ieee->current_network.beacon_interval
      >                          * ieee->current_network.dtim_period)
      * 1000;
      >          }
      >
      > -        if (time_h){
      > +        if (time_h) {
      >                  *time_h =
      ieee->current_network.last_dtim_sta_time[1];
      >                  if (time_l && *time_l <
      ieee->current_network.last_dtim_sta_time[0])
      >                          *time_h += 1;
      > @@ -1800,16 +1800,16 @@ static inline void
      ieee80211_sta_ps(struct ieee80211_device *ieee)
      >          if (sleep == 0)
      >                  goto out;
      >
      > -        if (sleep == 1){
      > +        if (sleep == 1) {
      >
      >                  if (ieee->sta_sleep == 1)
      >                          ieee->enter_sleep_state(ieee->dev,
      th, tl);
      >
      > -                else if (ieee->sta_sleep == 0){
      > +                else if (ieee->sta_sleep == 0) {
      >                          /* printk("send null 1\n"); */
      >
                               spin_lock_irqsave(&ieee->mgmt_tx_lock,
      flags2);
      >
      > -                        if
      (ieee->ps_is_queue_empty(ieee->dev)){
      > +                        if
      (ieee->ps_is_queue_empty(ieee->dev)) {
      >
      >
      >                                  ieee->sta_sleep = 2;
      > @@ -1826,7 +1826,7 @@ static inline void
      ieee80211_sta_ps(struct ieee80211_device *ieee)
      >                  }
      >
      >
      > -        }else if (sleep == 2){
      > +        } else if (sleep == 2) {
      >  /* #warning CHECK_LOCK_HERE */
      >                  spin_lock_irqsave(&ieee->mgmt_tx_lock,
      flags2);
      >
      > @@ -1842,8 +1842,8 @@ out:
      >
      >  void ieee80211_sta_wakeup(struct ieee80211_device *ieee,
      short nl)
      >  {
      > -        if (ieee->sta_sleep == 0){
      > -                if (nl){
      > +        if (ieee->sta_sleep == 0) {
      > +                if (nl) {
      >                          printk("Warning: driver is probably
      failing to report TX ps error\n");
      >                          ieee->ps_request_tx_ack(ieee->dev);
      >
                               ieee80211_sta_ps_send_null_frame(ieee,
      0);
      > @@ -1857,7 +1857,7 @@ void ieee80211_sta_wakeup(struct
      ieee80211_device *ieee, short nl)
      >
      >          ieee->sta_sleep = 0;
      >
      > -        if (nl){
      > +        if (nl) {
      >                  ieee->ps_request_tx_ack(ieee->dev);
      >                  ieee80211_sta_ps_send_null_frame(ieee, 0);
      >          }
      > @@ -1869,9 +1869,9 @@ void ieee80211_ps_tx_ack(struct
      ieee80211_device *ieee, short success)
      >
      >          spin_lock_irqsave(&ieee->lock, flags);
      >
      > -        if (ieee->sta_sleep == 2){
      > +        if (ieee->sta_sleep == 2) {
      >                  /* Null frame with PS bit set */
      > -                if (success){
      > +                if (success) {
      >                          ieee->sta_sleep = 1;
      >                         ieee->enter_sleep_state(ieee->dev,ieee->ps_th,ieee
      ->ps_tl);
      >                  }
      > @@ -2014,7 +2014,7 @@ ieee80211_rx_frame_softmac(struct
      ieee80211_device *ieee, struct sk_buff *skb,
      >
      >          case IEEE80211_STYPE_AUTH:
      >
      > -                if (ieee->softmac_features &
      IEEE_SOFTMAC_ASSOCIATE){
      > +                if (ieee->softmac_features &
      IEEE_SOFTMAC_ASSOCIATE) {
      >                          if (ieee->state ==
      IEEE80211_ASSOCIATING_AUTHENTICATING &&
      >                          ieee->iw_mode == IW_MODE_INFRA){
      >
      > @@ -2022,7 +2022,7 @@ ieee80211_rx_frame_softmac(struct
      ieee80211_device *ieee, struct sk_buff *skb,
      >
      >                                          errcode =
      auth_parse(skb, &challenge, &chlen);
      >                                          if (!errcode) {
      > -                                                if
      (ieee->open_wep || !challenge){
      > +                                                if
      (ieee->open_wep || !challenge) {
      >
                                                               ieee->state
      = IEEE80211_ASSOCIATING_AUTHENTICATED;
      >                                                         ieee->softmac_stat
      s.rx_auth_rs_ok++;
      >                                                          if
      (!(ieee->pHTInfo->IOTAction&HT_IOT_ACT_PURE_N_MODE))
Quoted 8 lines
      > @@ -2048,7 +2048,7 @@ ieee80211_rx_frame_softmac(struct
      ieee80211_device *ieee, struct sk_buff *skb,
      >
                                                                       /*
      N mode setting */
      >                                                                 ieee->SetW
      irelessMode(ieee->dev, \
      >                                                                          

?? ?      ieee->current_network.mode);

Quoted 285 lines
      >
      -                                                        }else{
      > +                                                        }
      else {
      >
                                                                       /*
      b/g mode setting */
      >
                                                                       /*TODO*/
      >                                                                 ieee->SetW
      irelessMode(ieee->dev, IEEE_G);
      > @@ -2063,16 +2063,16 @@ ieee80211_rx_frame_softmac(struct
      ieee80211_device *ieee, struct sk_buff *skb,
      >                                                                 ieee->bHal
      fWirelessN24GMode = false;
      >
      >                                                         ieee80211_associat
      e_step2(ieee);
      > -                                                }else{
      > +                                                } else {
      >                                                         ieee80211_auth_cha
      llenge(ieee, challenge, chlen);
      >                                                  }
      > -                                        }else{
      > +                                        } else {
      >                                                 ieee->softmac_stats.rx_aut
      h_rs_err++;
      >                                                 IEEE80211_DEBUG_MGMT("Auth
      entication response status code 0x%x",errcode);
      >                                                 ieee80211_associate_abort(
      ieee);
      >                                          }
      >
      > -                                }else if (ieee->iw_mode ==
      IW_MODE_MASTER){
      > +                                } else if (ieee->iw_mode ==
      IW_MODE_MASTER) {
      >
                                               ieee80211_rx_auth_rq(ieee,
      skb);
      >                                  }
      >                          }
      > @@ -2176,7 +2176,7 @@ void ieee80211_softmac_xmit(struct
      ieee80211_txb *txb, struct ieee80211_device *
      >  #else
      >
                               skb_queue_tail(&ieee->skb_waitQ[queue_index],
      txb->fragments[i]);
      >  #endif
      > -                }else{
      > +                } else {
      >                          ieee->softmac_data_hard_start_xmit(
      >                                          txb->fragments[i],
      >                                          ieee->dev,
      ieee->rate);
      > @@ -2200,10 +2200,10 @@ static void ieee80211_resume_tx(struct
      ieee80211_device *ieee)
      >          int i;
      >          for (i = ieee->tx_pending.frag; i <
      ieee->tx_pending.txb->nr_frags; i++) {
      >
      > -                if (ieee->queue_stop){
      > +                if (ieee->queue_stop) {
      >                          ieee->tx_pending.frag = i;
      >                          return;
      > -                }else{
      > +                } else {
      >
      >                          ieee->softmac_data_hard_start_xmit(
      >
                                       ieee->tx_pending.txb->fragments[i],
      > @@ -2226,7 +2226,7 @@ void ieee80211_reset_queue(struct
      ieee80211_device *ieee)
      >
      >          spin_lock_irqsave(&ieee->lock, flags);
      >          init_mgmt_queue(ieee);
      > -        if (ieee->tx_pending.txb){
      > +        if (ieee->tx_pending.txb) {
      >                  ieee80211_txb_free(ieee->tx_pending.txb);
      >                  ieee->tx_pending.txb = NULL;
      >          }
      > @@ -2248,8 +2248,8 @@ void ieee80211_wake_queue(struct
      ieee80211_device *ieee)
      >
      >          ieee->queue_stop = 0;
      >
      > -        if (ieee->softmac_features &
      IEEE_SOFTMAC_SINGLE_QUEUE){
      > -                while (!ieee->queue_stop && (skb =
      dequeue_mgmt(ieee))){
      > +        if (ieee->softmac_features &
      IEEE_SOFTMAC_SINGLE_QUEUE) {
      > +                while (!ieee->queue_stop && (skb =
      dequeue_mgmt(ieee))) {
      >
      >                          header = (struct ieee80211_hdr_3addr
       *) skb->data;
      >
      > @@ -2267,7 +2267,7 @@ void ieee80211_wake_queue(struct
      ieee80211_device *ieee)
      >          if (!ieee->queue_stop && ieee->tx_pending.txb)
      >                  ieee80211_resume_tx(ieee);
      >
      > -        if (!ieee->queue_stop &&
      netif_queue_stopped(ieee->dev)){
      > +        if (!ieee->queue_stop &&
      netif_queue_stopped(ieee->dev)) {
      >                  ieee->softmac_stats.swtxawake++;
      >                  netif_wake_queue(ieee->dev);
      >          }
      > @@ -2282,7 +2282,7 @@ void ieee80211_stop_queue(struct
      ieee80211_device *ieee)
      >          /* unsigned long flags;
      >          spin_lock_irqsave(&ieee->lock,flags); */
      >
      > -        if (! netif_queue_stopped(ieee->dev)){
      > +        if (! netif_queue_stopped(ieee->dev)) {
      >                  netif_stop_queue(ieee->dev);
      >                  ieee->softmac_stats.swtxstop++;
      >          }
      > @@ -2303,7 +2303,7 @@ void ieee80211_start_master_bss(struct
      ieee80211_device *ieee)
      >  {
      >          ieee->assoc_id = 1;
      >
      > -        if (ieee->current_network.ssid_len == 0){
      > +        if (ieee->current_network.ssid_len == 0) {
      >                  strncpy(ieee->current_network.ssid,
      >                          IEEE80211_DEFAULT_TX_ESSID,
      >                          IW_ESSID_MAX_SIZE);
      > @@ -2327,7 +2327,7 @@ void ieee80211_start_master_bss(struct
      ieee80211_device *ieee)
      >
      >  static void ieee80211_start_monitor_mode(struct
      ieee80211_device *ieee)
      >  {
      > -        if (ieee->raw_tx){
      > +        if (ieee->raw_tx) {
      >
      >                  if (ieee->data_hard_resume)
      >                          ieee->data_hard_resume(ieee->dev);
      > @@ -2347,13 +2347,13 @@ static void
      ieee80211_start_ibss_wq(struct work_struct *work)
      >           * (abort) this wq (when syncro scanning) before
      sleeping
      >           * on the semaphore
      >           */
      > -        if (!ieee->proto_started){
      > +        if (!ieee->proto_started) {
      >                  printk("==========oh driver down return\n");
      >                  return;
      >          }
      >          down(&ieee->wx_sem);
      >
      > -        if (ieee->current_network.ssid_len == 0){
      > +        if (ieee->current_network.ssid_len == 0) {
      >                  strcpy(ieee->current_network.ssid,
      IEEE80211_DEFAULT_TX_ESSID);
      >                  ieee->current_network.ssid_len =
      strlen(IEEE80211_DEFAULT_TX_ESSID);
      >                  ieee->ssid_set = 1;
      > @@ -2384,12 +2384,12 @@ static void
      ieee80211_start_ibss_wq(struct work_struct *work)
      >                  ieee80211_start_scan_syncro(ieee);
      >
      >          /* the network definitively is not here.. create a
      new cell */
      > -        if (ieee->state == IEEE80211_NOLINK){
      > +        if (ieee->state == IEEE80211_NOLINK) {
      >                  printk("creating new IBSS cell\n");
      >                  if (!ieee->wap_set)
      >                          ieee80211_randomize_cell(ieee);
      >
      > -                if (ieee->modulation &
      IEEE80211_CCK_MODULATION){
      > +                if (ieee->modulation &
      IEEE80211_CCK_MODULATION) {
      >
      >                          ieee->current_network.rates_len = 4;
      >
      > @@ -2398,10 +2398,10 @@ static void
      ieee80211_start_ibss_wq(struct work_struct *work)
      >                          ieee->current_network.rates[2] =
      IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_5MB;
      >                          ieee->current_network.rates[3] =
      IEEE80211_BASIC_RATE_MASK | IEEE80211_CCK_RATE_11MB;
      >
      > -                }else
      > +                } else
      >                          ieee->current_network.rates_len = 0;
      >
      > -                if (ieee->modulation &
      IEEE80211_OFDM_MODULATION){
      > +                if (ieee->modulation &
      IEEE80211_OFDM_MODULATION) {
      >                          ieee->current_network.rates_ex_len =
      8;
      >
      >                          ieee->current_network.rates_ex[0] =
      IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_6MB;
      > @@ -2414,7 +2414,7 @@ static void
      ieee80211_start_ibss_wq(struct work_struct *work)
      >                          ieee->current_network.rates_ex[7] =
      IEEE80211_BASIC_RATE_MASK | IEEE80211_OFDM_RATE_54MB;
      >
      >                          ieee->rate = 108;
      > -                }else{
      > +                } else {
      >                          ieee->current_network.rates_ex_len =
      0;
      >                          ieee->rate = 22;
      >                  }
      > @@ -2481,7 +2481,7 @@ void ieee80211_start_bss(struct
      ieee80211_device *ieee)
      >           */
      >          spin_lock_irqsave(&ieee->lock, flags);
      >
      > -        if (ieee->state == IEEE80211_NOLINK){
      > +        if (ieee->state == IEEE80211_NOLINK) {
      >                  ieee->actscanning = true;
      >                  ieee80211_start_scan(ieee);
      >          }
      > @@ -2635,12 +2635,12 @@ void ieee80211_start_protocol(struct
      ieee80211_device *ieee)
      >
      >          ieee->proto_started = 1;
      >
      > -        if (ieee->current_network.channel == 0){
      > -                do{
      > +        if (ieee->current_network.channel == 0) {
      > +                do {
      >                          ch++;
      >                          if (ch > MAX_CHANNEL_NUMBER)
      >                                  return; /* no channel found
      */
      > -                }while
      (!GET_DOT11D_INFO(ieee)->channel_map[ch]);
      > +                } while
      (!GET_DOT11D_INFO(ieee)->channel_map[ch]);
      >                  ieee->current_network.channel = ch;
      >          }
      >
      > @@ -2856,12 +2856,12 @@ static int
      ieee80211_wpa_set_auth_algs(struct ieee80211_device *ieee, int
      value)
      >                  sec.auth_mode = WLAN_AUTH_SHARED_KEY;
      >                  ieee->open_wep = 0;
      >                  ieee->auth_mode = 1;
      > -        } else if (value & AUTH_ALG_OPEN_SYSTEM){
      > +        } else if (value & AUTH_ALG_OPEN_SYSTEM) {
      >                  sec.auth_mode = WLAN_AUTH_OPEN;
      >                  ieee->open_wep = 1;
      >                  ieee->auth_mode = 0;
      >          }
      > -        else if (value & IW_AUTH_ALG_LEAP){
      > +        else if (value & IW_AUTH_ALG_LEAP) {
      >                  sec.auth_mode = WLAN_AUTH_LEAP;
      >                  ieee->open_wep = 1;
      >                  ieee->auth_mode = 2;
      > --
      > 1.9.1
      >
      > --
      > You received this message because you are subscribed to the
      Google Groups "outreachy-kernel" group.
      > To unsubscribe from this group and stop receiving emails from
      it, send an email to [email protected].
      > To post to this group, send email to
      [email protected].
      > To view this discussion on the web visithttps://groups.google.com/d/msgid/outreachy-kernel/1425316465-16949-1-git-s
      end-email-haticeerturk27%40gmail.com.
      > For more options, visit https://groups.google.com/d/optout.
      >

--
You received this message because you are subscribed to the Google Groups
"outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visithttps://groups.google.com/d/msgid/outreachy-kernel/3fd76d7d-be19-458d-a864- d6a5a78f3fc4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

maintainer
#5 lore raw
In reply to Hatice ERTÜRK
Quoted 7 lines · Hatice ERT�RK

Space required before the open brace '{' and after the close brace '}' This Error found with checkpatch.pl

---
 .../staging/rtl8192u/ieee80211/ieee80211_softmac.c | 184 ++++++++++-----------
 1 file changed, 92 insertions(+), 92 deletions(-)

This does not apply to my tree at all. Please refresh it against the latest staging-testing branch of staging.git and resend.

thanks,

greg k-h