* [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses [not found] <CGME20180314021710epcas1p3766602fe312f87d916cab69af2acf203@epcas1p3.samsung.com> @ 2018-03-14 2:17 ` YOUNGKEUN OH 2018-03-14 13:58 ` Greg KH 0 siblings, 1 reply; 6+ messages in thread From: YOUNGKEUN OH @ 2018-03-14 2:17 UTC (permalink / raw) To: gregkh; +Cc: jslaby, linux-serial, linux-kernel, kernel-janitors, YOUNGKEUN OH Cleanup checkpatch error: ERROR: Macros with complex values should be enclosed in parentheses Signed-off-by: YOUNGKEUN OH <y.k.oh@samsung.com> --- drivers/tty/serial/samsung.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c index 3f2f8c1..da9bddb1 100644 --- a/drivers/tty/serial/samsung.c +++ b/drivers/tty/serial/samsung.c @@ -1455,7 +1455,7 @@ static int __init s3c24xx_serial_console_init(void) } console_initcall(s3c24xx_serial_console_init); -#define S3C24XX_SERIAL_CONSOLE &s3c24xx_serial_console +#define S3C24XX_SERIAL_CONSOLE (&s3c24xx_serial_console) #else #define S3C24XX_SERIAL_CONSOLE NULL #endif @@ -2198,7 +2198,7 @@ static void s3c24xx_serial_put_poll_char(struct uart_port *port, }; #define S3C2410_SERIAL_DRV_DATA ((kernel_ulong_t)&s3c2410_serial_drv_data) #else -#define S3C2410_SERIAL_DRV_DATA (kernel_ulong_t)NULL +#define S3C2410_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) #endif #ifdef CONFIG_CPU_S3C2412 @@ -2226,7 +2226,7 @@ static void s3c24xx_serial_put_poll_char(struct uart_port *port, }; #define S3C2412_SERIAL_DRV_DATA ((kernel_ulong_t)&s3c2412_serial_drv_data) #else -#define S3C2412_SERIAL_DRV_DATA (kernel_ulong_t)NULL +#define S3C2412_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) #endif #if defined(CONFIG_CPU_S3C2440) || defined(CONFIG_CPU_S3C2416) || \ @@ -2255,7 +2255,7 @@ static void s3c24xx_serial_put_poll_char(struct uart_port *port, }; #define S3C2440_SERIAL_DRV_DATA ((kernel_ulong_t)&s3c2440_serial_drv_data) #else -#define S3C2440_SERIAL_DRV_DATA (kernel_ulong_t)NULL +#define S3C2440_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) #endif #if defined(CONFIG_CPU_S3C6400) || defined(CONFIG_CPU_S3C6410) @@ -2283,7 +2283,7 @@ static void s3c24xx_serial_put_poll_char(struct uart_port *port, }; #define S3C6400_SERIAL_DRV_DATA ((kernel_ulong_t)&s3c6400_serial_drv_data) #else -#define S3C6400_SERIAL_DRV_DATA (kernel_ulong_t)NULL +#define S3C6400_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) #endif #ifdef CONFIG_CPU_S5PV210 @@ -2311,7 +2311,7 @@ static void s3c24xx_serial_put_poll_char(struct uart_port *port, }; #define S5PV210_SERIAL_DRV_DATA ((kernel_ulong_t)&s5pv210_serial_drv_data) #else -#define S5PV210_SERIAL_DRV_DATA (kernel_ulong_t)NULL +#define S5PV210_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) #endif #if defined(CONFIG_ARCH_EXYNOS) @@ -2350,8 +2350,8 @@ static void s3c24xx_serial_put_poll_char(struct uart_port *port, #define EXYNOS4210_SERIAL_DRV_DATA ((kernel_ulong_t)&exynos4210_serial_drv_data) #define EXYNOS5433_SERIAL_DRV_DATA ((kernel_ulong_t)&exynos5433_serial_drv_data) #else -#define EXYNOS4210_SERIAL_DRV_DATA (kernel_ulong_t)NULL -#define EXYNOS5433_SERIAL_DRV_DATA (kernel_ulong_t)NULL +#define EXYNOS4210_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) +#define EXYNOS5433_SERIAL_DRV_DATA ((kernel_ulong_t)NULL) #endif static const struct platform_device_id s3c24xx_serial_driver_ids[] = { -- 1.9.1 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses 2018-03-14 2:17 ` [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses YOUNGKEUN OH @ 2018-03-14 13:58 ` Greg KH 2018-03-22 4:37 ` y.k.oh 0 siblings, 1 reply; 6+ messages in thread From: Greg KH @ 2018-03-14 13:58 UTC (permalink / raw) To: YOUNGKEUN OH; +Cc: jslaby, linux-serial, linux-kernel, kernel-janitors On Wed, Mar 14, 2018 at 11:17:05AM +0900, YOUNGKEUN OH wrote: > Cleanup checkpatch error: > ERROR: Macros with complex values should be enclosed in parentheses > > Signed-off-by: YOUNGKEUN OH <y.k.oh@samsung.com> > --- > drivers/tty/serial/samsung.c | 16 ++++++++-------- > 1 file changed, 8 insertions(+), 8 deletions(-) > > diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c > index 3f2f8c1..da9bddb1 100644 > --- a/drivers/tty/serial/samsung.c > +++ b/drivers/tty/serial/samsung.c > @@ -1455,7 +1455,7 @@ static int __init s3c24xx_serial_console_init(void) > } > console_initcall(s3c24xx_serial_console_init); > > -#define S3C24XX_SERIAL_CONSOLE &s3c24xx_serial_console > +#define S3C24XX_SERIAL_CONSOLE (&s3c24xx_serial_console) That's not a complex macro! Please use checkpatch as a hint, not the "truth". thanks, greg k-h ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses 2018-03-14 13:58 ` Greg KH @ 2018-03-22 4:37 ` y.k.oh 2018-03-22 4:45 ` Joe Perches 2018-03-22 8:45 ` Greg KH 0 siblings, 2 replies; 6+ messages in thread From: y.k.oh @ 2018-03-22 4:37 UTC (permalink / raw) To: Greg KH; +Cc: jslaby, linux-serial, linux-kernel, kernel-janitors On 03/14/2018 10:58 PM, Greg KH wrote: > On Wed, Mar 14, 2018 at 11:17:05AM +0900, YOUNGKEUN OH wrote: >> Cleanup checkpatch error: >> ERROR: Macros with complex values should be enclosed in parentheses >> >> Signed-off-by: YOUNGKEUN OH <y.k.oh@samsung.com> >> --- >> drivers/tty/serial/samsung.c | 16 ++++++++-------- >> 1 file changed, 8 insertions(+), 8 deletions(-) >> >> diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c >> index 3f2f8c1..da9bddb1 100644 >> --- a/drivers/tty/serial/samsung.c >> +++ b/drivers/tty/serial/samsung.c >> @@ -1455,7 +1455,7 @@ static int __init s3c24xx_serial_console_init(void) >> } >> console_initcall(s3c24xx_serial_console_init); >> >> -#define S3C24XX_SERIAL_CONSOLE &s3c24xx_serial_console >> +#define S3C24XX_SERIAL_CONSOLE (&s3c24xx_serial_console) > > That's not a complex macro! > > Please use checkpatch as a hint, not the "truth". > > thanks, > > greg k-h > Dear Greg. Yes! Of course that's not a pretty complex macro. However, I think it is important to make a small effort to modify the minimum standard, Checkpatch ERROR, to ensure consistency in the Linux code. Starting with this Checkpatch error of samsung.c, I would like to start my efforts on contribution from a small point. Please review it again. If there are any points that require modification, such as comment, then I'll modify it. Thank you. Best regards, Youngkeun Oh ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses 2018-03-22 4:37 ` y.k.oh @ 2018-03-22 4:45 ` Joe Perches 2018-03-22 8:45 ` Greg KH 1 sibling, 0 replies; 6+ messages in thread From: Joe Perches @ 2018-03-22 4:45 UTC (permalink / raw) To: y.k.oh, Greg KH; +Cc: jslaby, linux-serial, linux-kernel, kernel-janitors On Thu, 2018-03-22 at 13:37 +0900, y.k.oh wrote: > > On 03/14/2018 10:58 PM, Greg KH wrote: > > On Wed, Mar 14, 2018 at 11:17:05AM +0900, YOUNGKEUN OH wrote: > > > Cleanup checkpatch error: > > > ERROR: Macros with complex values should be enclosed in parentheses > > > > > > Signed-off-by: YOUNGKEUN OH <y.k.oh@samsung.com> > > > --- > > > drivers/tty/serial/samsung.c | 16 ++++++++-------- > > > 1 file changed, 8 insertions(+), 8 deletions(-) > > > > > > diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c > > > index 3f2f8c1..da9bddb1 100644 > > > --- a/drivers/tty/serial/samsung.c > > > +++ b/drivers/tty/serial/samsung.c > > > @@ -1455,7 +1455,7 @@ static int __init s3c24xx_serial_console_init(void) > > > } > > > console_initcall(s3c24xx_serial_console_init); > > > > > > -#define S3C24XX_SERIAL_CONSOLE &s3c24xx_serial_console > > > +#define S3C24XX_SERIAL_CONSOLE (&s3c24xx_serial_console) > > > > That's not a complex macro! > > > > Please use checkpatch as a hint, not the "truth". > > > > thanks, > > > > greg k-h > > > > Dear Greg. > > Yes! Of course that's not a pretty complex macro. However, I think it is > important to make a small effort to modify the minimum standard, > Checkpatch ERROR, to ensure consistency in the Linux code. > Starting with this Checkpatch error of samsung.c, I would like to start > my efforts on contribution from a small point. Please review it again. > If there are any points that require modification, such as comment, > then I'll modify it. It might be better to remove the #defines and use an #ifdef in the one place S2C24XX_SERIAL_CONSOLE is referenced instead. ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses 2018-03-22 4:37 ` y.k.oh 2018-03-22 4:45 ` Joe Perches @ 2018-03-22 8:45 ` Greg KH 2018-03-22 9:04 ` YOUNGKEUN OH 1 sibling, 1 reply; 6+ messages in thread From: Greg KH @ 2018-03-22 8:45 UTC (permalink / raw) To: y.k.oh; +Cc: jslaby, linux-serial, linux-kernel, kernel-janitors On Thu, Mar 22, 2018 at 01:37:45PM +0900, y.k.oh wrote: > > > On 03/14/2018 10:58 PM, Greg KH wrote: > > On Wed, Mar 14, 2018 at 11:17:05AM +0900, YOUNGKEUN OH wrote: > >> Cleanup checkpatch error: > >> ERROR: Macros with complex values should be enclosed in parentheses > >> > >> Signed-off-by: YOUNGKEUN OH <y.k.oh@samsung.com> > >> --- > >> drivers/tty/serial/samsung.c | 16 ++++++++-------- > >> 1 file changed, 8 insertions(+), 8 deletions(-) > >> > >> diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c > >> index 3f2f8c1..da9bddb1 100644 > >> --- a/drivers/tty/serial/samsung.c > >> +++ b/drivers/tty/serial/samsung.c > >> @@ -1455,7 +1455,7 @@ static int __init s3c24xx_serial_console_init(void) > >> } > >> console_initcall(s3c24xx_serial_console_init); > >> > >> -#define S3C24XX_SERIAL_CONSOLE &s3c24xx_serial_console > >> +#define S3C24XX_SERIAL_CONSOLE (&s3c24xx_serial_console) > > > > That's not a complex macro! > > > > Please use checkpatch as a hint, not the "truth". > > > > thanks, > > > > greg k-h > > > Dear Greg. > > Yes! Of course that's not a pretty complex macro. However, I think it is > important to make a small effort to modify the minimum standard, > Checkpatch ERROR, to ensure consistency in the Linux code. > Starting with this Checkpatch error of samsung.c, I would like to start > my efforts on contribution from a small point. Please review it again. Why would I review something again that is not correct? If you wish to start out in kernel development, please start in drivers/staging/*/TODO, not in "core" kernel code. That is what the drivers/staging/ code is there for. good luck! greg k-h ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses 2018-03-22 8:45 ` Greg KH @ 2018-03-22 9:04 ` YOUNGKEUN OH 0 siblings, 0 replies; 6+ messages in thread From: YOUNGKEUN OH @ 2018-03-22 9:04 UTC (permalink / raw) To: Greg KH; +Cc: jslaby, linux-serial, linux-kernel, kernel-janitors On 03/22/2018 05:45 PM, Greg KH wrote: > On Thu, Mar 22, 2018 at 01:37:45PM +0900, y.k.oh wrote: >> >> >> On 03/14/2018 10:58 PM, Greg KH wrote: >>> On Wed, Mar 14, 2018 at 11:17:05AM +0900, YOUNGKEUN OH wrote: >>>> Cleanup checkpatch error: >>>> ERROR: Macros with complex values should be enclosed in parentheses >>>> >>>> Signed-off-by: YOUNGKEUN OH <y.k.oh@samsung.com> >>>> --- >>>> drivers/tty/serial/samsung.c | 16 ++++++++-------- >>>> 1 file changed, 8 insertions(+), 8 deletions(-) >>>> >>>> diff --git a/drivers/tty/serial/samsung.c b/drivers/tty/serial/samsung.c >>>> index 3f2f8c1..da9bddb1 100644 >>>> --- a/drivers/tty/serial/samsung.c >>>> +++ b/drivers/tty/serial/samsung.c >>>> @@ -1455,7 +1455,7 @@ static int __init s3c24xx_serial_console_init(void) >>>> } >>>> console_initcall(s3c24xx_serial_console_init); >>>> >>>> -#define S3C24XX_SERIAL_CONSOLE &s3c24xx_serial_console >>>> +#define S3C24XX_SERIAL_CONSOLE (&s3c24xx_serial_console) >>> >>> That's not a complex macro! >>> >>> Please use checkpatch as a hint, not the "truth". >>> >>> thanks, >>> >>> greg k-h >>> >> Dear Greg. >> >> Yes! Of course that's not a pretty complex macro. However, I think it is >> important to make a small effort to modify the minimum standard, >> Checkpatch ERROR, to ensure consistency in the Linux code. >> Starting with this Checkpatch error of samsung.c, I would like to start >> my efforts on contribution from a small point. Please review it again. > > Why would I review something again that is not correct? > > If you wish to start out in kernel development, please start in > drivers/staging/*/TODO, not in "core" kernel code. That is what the > drivers/staging/ code is there for. > > good luck! > > greg k-h > Dear Greg. Thank you for your comment. I'll see you soon with a good patch. Sincerely, Youngkeun Oh ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2018-03-22 9:04 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <CGME20180314021710epcas1p3766602fe312f87d916cab69af2acf203@epcas1p3.samsung.com> 2018-03-14 2:17 ` [PATCH] serial: samsung: macros with complex values should be enclosed in parentheses YOUNGKEUN OH 2018-03-14 13:58 ` Greg KH 2018-03-22 4:37 ` y.k.oh 2018-03-22 4:45 ` Joe Perches 2018-03-22 8:45 ` Greg KH 2018-03-22 9:04 ` YOUNGKEUN OH
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).