Linux kernel staging patches
 help / color / mirror / Atom feed
From: Julia Lawall <julia.lawall@inria.fr>
To: Aliya Rahmani <aliyarahmani786@gmail.com>
Cc: clabbe@baylibre.com, gregkh@linuxfoundation.org,
	 linux-staging@lists.linux.dev, outreachy@lists.linux.dev,
	 linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] staging: media: zoran: avoid macro argument precedence issues
Date: Mon, 18 Apr 2022 14:09:37 +0200 (CEST)	[thread overview]
Message-ID: <alpine.DEB.2.22.394.2204181408230.11986@hadrien> (raw)
In-Reply-To: <20220418115948.5456-4-aliyarahmani786@gmail.com>



On Mon, 18 Apr 2022, Aliya Rahmani wrote:

> This patch fixes checkpatch warnings of precedence issues. Added parentheses
> around macro argument 'num'.

You should use the imperative.  This "Add" rather than "Added".

The subject line would be better as "add parentheses on macro parameter".
That describes what you did, rather than what you avoided (avoided how?).

julia

>
> Signed-off-by: Aliya Rahmani <aliyarahmani786@gmail.com>
> ---
>  drivers/staging/media/zoran/videocodec.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/media/zoran/videocodec.c b/drivers/staging/media/zoran/videocodec.c
> index 19732a47c8bd..925f90fd5885 100644
> --- a/drivers/staging/media/zoran/videocodec.c
> +++ b/drivers/staging/media/zoran/videocodec.c
> @@ -22,7 +22,7 @@ MODULE_PARM_DESC(videocodec_debug, "Debug level (0-4)");
>
>  #define dprintk(num, format, args...) \
>  	do { \
> -		if (videocodec_debug >= num) \
> +		if (videocodec_debug >= (num)) \
>  			printk(format, ##args); \
>  	} while (0)
>
> --
> 2.25.1
>
>
>

      reply	other threads:[~2022-04-18 12:09 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-18 11:59 [PATCH 0/3] staging: media: zoran: fix warnings reported by checkpatch Aliya Rahmani
2022-04-18 11:59 ` [PATCH 1/3] staging: media: zoran: use seq_puts() instead of seq_printf() Aliya Rahmani
2022-04-18 11:59 ` [PATCH 2/3] staging: media: zoran: Code cleanup - else is not generally useful after a break or return Aliya Rahmani
2022-04-18 12:11   ` Julia Lawall
2022-04-18 11:59 ` [PATCH 3/3] staging: media: zoran: avoid macro argument precedence issues Aliya Rahmani
2022-04-18 12:09   ` Julia Lawall [this message]

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=alpine.DEB.2.22.394.2204181408230.11986@hadrien \
    --to=julia.lawall@inria.fr \
    --cc=aliyarahmani786@gmail.com \
    --cc=clabbe@baylibre.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    --cc=outreachy@lists.linux.dev \
    /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