public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: YAMANE Toshiaki <yamanetoshi@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/3] Add parenthesis to macros with complex values in trace.h
Date: Tue, 2 Oct 2012 15:21:57 +0300	[thread overview]
Message-ID: <20121002122157.GU4587@mwanda> (raw)
In-Reply-To: <1349178868-29677-1-git-send-email-yamanetoshi@gmail.com>

On Tue, Oct 02, 2012 at 08:54:28PM +0900, YAMANE Toshiaki wrote:
> fixed some checkpatch below error.
> -ERROR: Macros with complex values should be enclosed in parenthesis
> 
> Signed-off-by: Toshiaki Yamane <yamanetoshi@gmail.com>
> ---
>  drivers/staging/rts_pstor/trace.h |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/staging/rts_pstor/trace.h b/drivers/staging/rts_pstor/trace.h
> index 740999c..a34493c 100644
> --- a/drivers/staging/rts_pstor/trace.h
> +++ b/drivers/staging/rts_pstor/trace.h
> @@ -78,8 +78,8 @@ do {													\
>  	goto label; 											\
>  } while (0)
>  #else
> -#define TRACE_RET(chip, ret)	return ret
> -#define TRACE_GOTO(chip, label)	goto label
> +#define TRACE_RET(chip, ret)	return(ret)
> +#define TRACE_GOTO(chip, label)	goto(label)

This will cause a compile error.

There is no need to do this, checkpatch.pl is wrong here.

regards,
dan carpenter


  parent reply	other threads:[~2012-10-02 12:22 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-02 11:53 [PATCH 1/3] Fix trailing whitespace in trace.h YAMANE Toshiaki
2012-10-02 11:54 ` [PATCH 2/3] Add parenthesis to macros with complex values " YAMANE Toshiaki
2012-10-02 12:13   ` Andy Shevchenko
2012-10-02 12:21   ` Dan Carpenter [this message]
2012-10-03  0:19     ` Toshiaki Yamane
2012-10-02 11:54 ` [PATCH 3/3] Fix line over 80 character issue and space before tabs issue " YAMANE Toshiaki
2012-10-02 12:23   ` Dan Carpenter
2012-10-03  0:19     ` Toshiaki Yamane
2012-10-02 12:12 ` [PATCH 1/3] Fix trailing whitespace " Andy Shevchenko
2012-10-03  0:18   ` Toshiaki Yamane

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=20121002122157.GU4587@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=yamanetoshi@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