Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1476005 > unrolled thread
| Started by | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| First post | 2016-09-04 21:30 +0200 |
| Last post | 2016-09-07 09:50 +0200 |
| Articles | 9 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c Matthias Beyer <mail@beyermatthias.de> - 2016-09-04 21:30 +0200
[PATCH 3/5] drivers: staging: rtl8723au: core: Refactor pointless branching Matthias Beyer <mail@beyermatthias.de> - 2016-09-04 21:30 +0200
[PATCH 4/5] drivers: staging: rtl8723au: core: Fix "space prohibited" warning Matthias Beyer <mail@beyermatthias.de> - 2016-09-04 21:30 +0200
[PATCH 2/5] drivers: staging: rtl8723au: core: simplify if-break-else Matthias Beyer <mail@beyermatthias.de> - 2016-09-04 21:30 +0200
[PATCH 5/5] drivers: staging: rtl8723au: core: Fix indentation Matthias Beyer <mail@beyermatthias.de> - 2016-09-04 21:40 +0200
Re: [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c Jes Sorensen <Jes.Sorensen@redhat.com> - 2016-09-06 18:10 +0200
Re: [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c Joe Perches <joe@perches.com> - 2016-09-06 18:10 +0200
Re: [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c Jes Sorensen <Jes.Sorensen@redhat.com> - 2016-09-06 18:20 +0200
Re: [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c Matthias Beyer <mail@beyermatthias.de> - 2016-09-07 09:50 +0200
| From | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| Date | 2016-09-04 21:30 +0200 |
| Subject | [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c |
| Message-ID | <sdLh8-1yo-11@gated-at.bofh.it> |
This patchset fixes some errors and warnings reported by checkpatch.pl. Matthias Beyer (5): drivers: staging: rtl8723au: core: Fix checkpatch.pl errors drivers: staging: rtl8723au: core: simplify if-break-else drivers: staging: rtl8723au: core: Refactor pointless branching drivers: staging: rtl8723au: core: Fix "space prohibited" warning drivers: staging: rtl8723au: core: Fix indentation drivers/staging/rtl8723au/core/rtw_mlme.c | 72 ++++++++++++++----------------- 1 file changed, 33 insertions(+), 39 deletions(-) -- 2.9.3
[toc] | [next] | [standalone]
| From | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| Date | 2016-09-04 21:30 +0200 |
| Subject | [PATCH 3/5] drivers: staging: rtl8723au: core: Refactor pointless branching |
| Message-ID | <sdLh8-1yo-9@gated-at.bofh.it> |
| In reply to | #1476005 |
As ether_addr_equal returns a bool, we can simply use the return value
to set the variable.
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Manuel Messner <manuel.johannes.messner@hs-furtwangen.de>
---
drivers/staging/rtl8723au/core/rtw_mlme.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/rtl8723au/core/rtw_mlme.c b/drivers/staging/rtl8723au/core/rtw_mlme.c
index da9f298..196447b 100644
--- a/drivers/staging/rtl8723au/core/rtw_mlme.c
+++ b/drivers/staging/rtl8723au/core/rtw_mlme.c
@@ -1062,11 +1062,8 @@ void rtw_joinbss_event_prehandle23a(struct rtw_adapter *adapter, u8 *pbuf)
pmlmepriv->assoc_ssid.ssid);
}
- if (ether_addr_equal(pnetwork->network.MacAddress,
- cur_network->network.MacAddress))
- the_same_macaddr = true;
- else
- the_same_macaddr = false;
+ the_same_macaddr = ether_addr_equal(pnetwork->network.MacAddress,
+ cur_network->network.MacAddress);
pnetwork->network.Length = get_wlan_bssid_ex_sz(&pnetwork->network);
if (pnetwork->network.Length > sizeof(struct wlan_bssid_ex)) {
--
2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| Date | 2016-09-04 21:30 +0200 |
| Subject | [PATCH 4/5] drivers: staging: rtl8723au: core: Fix "space prohibited" warning |
| Message-ID | <sdLh8-1yo-19@gated-at.bofh.it> |
| In reply to | #1476005 |
This patch fixes the "space prohibited between function name and open
parenthesis '('" warning from checkpatch.pl
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Manuel Messner <manuel.johannes.messner@hs-furtwangen.de>
---
drivers/staging/rtl8723au/core/rtw_mlme.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/rtl8723au/core/rtw_mlme.c b/drivers/staging/rtl8723au/core/rtw_mlme.c
index 196447b..1e01d62 100644
--- a/drivers/staging/rtl8723au/core/rtw_mlme.c
+++ b/drivers/staging/rtl8723au/core/rtw_mlme.c
@@ -900,15 +900,15 @@ rtw_joinbss_update_stainfo(struct rtw_adapter *padapter,
padapter->securitypriv.dot11PrivacyAlgrthm;
memset(&psta->dot118021x_UncstKey, 0,
- sizeof (union Keytype));
+ sizeof(union Keytype));
memset(&psta->dot11tkiprxmickey, 0,
- sizeof (union Keytype));
+ sizeof(union Keytype));
memset(&psta->dot11tkiptxmickey, 0,
- sizeof (union Keytype));
+ sizeof(union Keytype));
- memset(&psta->dot11txpn, 0, sizeof (union pn48));
- memset(&psta->dot11rxpn, 0, sizeof (union pn48));
+ memset(&psta->dot11txpn, 0, sizeof(union pn48));
+ memset(&psta->dot11rxpn, 0, sizeof(union pn48));
}
/* Commented by Albert 2012/07/21 */
--
2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| Date | 2016-09-04 21:30 +0200 |
| Subject | [PATCH 2/5] drivers: staging: rtl8723au: core: simplify if-break-else |
| Message-ID | <sdLh8-1yo-17@gated-at.bofh.it> |
| In reply to | #1476005 |
As the if statement breaks/continues the loop, the else block is not
useful and can be omitted.
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Manuel Messner <manuel.johannes.messner@hs-furtwangen.de>
---
drivers/staging/rtl8723au/core/rtw_mlme.c | 25 +++++++++++--------------
1 file changed, 11 insertions(+), 14 deletions(-)
diff --git a/drivers/staging/rtl8723au/core/rtw_mlme.c b/drivers/staging/rtl8723au/core/rtw_mlme.c
index 8b8b6a9..da9f298 100644
--- a/drivers/staging/rtl8723au/core/rtw_mlme.c
+++ b/drivers/staging/rtl8723au/core/rtw_mlme.c
@@ -244,21 +244,18 @@ static void _rtw_roaming(struct rtw_adapter *padapter,
do_join_r = rtw_do_join(padapter);
if (do_join_r == _SUCCESS)
break;
- else {
- DBG_8723A("roaming do_join return %d\n",
- do_join_r);
- pmlmepriv->to_roaming--;
- if (padapter->mlmepriv.to_roaming > 0)
- continue;
- else {
- DBG_8723A("%s(%d) -to roaming fail, "
- "indicate_disconnect\n",
- __func__, __LINE__);
- rtw_indicate_disconnect23a(padapter);
- break;
- }
- }
+ DBG_8723A("roaming do_join return %d\n", do_join_r);
+ pmlmepriv->to_roaming--;
+
+ if (padapter->mlmepriv.to_roaming > 0)
+ continue;
+
+ DBG_8723A("%s(%d) -to roaming fail, "
+ "indicate_disconnect\n",
+ __func__, __LINE__);
+ rtw_indicate_disconnect23a(padapter);
+ break;
}
}
}
--
2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| Date | 2016-09-04 21:40 +0200 |
| Subject | [PATCH 5/5] drivers: staging: rtl8723au: core: Fix indentation |
| Message-ID | <sdLqO-1CI-21@gated-at.bofh.it> |
| In reply to | #1476005 |
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Manuel Messner <manuel.johannes.messner@hs-furtwangen.de>
---
drivers/staging/rtl8723au/core/rtw_mlme.c | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/staging/rtl8723au/core/rtw_mlme.c b/drivers/staging/rtl8723au/core/rtw_mlme.c
index 1e01d62..1c31774 100644
--- a/drivers/staging/rtl8723au/core/rtw_mlme.c
+++ b/drivers/staging/rtl8723au/core/rtw_mlme.c
@@ -1921,17 +1921,17 @@ static int rtw_append_pmkid(struct rtw_adapter *Adapter, int iEntry,
struct security_priv *psecuritypriv = &Adapter->securitypriv;
if (ie[1] <= 20) {
- /* The RSN IE didn't include the PMK ID,
- append the PMK information */
- ie[ie_len] = 1;
- ie_len++;
- ie[ie_len] = 0; /* PMKID count = 0x0100 */
- ie_len++;
- memcpy(&ie[ie_len],
- &psecuritypriv->PMKIDList[iEntry].PMKID, 16);
-
- ie_len += 16;
- ie[1] += 18;/* PMKID length = 2+16 */
+ /* The RSN IE didn't include the PMK ID,
+ append the PMK information */
+ ie[ie_len] = 1;
+ ie_len++;
+ ie[ie_len] = 0; /* PMKID count = 0x0100 */
+ ie_len++;
+ memcpy(&ie[ie_len],
+ &psecuritypriv->PMKIDList[iEntry].PMKID, 16);
+
+ ie_len += 16;
+ ie[1] += 18;/* PMKID length = 2+16 */
}
return ie_len;
}
--
2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Jes Sorensen <Jes.Sorensen@redhat.com> |
|---|---|
| Date | 2016-09-06 18:10 +0200 |
| Message-ID | <ser6G-4cc-19@gated-at.bofh.it> |
| In reply to | #1476005 |
Matthias Beyer <mail@beyermatthias.de> writes: > This patchset fixes some errors and warnings reported by checkpatch.pl. > > Matthias Beyer (5): > drivers: staging: rtl8723au: core: Fix checkpatch.pl errors > drivers: staging: rtl8723au: core: simplify if-break-else > drivers: staging: rtl8723au: core: Refactor pointless branching > drivers: staging: rtl8723au: core: Fix "space prohibited" warning > drivers: staging: rtl8723au: core: Fix indentation > > drivers/staging/rtl8723au/core/rtw_mlme.c | 72 ++++++++++++++----------------- > 1 file changed, 33 insertions(+), 39 deletions(-) Nothing wrong with these patches, however I intend to post a patch to remove this driver soon, so it's kind of a waste of your time to spend too many cycles on it. Best regards, Jes
[toc] | [prev] | [next] | [standalone]
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2016-09-06 18:10 +0200 |
| Subject | Re: [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c |
| Message-ID | <ser6G-4cc-29@gated-at.bofh.it> |
| In reply to | #1477571 |
On Tue, 2016-09-06 at 12:00 -0400, Jes Sorensen wrote: > Nothing wrong with these patches, however I intend to post a patch to > remove this driver soon, so it's kind of a waste of your time to spend > too many cycles on it. It might be useful to mark any drivers you're planning on removing as "Obsolete" in MAINTAINERS. checkpatch will then emit a "don't waste your time" message if anyone scans an obsolete driver/file.
[toc] | [prev] | [next] | [standalone]
| From | Jes Sorensen <Jes.Sorensen@redhat.com> |
|---|---|
| Date | 2016-09-06 18:20 +0200 |
| Message-ID | <sergl-4jl-17@gated-at.bofh.it> |
| In reply to | #1477572 |
Joe Perches <joe@perches.com> writes: > On Tue, 2016-09-06 at 12:00 -0400, Jes Sorensen wrote: > >> Nothing wrong with these patches, however I intend to post a patch to >> remove this driver soon, so it's kind of a waste of your time to spend >> too many cycles on it. > > It might be useful to mark any drivers you're > planning on removing as "Obsolete" in MAINTAINERS. > > checkpatch will then emit a "don't waste your time" > message if anyone scans an obsolete driver/file. I see, wasn't aware of that. I did add a printk to it for 4.6 notifying users that the driver was going to go away. Jes
[toc] | [prev] | [next] | [standalone]
| From | Matthias Beyer <mail@beyermatthias.de> |
|---|---|
| Date | 2016-09-07 09:50 +0200 |
| Subject | Re: [PATCH 0/5] Some cleanup patches for drivers/staging/rtl8723au/core/rtw_mlme.c |
| Message-ID | <seFMm-5cY-39@gated-at.bofh.it> |
| In reply to | #1477571 |
[Multipart message — attachments visible in raw view] — view raw
On 06-09-2016 12:00:37, Jes Sorensen wrote: > Matthias Beyer <mail@beyermatthias.de> writes: > > This patchset fixes some errors and warnings reported by checkpatch.pl. > > > > Matthias Beyer (5): > > drivers: staging: rtl8723au: core: Fix checkpatch.pl errors > > drivers: staging: rtl8723au: core: simplify if-break-else > > drivers: staging: rtl8723au: core: Refactor pointless branching > > drivers: staging: rtl8723au: core: Fix "space prohibited" warning > > drivers: staging: rtl8723au: core: Fix indentation > > > > drivers/staging/rtl8723au/core/rtw_mlme.c | 72 ++++++++++++++----------------- > > 1 file changed, 33 insertions(+), 39 deletions(-) > > Nothing wrong with these patches, however I intend to post a patch to > remove this driver soon, so it's kind of a waste of your time to spend > too many cycles on it. > Alright, thanks for telling me, I won't waste any more time on it. Besides that - thanks for telling me that the patchset is okay as-is. That keeps me motivated! -- Mit freundlichen Grüßen, Kind regards, Matthias Beyer Proudly sent with mutt. Happily signed with gnupg.
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web