All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] video: fbdev: i810: use true,false for bool variables
@ 2020-04-22  7:18 ` Jason Yan
  0 siblings, 0 replies; 6+ messages in thread
From: Jason Yan @ 2020-04-22  7:18 UTC (permalink / raw)
  To: adaplas, b.zolnierkie, yanaijie, linux-fbdev, dri-devel, linux-kernel

Fix the following coccicheck warning:

drivers/video/fbdev/i810/i810_main.c:1969:3-7: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1971:3-8: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1973:3-9: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1975:3-7: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:2001:3-9: WARNING: Assignment of
0/1 to bool variable

Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/video/fbdev/i810/i810_main.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/video/fbdev/i810/i810_main.c b/drivers/video/fbdev/i810/i810_main.c
index aa7583d963ac..13bbf7fe13bf 100644
--- a/drivers/video/fbdev/i810/i810_main.c
+++ b/drivers/video/fbdev/i810/i810_main.c
@@ -1966,13 +1966,13 @@ static int i810fb_setup(char *options)
 	
 	while ((this_opt = strsep(&options, ",")) != NULL) {
 		if (!strncmp(this_opt, "mtrr", 4))
-			mtrr = 1;
+			mtrr = true;
 		else if (!strncmp(this_opt, "accel", 5))
-			accel = 1;
+			accel = true;
 		else if (!strncmp(this_opt, "extvga", 6))
-			extvga = 1;
+			extvga = true;
 		else if (!strncmp(this_opt, "sync", 4))
-			sync = 1;
+			sync = true;
 		else if (!strncmp(this_opt, "vram:", 5))
 			vram = (simple_strtoul(this_opt+5, NULL, 0));
 		else if (!strncmp(this_opt, "voffset:", 8))
@@ -1998,7 +1998,7 @@ static int i810fb_setup(char *options)
 		else if (!strncmp(this_opt, "vsync2:", 7))
 			vsync2 = simple_strtoul(this_opt+7, NULL, 0);
 		else if (!strncmp(this_opt, "dcolor", 6))
-			dcolor = 1;
+			dcolor = true;
 		else if (!strncmp(this_opt, "ddc3", 4))
 			ddc3 = true;
 		else
-- 
2.21.1


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

* [PATCH] video: fbdev: i810: use true,false for bool variables
@ 2020-04-22  7:18 ` Jason Yan
  0 siblings, 0 replies; 6+ messages in thread
From: Jason Yan @ 2020-04-22  7:18 UTC (permalink / raw)
  To: adaplas, b.zolnierkie, yanaijie, linux-fbdev, dri-devel, linux-kernel

Fix the following coccicheck warning:

