* [PATCH] Staging:greybus: Add () around gcam macro.
@ 2021-04-27 15:30 tawahpeggy
2021-04-27 15:31 ` [Outreachy kernel] " Julia Lawall
2021-04-27 15:52 ` Johan Hovold
0 siblings, 2 replies; 4+ messages in thread
From: tawahpeggy @ 2021-04-27 15:30 UTC (permalink / raw)
To: Johan Hovold, Alex Elder, Greg Kroah-Hartman; +Cc: outreachy-kernel
checkpatch.pl suggested parenthesis be added aroung gcam macro variable.
Signed-off-by: tawahpeggy <tawahpeggy98@gmail.com>
---
drivers/staging/greybus/camera.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/greybus/camera.c b/drivers/staging/greybus/camera.c
index cdbb42cd413b..324a26430f71 100644
--- a/drivers/staging/greybus/camera.c
+++ b/drivers/staging/greybus/camera.c
@@ -182,7 +182,7 @@ static const struct gb_camera_fmt_info *gb_camera_get_format_info(u16 gb_fmt)
#define gcam_dbg(gcam, format...) dev_dbg(&gcam->bundle->dev, format)
#define gcam_info(gcam, format...) dev_info(&gcam->bundle->dev, format)
-#define gcam_err(gcam, format...) dev_err(&gcam->bundle->dev, format)
+#define gcam_err((gcam), format...) dev_err(&gcam->bundle->dev, format)
static int gb_camera_operation_sync_flags(struct gb_connection *connection,
int type, unsigned int flags,
--
2.17.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [Outreachy kernel] [PATCH] Staging:greybus: Add () around gcam macro.
2021-04-27 15:30 [PATCH] Staging:greybus: Add () around gcam macro tawahpeggy
@ 2021-04-27 15:31 ` Julia Lawall
2021-04-27 15:52 ` Johan Hovold
1 sibling, 0 replies; 4+ messages in thread
From: Julia Lawall @ 2021-04-27 15:31 UTC (permalink / raw)
To: tawahpeggy; +Cc: Johan Hovold, Alex Elder, Greg Kroah-Hartman, outreachy-kernel
On Tue, 27 Apr 2021, tawahpeggy wrote:
> checkpatch.pl suggested parenthesis be added aroung gcam macro variable.
>
> Signed-off-by: tawahpeggy <tawahpeggy98@gmail.com>
Remember that you need to use your real name.
julia
>
> ---
> drivers/staging/greybus/camera.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/greybus/camera.c b/drivers/staging/greybus/camera.c
> index cdbb42cd413b..324a26430f71 100644
> --- a/drivers/staging/greybus/camera.c
> +++ b/drivers/staging/greybus/camera.c
> @@ -182,7 +182,7 @@ static const struct gb_camera_fmt_info *gb_camera_get_format_info(u16 gb_fmt)
>
> #define gcam_dbg(gcam, format...) dev_dbg(&gcam->bundle->dev, format)
> #define gcam_info(gcam, format...) dev_info(&gcam->bundle->dev, format)
> -#define gcam_err(gcam, format...) dev_err(&gcam->bundle->dev, format)
> +#define gcam_err((gcam), format...) dev_err(&gcam->bundle->dev, format)
>
> static int gb_camera_operation_sync_flags(struct gb_connection *connection,
> int type, unsigned int flags,
> --
> 2.17.1
>
> --
> You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to outreachy-kernel+unsubscribe@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20210427153024.GA14574%40peggy-Lenovo-V130-15IKB.
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Staging:greybus: Add () around gcam macro.
2021-04-27 15:30 [PATCH] Staging:greybus: Add () around gcam macro tawahpeggy
2021-04-27 15:31 ` [Outreachy kernel] " Julia Lawall
@ 2021-04-27 15:52 ` Johan Hovold
2021-04-27 15:59 ` PEGGY TAWAH
1 sibling, 1 reply; 4+ messages in thread
From: Johan Hovold @ 2021-04-27 15:52 UTC (permalink / raw)
To: tawahpeggy; +Cc: Alex Elder, Greg Kroah-Hartman, outreachy-kernel
On Tue, Apr 27, 2021 at 11:30:28AM -0400, tawahpeggy wrote:
> checkpatch.pl suggested parenthesis be added aroung gcam macro variable.
>
> Signed-off-by: tawahpeggy <tawahpeggy98@gmail.com>
>
> ---
> drivers/staging/greybus/camera.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/greybus/camera.c b/drivers/staging/greybus/camera.c
> index cdbb42cd413b..324a26430f71 100644
> --- a/drivers/staging/greybus/camera.c
> +++ b/drivers/staging/greybus/camera.c
> @@ -182,7 +182,7 @@ static const struct gb_camera_fmt_info *gb_camera_get_format_info(u16 gb_fmt)
>
> #define gcam_dbg(gcam, format...) dev_dbg(&gcam->bundle->dev, format)
> #define gcam_info(gcam, format...) dev_info(&gcam->bundle->dev, format)
> -#define gcam_err(gcam, format...) dev_err(&gcam->bundle->dev, format)
> +#define gcam_err((gcam), format...) dev_err(&gcam->bundle->dev, format)
I'm pretty sure this is not what checkpatch suggested. You could add
parenthesis around gcam in the &gcam->bundle bit though.
Also doesn't make sense to change only one of the macros.
> static int gb_camera_operation_sync_flags(struct gb_connection *connection,
> int type, unsigned int flags,
Johan
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Staging:greybus: Add () around gcam macro.
2021-04-27 15:52 ` Johan Hovold
@ 2021-04-27 15:59 ` PEGGY TAWAH
0 siblings, 0 replies; 4+ messages in thread
From: PEGGY TAWAH @ 2021-04-27 15:59 UTC (permalink / raw)
To: Johan Hovold; +Cc: Alex Elder, Greg Kroah-Hartman, outreachy-kernel
[-- Attachment #1: Type: text/plain, Size: 1437 bytes --]
Ok, I'll check it out. Thanks for your corrections
On Tue, Apr 27, 2021, 4:52 PM Johan Hovold <johan@kernel.org> wrote:
> On Tue, Apr 27, 2021 at 11:30:28AM -0400, tawahpeggy wrote:
> > checkpatch.pl suggested parenthesis be added aroung gcam macro variable.
> >
> > Signed-off-by: tawahpeggy <tawahpeggy98@gmail.com>
> >
> > ---
> > drivers/staging/greybus/camera.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/staging/greybus/camera.c
> b/drivers/staging/greybus/camera.c
> > index cdbb42cd413b..324a26430f71 100644
> > --- a/drivers/staging/greybus/camera.c
> > +++ b/drivers/staging/greybus/camera.c
> > @@ -182,7 +182,7 @@ static const struct gb_camera_fmt_info
> *gb_camera_get_format_info(u16 gb_fmt)
> >
> > #define gcam_dbg(gcam, format...) dev_dbg(&gcam->bundle->dev, format)
> > #define gcam_info(gcam, format...) dev_info(&gcam->bundle->dev,
> format)
> > -#define gcam_err(gcam, format...) dev_err(&gcam->bundle->dev, format)
> > +#define gcam_err((gcam), format...) dev_err(&gcam->bundle->dev, format)
>
> I'm pretty sure this is not what checkpatch suggested. You could add
> parenthesis around gcam in the &gcam->bundle bit though.
>
> Also doesn't make sense to change only one of the macros.
>
> > static int gb_camera_operation_sync_flags(struct gb_connection
> *connection,
> > int type, unsigned int flags,
>
> Johan
>
[-- Attachment #2: Type: text/html, Size: 2096 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-04-27 15:59 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-27 15:30 [PATCH] Staging:greybus: Add () around gcam macro tawahpeggy
2021-04-27 15:31 ` [Outreachy kernel] " Julia Lawall
2021-04-27 15:52 ` Johan Hovold
2021-04-27 15:59 ` PEGGY TAWAH
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.