Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1371758 > unrolled thread
| Started by | Nicholas Sim <nicholassimws@gmail.com> |
|---|---|
| First post | 2016-04-05 18:10 +0200 |
| Last post | 2016-04-07 20:10 +0200 |
| Articles | 5 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH] staging: rtl8192u: remove blank lines after braces (opening) Nicholas Sim <nicholassimws@gmail.com> - 2016-04-05 18:10 +0200
Re: [PATCH] staging: rtl8192u: remove blank lines after braces (opening) Andy Shevchenko <andy.shevchenko@gmail.com> - 2016-04-07 20:10 +0200
Re: [PATCH] staging: rtl8192u: remove blank lines after braces (opening) Andy Shevchenko <andy.shevchenko@gmail.com> - 2016-04-07 20:10 +0200
Re: [PATCH] staging: rtl8192u: remove blank lines after braces (opening) Joe Perches <joe@perches.com> - 2016-04-07 20:20 +0200
Re: [PATCH] staging: rtl8192u: remove blank lines after braces (opening) Joe Perches <joe@perches.com> - 2016-04-07 20:10 +0200
| From | Nicholas Sim <nicholassimws@gmail.com> |
|---|---|
| Date | 2016-04-05 18:10 +0200 |
| Subject | [PATCH] staging: rtl8192u: remove blank lines after braces (opening) |
| Message-ID | <rkBIf-6yB-17@gated-at.bofh.it> |
Remove unneeded blank lines appearing after opening braces as suggested
by checkpatch.pl
Signed-off-by: Nicholas Sim <nicholassimws@gmail.com>
---
drivers/staging/rtl8192u/r8192U_core.c | 14 --------------
1 file changed, 14 deletions(-)
diff --git a/drivers/staging/rtl8192u/r8192U_core.c b/drivers/staging/rtl8192u/r8192U_core.c
index 2f506b8..21d5693 100644
--- a/drivers/staging/rtl8192u/r8192U_core.c
+++ b/drivers/staging/rtl8192u/r8192U_core.c
@@ -323,7 +323,6 @@ void write_nic_byte(struct net_device *dev, int indx, u8 data)
void write_nic_word(struct net_device *dev, int indx, u16 data)
{
-
int status;
struct r8192_priv *priv = (struct r8192_priv *)ieee80211_priv(dev);
@@ -347,7 +346,6 @@ void write_nic_word(struct net_device *dev, int indx, u16 data)
void write_nic_dword(struct net_device *dev, int indx, u32 data)
{
-
int status;
struct r8192_priv *priv = (struct r8192_priv *)ieee80211_priv(dev);
@@ -733,7 +731,6 @@ void rtl8192_update_msr(struct net_device *dev)
* master (see the create BSS/IBSS func)
*/
if (priv->ieee80211->state == IEEE80211_LINKED) {
-
if (priv->ieee80211->iw_mode == IW_MODE_INFRA)
msr |= (MSR_LINK_MANAGED << MSR_LINK_SHIFT);
else if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
@@ -768,7 +765,6 @@ static void rtl8192_rx_isr(struct urb *urb);
static u32 get_rxpacket_shiftbytes_819xusb(struct ieee80211_rx_stats *pstats)
{
-
return (sizeof(rx_desc_819x_usb) + pstats->RxDrvInfoSize
+ pstats->RxBufShift);
}
@@ -1267,7 +1263,6 @@ static void rtl8192_update_cap(struct net_device *dev, u16 cap)
}
static void rtl8192_net_update(struct net_device *dev)
{
-
struct r8192_priv *priv = ieee80211_priv(dev);
struct ieee80211_network *net;
u16 BcnTimeCfg = 0, BcnCW = 6, BcnIFS = 0xf;
@@ -1725,7 +1720,6 @@ static short rtl8192_usb_initendpoints(struct net_device *dev)
#ifndef JACKSON_NEW_RX
for (i = 0; i < (MAX_RX_URB + 1); i++) {
-
priv->rx_urb[i] = usb_alloc_urb(0, GFP_KERNEL);
priv->rx_urb[i]->transfer_buffer =
@@ -2658,7 +2652,6 @@ static short rtl8192_get_channel_map(struct net_device *dev)
static short rtl8192_init(struct net_device *dev)
{
-
struct r8192_priv *priv = ieee80211_priv(dev);
memset(&(priv->stats), 0, sizeof(struct Stats));
@@ -3007,7 +3000,6 @@ static bool rtl8192_adapter_start(struct net_device *dev)
bMaskByte2);
for (i = 0; i < CCKTxBBGainTableLength; i++) {
-
if (TempCCk == priv->cck_txbbgain_table[i].ccktxbb_valuearray[0]) {
priv->cck_present_attentuation_20Mdefault = (u8)i;
break;
@@ -3228,7 +3220,6 @@ static void CamRestoreAllEntry(struct net_device *dev)
if ((priv->ieee80211->pairwise_key_type == KEY_TYPE_WEP40) ||
(priv->ieee80211->pairwise_key_type == KEY_TYPE_WEP104)) {
-
for (EntryId = 0; EntryId < 4; EntryId++) {
MacAddr = CAM_CONST_ADDR[EntryId];
setKey(dev, EntryId, EntryId,
@@ -3237,7 +3228,6 @@ static void CamRestoreAllEntry(struct net_device *dev)
}
} else if (priv->ieee80211->pairwise_key_type == KEY_TYPE_TKIP) {
-
if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
setKey(dev, 4, 0, priv->ieee80211->pairwise_key_type,
(u8 *)dev->dev_addr, 0, NULL);
@@ -3245,7 +3235,6 @@ static void CamRestoreAllEntry(struct net_device *dev)
setKey(dev, 4, 0, priv->ieee80211->pairwise_key_type,
MacAddr, 0, NULL);
} else if (priv->ieee80211->pairwise_key_type == KEY_TYPE_CCMP) {
-
if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
setKey(dev, 4, 0, priv->ieee80211->pairwise_key_type,
(u8 *)dev->dev_addr, 0, NULL);
@@ -3446,7 +3435,6 @@ static void rtl819x_watchdog_wqcallback(struct work_struct *work)
/* for AP roaming */
if (priv->ieee80211->state == IEEE80211_LINKED &&
priv->ieee80211->iw_mode == IW_MODE_INFRA) {
-
rtl819x_update_rxcounts(priv, &TotalRxBcnNum, &TotalRxDataNum);
if ((TotalRxBcnNum + TotalRxDataNum) == 0) {
#ifdef TODO
@@ -4865,7 +4853,6 @@ static void rtl8192_rx_cmd(struct sk_buff *skb)
};
if ((skb->len >= (20 + sizeof(rx_desc_819x_usb))) && (skb->len < RX_URB_SIZE)) {
-
query_rx_cmdpkt_desc_status(skb, &stats);
/* prfd->queue_id = 1; */
@@ -5000,7 +4987,6 @@ fail:
*/
static void rtl8192_cancel_deferred_work(struct r8192_priv *priv)
{
-
cancel_work_sync(&priv->reset_wq);
cancel_delayed_work(&priv->watch_dog_wq);
cancel_delayed_work(&priv->update_beacon_wq);
--
2.4.3
[toc] | [next] | [standalone]
| From | Andy Shevchenko <andy.shevchenko@gmail.com> |
|---|---|
| Date | 2016-04-07 20:10 +0200 |
| Message-ID | <rlmxr-7V5-5@gated-at.bofh.it> |
| In reply to | #1371758 |
On Tue, Apr 5, 2016 at 7:07 PM, Nicholas Sim <nicholassimws@gmail.com> wrote:
> Remove unneeded blank lines appearing after opening braces as suggested
> by checkpatch.pl
>
You have to combine this with the rest so called 'indentation' fixes,
e.g. +- empty lines, tabs vs. spaces, etc.
P.S. By the way. are they first patches you are trying to push to kernel?
> Signed-off-by: Nicholas Sim <nicholassimws@gmail.com>
> ---
> drivers/staging/rtl8192u/r8192U_core.c | 14 --------------
> 1 file changed, 14 deletions(-)
>
> diff --git a/drivers/staging/rtl8192u/r8192U_core.c b/drivers/staging/rtl8192u/r8192U_core.c
> index 2f506b8..21d5693 100644
> --- a/drivers/staging/rtl8192u/r8192U_core.c
> +++ b/drivers/staging/rtl8192u/r8192U_core.c
> @@ -323,7 +323,6 @@ void write_nic_byte(struct net_device *dev, int indx, u8 data)
>
> void write_nic_word(struct net_device *dev, int indx, u16 data)
> {
> -
> int status;
>
> struct r8192_priv *priv = (struct r8192_priv *)ieee80211_priv(dev);
> @@ -347,7 +346,6 @@ void write_nic_word(struct net_device *dev, int indx, u16 data)
>
> void write_nic_dword(struct net_device *dev, int indx, u32 data)
> {
> -
> int status;
>
> struct r8192_priv *priv = (struct r8192_priv *)ieee80211_priv(dev);
> @@ -733,7 +731,6 @@ void rtl8192_update_msr(struct net_device *dev)
> * master (see the create BSS/IBSS func)
> */
> if (priv->ieee80211->state == IEEE80211_LINKED) {
> -
> if (priv->ieee80211->iw_mode == IW_MODE_INFRA)
> msr |= (MSR_LINK_MANAGED << MSR_LINK_SHIFT);
> else if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
> @@ -768,7 +765,6 @@ static void rtl8192_rx_isr(struct urb *urb);
>
> static u32 get_rxpacket_shiftbytes_819xusb(struct ieee80211_rx_stats *pstats)
> {
> -
> return (sizeof(rx_desc_819x_usb) + pstats->RxDrvInfoSize
> + pstats->RxBufShift);
> }
> @@ -1267,7 +1263,6 @@ static void rtl8192_update_cap(struct net_device *dev, u16 cap)
> }
> static void rtl8192_net_update(struct net_device *dev)
> {
> -
> struct r8192_priv *priv = ieee80211_priv(dev);
> struct ieee80211_network *net;
> u16 BcnTimeCfg = 0, BcnCW = 6, BcnIFS = 0xf;
> @@ -1725,7 +1720,6 @@ static short rtl8192_usb_initendpoints(struct net_device *dev)
>
> #ifndef JACKSON_NEW_RX
> for (i = 0; i < (MAX_RX_URB + 1); i++) {
> -
> priv->rx_urb[i] = usb_alloc_urb(0, GFP_KERNEL);
>
> priv->rx_urb[i]->transfer_buffer =
> @@ -2658,7 +2652,6 @@ static short rtl8192_get_channel_map(struct net_device *dev)
>
> static short rtl8192_init(struct net_device *dev)
> {
> -
> struct r8192_priv *priv = ieee80211_priv(dev);
>
> memset(&(priv->stats), 0, sizeof(struct Stats));
> @@ -3007,7 +3000,6 @@ static bool rtl8192_adapter_start(struct net_device *dev)
> bMaskByte2);
>
> for (i = 0; i < CCKTxBBGainTableLength; i++) {
> -
> if (TempCCk == priv->cck_txbbgain_table[i].ccktxbb_valuearray[0]) {
> priv->cck_present_attentuation_20Mdefault = (u8)i;
> break;
> @@ -3228,7 +3220,6 @@ static void CamRestoreAllEntry(struct net_device *dev)
>
> if ((priv->ieee80211->pairwise_key_type == KEY_TYPE_WEP40) ||
> (priv->ieee80211->pairwise_key_type == KEY_TYPE_WEP104)) {
> -
> for (EntryId = 0; EntryId < 4; EntryId++) {
> MacAddr = CAM_CONST_ADDR[EntryId];
> setKey(dev, EntryId, EntryId,
> @@ -3237,7 +3228,6 @@ static void CamRestoreAllEntry(struct net_device *dev)
> }
>
> } else if (priv->ieee80211->pairwise_key_type == KEY_TYPE_TKIP) {
> -
> if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
> setKey(dev, 4, 0, priv->ieee80211->pairwise_key_type,
> (u8 *)dev->dev_addr, 0, NULL);
> @@ -3245,7 +3235,6 @@ static void CamRestoreAllEntry(struct net_device *dev)
> setKey(dev, 4, 0, priv->ieee80211->pairwise_key_type,
> MacAddr, 0, NULL);
> } else if (priv->ieee80211->pairwise_key_type == KEY_TYPE_CCMP) {
> -
> if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
> setKey(dev, 4, 0, priv->ieee80211->pairwise_key_type,
> (u8 *)dev->dev_addr, 0, NULL);
> @@ -3446,7 +3435,6 @@ static void rtl819x_watchdog_wqcallback(struct work_struct *work)
> /* for AP roaming */
> if (priv->ieee80211->state == IEEE80211_LINKED &&
> priv->ieee80211->iw_mode == IW_MODE_INFRA) {
> -
> rtl819x_update_rxcounts(priv, &TotalRxBcnNum, &TotalRxDataNum);
> if ((TotalRxBcnNum + TotalRxDataNum) == 0) {
> #ifdef TODO
> @@ -4865,7 +4853,6 @@ static void rtl8192_rx_cmd(struct sk_buff *skb)
> };
>
> if ((skb->len >= (20 + sizeof(rx_desc_819x_usb))) && (skb->len < RX_URB_SIZE)) {
> -
> query_rx_cmdpkt_desc_status(skb, &stats);
> /* prfd->queue_id = 1; */
>
> @@ -5000,7 +4987,6 @@ fail:
> */
> static void rtl8192_cancel_deferred_work(struct r8192_priv *priv)
> {
> -
> cancel_work_sync(&priv->reset_wq);
> cancel_delayed_work(&priv->watch_dog_wq);
> cancel_delayed_work(&priv->update_beacon_wq);
> --
> 2.4.3
>
--
With Best Regards,
Andy Shevchenko
[toc] | [prev] | [next] | [standalone]
| From | Andy Shevchenko <andy.shevchenko@gmail.com> |
|---|---|
| Date | 2016-04-07 20:10 +0200 |
| Message-ID | <rlmxr-7V5-7@gated-at.bofh.it> |
| In reply to | #1373621 |
On Thu, Apr 7, 2016 at 9:04 PM, Joe Perches <joe@perches.com> wrote: > On Thu, 2016-04-07 at 20:59 +0300, Andy Shevchenko wrote: >> On Tue, Apr 5, 2016 at 7:07 PM, Nicholas Sim <nicholassimws@gmail.com> wrote: >> > >> > Remove unneeded blank lines appearing after opening braces as suggested >> > by checkpatch.pl >> > >> You have to combine this with the rest so called 'indentation' fixes, >> e.g. +- empty lines, tabs vs. spaces, etc. > > Actually, patches that do single things like removing > undesired blank lines are easier to review if separate > from patches that change horizontal whitespace. > Okay, but I think you at least agree that +- empty lines can be easily combined. -- With Best Regards, Andy Shevchenko
[toc] | [prev] | [next] | [standalone]
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2016-04-07 20:20 +0200 |
| Subject | Re: [PATCH] staging: rtl8192u: remove blank lines after braces (opening) |
| Message-ID | <rlmH8-7YH-5@gated-at.bofh.it> |
| In reply to | #1373622 |
On Thu, 2016-04-07 at 21:06 +0300, Andy Shevchenko wrote: > On Thu, Apr 7, 2016 at 9:04 PM, Joe Perches <joe@perches.com> wrote: > > On Thu, 2016-04-07 at 20:59 +0300, Andy Shevchenko wrote: > > > On Tue, Apr 5, 2016 at 7:07 PM, Nicholas Sim wrote: > > > > > > > > Remove unneeded blank lines appearing after opening braces as suggested > > > > by checkpatch.pl > > > > > > > You have to combine this with the rest so called 'indentation' fixes, > > > e.g. +- empty lines, tabs vs. spaces, etc. > > Actually, patches that do single things like removing > > undesired blank lines are easier to review if separate > > from patches that change horizontal whitespace. > > > Okay, but I think you at least agree that +- empty lines can be easily combined. Not really, but it's not important enough to me to care much either way.
[toc] | [prev] | [next] | [standalone]
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2016-04-07 20:10 +0200 |
| Subject | Re: [PATCH] staging: rtl8192u: remove blank lines after braces (opening) |
| Message-ID | <rlmxr-7V5-9@gated-at.bofh.it> |
| In reply to | #1373621 |
On Thu, 2016-04-07 at 20:59 +0300, Andy Shevchenko wrote: > On Tue, Apr 5, 2016 at 7:07 PM, Nicholas Sim <nicholassimws@gmail.com> wrote: > > > > Remove unneeded blank lines appearing after opening braces as suggested > > by checkpatch.pl > > > You have to combine this with the rest so called 'indentation' fixes, > e.g. +- empty lines, tabs vs. spaces, etc. Actually, patches that do single things like removing undesired blank lines are easier to review if separate from patches that change horizontal whitespace.
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web