public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Martin Karamihov <martinowar@gmail.com>, gregkh@linuxfoundation.org
Cc: Larry.Finger@lwfinger.net, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] staging: rtl8188eu: remove not necessary braces {} (checkpatch fix)
Date: Wed, 01 Feb 2017 10:11:52 -0800	[thread overview]
Message-ID: <1485972712.2560.11.camel@perches.com> (raw)
In-Reply-To: <ee803da0-574b-4156-c820-1b59a8364807@gmail.com>

On Wed, 2017-02-01 at 18:36 +0200, Martin Karamihov wrote:
> 
> On 02/01/2017 12:39 AM, Joe Perches wrote:
> > On Tue, 2017-01-31 at 21:24 +0200, Martin Karamihov wrote:
> > > This is checkpatch fix for hal/bb_cfg.c file:
> > > remove not necessary braces {}
> > > 
> > > Signed-off-by: Martin Karamihov <martinowar@gmail.com>
> > > ---
> > >   drivers/staging/rtl8188eu/hal/bb_cfg.c | 3 +--
> > >   1 file changed, 1 insertion(+), 2 deletions(-)
> > > 
> > > diff --git a/drivers/staging/rtl8188eu/hal/bb_cfg.c b/drivers/staging/rtl8188eu/hal/bb_cfg.c
> > > index 134fa6c595a8..26e0ef224299 100644
> > > --- a/drivers/staging/rtl8188eu/hal/bb_cfg.c
> > > +++ b/drivers/staging/rtl8188eu/hal/bb_cfg.c
> > > @@ -534,9 +534,8 @@ static void store_pwrindex_offset(struct adapter *adapter,
> > >   		power_level_offset[11] = data;
> > >   	if (regaddr == rTxAGC_B_Mcs11_Mcs08)
> > >   		power_level_offset[12] = data;
> > > -	if (regaddr == rTxAGC_B_Mcs15_Mcs12) {
> > > +	if (regaddr == rTxAGC_B_Mcs15_Mcs12)
> > >   		power_level_offset[13] = data;
> > > -	}
> > 
> > presumably, this and the regaddr block above it
> > should be an else if or a switch/case.
> > 
> I will prepare the patch if this code modification is needed right now. 
> Is it?

No more nor less than the suggested brace removal.
Do please remember (or learn) that checkpatch is
a brainless script and clarifying the code for a
human reader is much more important than making a
file not have any checkpatch warnings.

  reply	other threads:[~2017-02-01 18:11 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-28  8:49 [PATCH] staging: rtl8188eu: checkpatch fixes: removed not necessary braces {} Martin Karamihov
2017-01-28  9:11 ` Greg KH
2017-01-29 16:43   ` Bjørn Mork
2017-01-29 18:57     ` martinowar
2017-02-02 22:53     ` Joe Perches
2017-01-31 19:24 ` [PATCH v2] staging: rtl8188eu: remove not necessary braces {} (checkpatch fix) Martin Karamihov
2017-01-31 22:39   ` Joe Perches
2017-02-01 16:36     ` Martin Karamihov
2017-02-01 18:11       ` Joe Perches [this message]
2017-02-02  6:06         ` Martin Karamihov
2017-02-02 23:32           ` Joe Perches

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=1485972712.2560.11.camel@perches.com \
    --to=joe@perches.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martinowar@gmail.com \
    /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