outreachy.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH] staging: media: av7110: comparison to NULL could be written "fe_func"
@ 2022-04-18 18:09 Aliya Rahmani
  2022-04-18 18:22 ` Julia Lawall
  0 siblings, 1 reply; 2+ messages in thread
From: Aliya Rahmani @ 2022-04-18 18:09 UTC (permalink / raw)
  To: mchehab; +Cc: gregkh, linux-staging, outreachy, linux-kernel, Aliya Rahmani

Fixed coding style for null comparisons to be more
consistent with the rest of the kernel coding style.

Signed-off-by: Aliya Rahmani <aliyarahmani786@gmail.com>
---
 drivers/staging/media/av7110/av7110.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/media/av7110/av7110.c b/drivers/staging/media/av7110/av7110.c
index d74ee0ecfb36..bdc6adf70d72 100644
--- a/drivers/staging/media/av7110/av7110.c
+++ b/drivers/staging/media/av7110/av7110.c
@@ -107,7 +107,7 @@ static int av7110_num;
 
 #define FE_FUNC_OVERRIDE(fe_func, av7110_copy, av7110_func) \
 {\
-	if (fe_func != NULL) { \
+	if (fe_func) { \
 		av7110_copy = fe_func; \
 		fe_func = av7110_func; \
 	} \
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] staging: media: av7110: comparison to NULL could be written "fe_func"
  2022-04-18 18:09 [PATCH] staging: media: av7110: comparison to NULL could be written "fe_func" Aliya Rahmani
@ 2022-04-18 18:22 ` Julia Lawall
  0 siblings, 0 replies; 2+ messages in thread
From: Julia Lawall @ 2022-04-18 18:22 UTC (permalink / raw)
  To: Aliya Rahmani; +Cc: mchehab, gregkh, linux-staging, outreachy, linux-kernel



On Mon, 18 Apr 2022, Aliya Rahmani wrote:

> Fixed coding style for null comparisons to be more
> consistent with the rest of the kernel coding style.

The log message (both the subject line and the text just above) should be
in the imperative.  Typically, that means that you should not be using
verbs that end in "ed".

There is too much detail in the subject line.  Consider how you could give
the general idea, but be more concise.

For the text above, what could you say rather than "fix".  When you say
that you fixed something, the reader may know (or at least hope) that it
is better, but gets no information about what you did, nor why.

julia

>
> Signed-off-by: Aliya Rahmani <aliyarahmani786@gmail.com>
> ---
>  drivers/staging/media/av7110/av7110.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/media/av7110/av7110.c b/drivers/staging/media/av7110/av7110.c
> index d74ee0ecfb36..bdc6adf70d72 100644
> --- a/drivers/staging/media/av7110/av7110.c
> +++ b/drivers/staging/media/av7110/av7110.c
> @@ -107,7 +107,7 @@ static int av7110_num;
>
>  #define FE_FUNC_OVERRIDE(fe_func, av7110_copy, av7110_func) \
>  {\
> -	if (fe_func != NULL) { \
> +	if (fe_func) { \
>  		av7110_copy = fe_func; \
>  		fe_func = av7110_func; \
>  	} \
> --
> 2.25.1
>
>
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-04-18 18:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-18 18:09 [PATCH] staging: media: av7110: comparison to NULL could be written "fe_func" Aliya Rahmani
2022-04-18 18:22 ` Julia Lawall

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).