mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andreas Ruprecht <andreas.ruprecht@fau.de>
To: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Jes Sorensen <Jes.Sorensen@redhat.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org,
	Andreas Ruprecht <andreas.ruprecht@fau.de>
Subject: [PATCH] staging: rtl8723au: core: Remove unneeded #ifdefs
Date: Mon, 15 Jun 2015 15:03:00 +0200	[thread overview]
Message-ID: <1434373380-8200-1-git-send-email-andreas.ruprecht@fau.de> (raw)

In rtw_mlme_ext.c, nested #ifdef blocks form the following
structure inside the file:

 #ifdef CONFIG_8723AU_AP_MODE           (line 1323)
 [...]
 #ifdef CONFIG_8723AU_AP_MODE           (line 1720)
 [...]
 #endif
 (2 more ifdef blocks with CONFIG_8723AU_AP_MODE follow)
 [...]
 #endif /* CONFIG_8723AU_AP_MODE */     (line 1763)

The inner #ifdefs are unnecessary as they depend on the
same condition as the outer #ifdef and can thus be removed.

Signed-off-by: Andreas Ruprecht <andreas.ruprecht@fau.de>
---
 drivers/staging/rtl8723au/core/rtw_mlme_ext.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/staging/rtl8723au/core/rtw_mlme_ext.c b/drivers/staging/rtl8723au/core/rtw_mlme_ext.c
index 0d7e921..be9a3d5 100644
--- a/drivers/staging/rtl8723au/core/rtw_mlme_ext.c
+++ b/drivers/staging/rtl8723au/core/rtw_mlme_ext.c
@@ -1717,7 +1717,6 @@ OnAssocReq23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame)
 	/*  now the station is qualified to join our BSS... */
 	if (pstat && pstat->state & WIFI_FW_ASSOC_SUCCESS &&
 	    status == WLAN_STATUS_SUCCESS) {
-#ifdef CONFIG_8723AU_AP_MODE
 		/* 1 bss_cap_update & sta_info_update23a */
 		bss_cap_update_on_sta_join23a(padapter, pstat);
 		sta_info_update23a(padapter, pstat);
@@ -1736,21 +1735,17 @@ OnAssocReq23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame)
 
 		/* 3-(1) report sta add event */
 		report_add_sta_event23a(padapter, pstat->hwaddr, pstat->aid);
-#endif
 	}
 
 	return _SUCCESS;
 
 asoc_class2_error:
 
-#ifdef CONFIG_8723AU_AP_MODE
 	issue_deauth23a(padapter, mgmt->sa, status);
-#endif
 	return _FAIL;
 
 OnAssocReq23aFail:
 
-#ifdef CONFIG_8723AU_AP_MODE
 	pstat->aid = 0;
 	if (ieee80211_is_assoc_req(mgmt->frame_control))
 		issue_assocrsp(padapter, status, pstat,
@@ -1758,7 +1753,6 @@ OnAssocReq23aFail:
 	else
 		issue_assocrsp(padapter, status, pstat,
 			       IEEE80211_STYPE_REASSOC_RESP);
-#endif
 
 #endif /* CONFIG_8723AU_AP_MODE */
 
-- 
1.9.1


                 reply	other threads:[~2015-06-15 13:10 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

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

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

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

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

  git send-email \
    --in-reply-to=1434373380-8200-1-git-send-email-andreas.ruprecht@fau.de \
    --to=andreas.ruprecht@fau.de \
    --cc=Jes.Sorensen@redhat.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

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

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®