drivers/video/fbdev/i810/i810_main.c:1969:3-7: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1971:3-8: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1973:3-9: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1975:3-7: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:2001:3-9: WARNING: Assignment of
0/1 to bool variable

Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/video/fbdev/i810/i810_main.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/video/fbdev/i810/i810_main.c b/drivers/video/fbdev/i810/i810_main.c
index aa7583d963ac..13bbf7fe13bf 100644
--- a/drivers/video/fbdev/i810/i810_main.c
+++ b/drivers/video/fbdev/i810/i810_main.c
@@ -1966,13 +1966,13 @@ static int i810fb_setup(char *options)
 	
 	while ((this_opt = strsep(&options, ",")) != NULL) {
 		if (!strncmp(this_opt, "mtrr", 4))
-			mtrr = 1;
+			mtrr = true;
 		else if (!strncmp(this_opt, "accel", 5))
-			accel = 1;
+			accel = true;
 		else if (!strncmp(this_opt, "extvga", 6))
-			extvga = 1;
+			extvga = true;
 		else if (!strncmp(this_opt, "sync", 4))
-			sync = 1;
+			sync = true;
 		else if (!strncmp(this_opt, "vram:", 5))
 			vram = (simple_strtoul(this_opt+5, NULL, 0));
 		else if (!strncmp(this_opt, "voffset:", 8))
@@ -1998,7 +1998,7 @@ static int i810fb_setup(char *options)
 		else if (!strncmp(this_opt, "vsync2:", 7))
 			vsync2 = simple_strtoul(this_opt+7, NULL, 0);
 		else if (!strncmp(this_opt, "dcolor", 6))
-			dcolor = 1;
+			dcolor = true;
 		else if (!strncmp(this_opt, "ddc3", 4))
 			ddc3 = true;
 		else
-- 
2.21.1

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

* [PATCH] video: fbdev: i810: use true,false for bool variables
@ 2020-04-22  7:18 ` Jason Yan
  0 siblings, 0 replies; 6+ messages in thread
From: Jason Yan @ 2020-04-22  7:18 UTC (permalink / raw)
  To: adaplas, b.zolnierkie, yanaijie, linux-fbdev, dri-devel, linux-kernel

Fix the following coccicheck warning:

drivers/video/fbdev/i810/i810_main.c:1969:3-7: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1971:3-8: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1973:3-9: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:1975:3-7: WARNING: Assignment of
0/1 to bool variable
drivers/video/fbdev/i810/i810_main.c:2001:3-9: WARNING: Assignment of
0/1 to bool variable

Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/video/fbdev/i810/i810_main.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/video/fbdev/i810/i810_main.c b/drivers/video/fbdev/i810/i810_main.c
index aa7583d963ac..13bbf7fe13bf 100644
--- a/drivers/video/fbdev/i810/i810_main.c
+++ b/drivers/video/fbdev/i810/i810_main.c
@@ -1966,13 +1966,13 @@ static int i810fb_setup(char *options)
 	
 	while ((this_opt = strsep(&options, ",")) != NULL) {
 		if (!strncmp(this_opt, "mtrr", 4))
-			mtrr = 1;
+			mtrr = true;
 		else if (!strncmp(this_opt, "accel", 5))
-			accel = 1;
+			accel = true;
 		else if (!strncmp(this_opt, "extvga", 6))
-			extvga = 1;
+			extvga = true;
 		else if (!strncmp(this_opt, "sync", 4))
-			sync = 1;
+			sync = true;
 		else if (!strncmp(this_opt, "vram:", 5))
 			vram = (simple_strtoul(this_opt+5, NULL, 0));
 		else if (!strncmp(this_opt, "voffset:", 8))
@@ -1998,7 +1998,7 @@ static int i810fb_setup(char *options)
 		else if (!strncmp(this_opt, "vsync2:", 7))
 			vsync2 = simple_strtoul(this_opt+7, NULL, 0);
 		else if (!strncmp(this_opt, "dcolor", 6))
-			dcolor = 1;
+			dcolor = true;
 		else if (!strncmp(this_opt, "ddc3", 4))
 			ddc3 = true;
 		else
-- 
2.21.1

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH] video: fbdev: i810: use true,false for bool variables
  2020-04-22  7:18 ` Jason Yan
  (?)
@ 2020-05-06 17:40   ` Sam Ravnborg
  -1 siblings, 0 replies; 6+ messages in thread
From: Sam Ravnborg @ 2020-05-06 17:40 UTC (permalink / raw)
  To: Jason Yan; +Cc: adaplas, b.zolnierkie, linux-fbdev, dri-devel, linux-kernel

On Wed, Apr 22, 2020 at 03:18:26PM +0800, Jason Yan wrote:
> Fix the following coccicheck warning:
> 
> drivers/video/fbdev/i810/i810_main.c:1969:3-7: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1971:3-8: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1973:3-9: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1975:3-7: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:2001:3-9: WARNING: Assignment of
> 0/1 to bool variable
> 
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Thanks.

I have pushed this and your other three patches to drm-misc-next.
They will show up in the mainline kernel in the next merge window.

	Sam

> ---
>  drivers/video/fbdev/i810/i810_main.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/video/fbdev/i810/i810_main.c b/drivers/video/fbdev/i810/i810_main.c
> index aa7583d963ac..13bbf7fe13bf 100644
> --- a/drivers/video/fbdev/i810/i810_main.c
> +++ b/drivers/video/fbdev/i810/i810_main.c
> @@ -1966,13 +1966,13 @@ static int i810fb_setup(char *options)
>  	
>  	while ((this_opt = strsep(&options, ",")) != NULL) {
>  		if (!strncmp(this_opt, "mtrr", 4))
> -			mtrr = 1;
> +			mtrr = true;
>  		else if (!strncmp(this_opt, "accel", 5))
> -			accel = 1;
> +			accel = true;
>  		else if (!strncmp(this_opt, "extvga", 6))
> -			extvga = 1;
> +			extvga = true;
>  		else if (!strncmp(this_opt, "sync", 4))
> -			sync = 1;
> +			sync = true;
>  		else if (!strncmp(this_opt, "vram:", 5))
>  			vram = (simple_strtoul(this_opt+5, NULL, 0));
>  		else if (!strncmp(this_opt, "voffset:", 8))
> @@ -1998,7 +1998,7 @@ static int i810fb_setup(char *options)
>  		else if (!strncmp(this_opt, "vsync2:", 7))
>  			vsync2 = simple_strtoul(this_opt+7, NULL, 0);
>  		else if (!strncmp(this_opt, "dcolor", 6))
> -			dcolor = 1;
> +			dcolor = true;
>  		else if (!strncmp(this_opt, "ddc3", 4))
>  			ddc3 = true;
>  		else
> -- 
> 2.21.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH] video: fbdev: i810: use true,false for bool variables
@ 2020-05-06 17:40   ` Sam Ravnborg
  0 siblings, 0 replies; 6+ messages in thread
From: Sam Ravnborg @ 2020-05-06 17:40 UTC (permalink / raw)
  To: Jason Yan; +Cc: linux-kernel, linux-fbdev, dri-devel, b.zolnierkie

On Wed, Apr 22, 2020 at 03:18:26PM +0800, Jason Yan wrote:
> Fix the following coccicheck warning:
> 
> drivers/video/fbdev/i810/i810_main.c:1969:3-7: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1971:3-8: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1973:3-9: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1975:3-7: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:2001:3-9: WARNING: Assignment of
> 0/1 to bool variable
> 
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Thanks.

I have pushed this and your other three patches to drm-misc-next.
They will show up in the mainline kernel in the next merge window.

	Sam

> ---
>  drivers/video/fbdev/i810/i810_main.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/video/fbdev/i810/i810_main.c b/drivers/video/fbdev/i810/i810_main.c
> index aa7583d963ac..13bbf7fe13bf 100644
> --- a/drivers/video/fbdev/i810/i810_main.c
> +++ b/drivers/video/fbdev/i810/i810_main.c
> @@ -1966,13 +1966,13 @@ static int i810fb_setup(char *options)
>  	
>  	while ((this_opt = strsep(&options, ",")) != NULL) {
>  		if (!strncmp(this_opt, "mtrr", 4))
> -			mtrr = 1;
> +			mtrr = true;
>  		else if (!strncmp(this_opt, "accel", 5))
> -			accel = 1;
> +			accel = true;
>  		else if (!strncmp(this_opt, "extvga", 6))
> -			extvga = 1;
> +			extvga = true;
>  		else if (!strncmp(this_opt, "sync", 4))
> -			sync = 1;
> +			sync = true;
>  		else if (!strncmp(this_opt, "vram:", 5))
>  			vram = (simple_strtoul(this_opt+5, NULL, 0));
>  		else if (!strncmp(this_opt, "voffset:", 8))
> @@ -1998,7 +1998,7 @@ static int i810fb_setup(char *options)
>  		else if (!strncmp(this_opt, "vsync2:", 7))
>  			vsync2 = simple_strtoul(this_opt+7, NULL, 0);
>  		else if (!strncmp(this_opt, "dcolor", 6))
> -			dcolor = 1;
> +			dcolor = true;
>  		else if (!strncmp(this_opt, "ddc3", 4))
>  			ddc3 = true;
>  		else
> -- 
> 2.21.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH] video: fbdev: i810: use true,false for bool variables
@ 2020-05-06 17:40   ` Sam Ravnborg
  0 siblings, 0 replies; 6+ messages in thread
From: Sam Ravnborg @ 2020-05-06 17:40 UTC (permalink / raw)
  To: Jason Yan; +Cc: linux-kernel, linux-fbdev, dri-devel, b.zolnierkie

On Wed, Apr 22, 2020 at 03:18:26PM +0800, Jason Yan wrote:
> Fix the following coccicheck warning:
> 
> drivers/video/fbdev/i810/i810_main.c:1969:3-7: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1971:3-8: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1973:3-9: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:1975:3-7: WARNING: Assignment of
> 0/1 to bool variable
> drivers/video/fbdev/i810/i810_main.c:2001:3-9: WARNING: Assignment of
> 0/1 to bool variable
> 
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Thanks.

I have pushed this and your other three patches to drm-misc-next.
They will show up in the mainline kernel in the next merge window.

	Sam

> ---
>  drivers/video/fbdev/i810/i810_main.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/video/fbdev/i810/i810_main.c b/drivers/video/fbdev/i810/i810_main.c
> index aa7583d963ac..13bbf7fe13bf 100644
> --- a/drivers/video/fbdev/i810/i810_main.c
> +++ b/drivers/video/fbdev/i810/i810_main.c
> @@ -1966,13 +1966,13 @@ static int i810fb_setup(char *options)
>  	
>  	while ((this_opt = strsep(&options, ",")) != NULL) {
>  		if (!strncmp(this_opt, "mtrr", 4))
> -			mtrr = 1;
> +			mtrr = true;
>  		else if (!strncmp(this_opt, "accel", 5))
> -			accel = 1;
> +			accel = true;
>  		else if (!strncmp(this_opt, "extvga", 6))
> -			extvga = 1;
> +			extvga = true;
>  		else if (!strncmp(this_opt, "sync", 4))
> -			sync = 1;
> +			sync = true;
>  		else if (!strncmp(this_opt, "vram:", 5))
>  			vram = (simple_strtoul(this_opt+5, NULL, 0));
>  		else if (!strncmp(this_opt, "voffset:", 8))
> @@ -1998,7 +1998,7 @@ static int i810fb_setup(char *options)
>  		else if (!strncmp(this_opt, "vsync2:", 7))
>  			vsync2 = simple_strtoul(this_opt+7, NULL, 0);
>  		else if (!strncmp(this_opt, "dcolor", 6))
> -			dcolor = 1;
> +			dcolor = true;
>  		else if (!strncmp(this_opt, "ddc3", 4))
>  			ddc3 = true;
>  		else
> -- 
> 2.21.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

end of thread, other threads:[~2020-05-06 17:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-22  7:18 [PATCH] video: fbdev: i810: use true,false for bool variables Jason Yan
2020-04-22  7:18 ` Jason Yan
2020-04-22  7:18 ` Jason Yan
2020-05-06 17:40 ` Sam Ravnborg
2020-05-06 17:40   ` Sam Ravnborg
2020-05-06 17:40   ` Sam Ravnborg

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.