linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] macintosh/ams-input: Use true and false for boolean values
@ 2018-01-24  1:48 Gustavo A. R. Silva
  2018-01-24  1:55 ` Michael Hanselmann
  2018-01-29  4:13 ` Michael Ellerman
  0 siblings, 2 replies; 3+ messages in thread
From: Gustavo A. R. Silva @ 2018-01-24  1:48 UTC (permalink / raw)
  To: Michael Hanselmann, Benjamin Herrenschmidt
  Cc: linuxppc-dev, linux-kernel, Gustavo A. R. Silva

Assign true or false to boolean variables instead of an integer value.

This issue was detected with the help of Coccinelle

Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
---
 drivers/macintosh/ams/ams-input.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/macintosh/ams/ams-input.c b/drivers/macintosh/ams/ams-input.c
index 2edae7d..fe248f6 100644
--- a/drivers/macintosh/ams/ams-input.c
+++ b/drivers/macintosh/ams/ams-input.c
@@ -91,7 +91,7 @@ static int ams_input_enable(void)
 		return error;
 	}
 
-	joystick = 1;
+	joystick = true;
 
 	return 0;
 }
@@ -104,7 +104,7 @@ static void ams_input_disable(void)
 		ams_info.idev = NULL;
 	}
 
-	joystick = 0;
+	joystick = false;
 }
 
 static ssize_t ams_input_show_joystick(struct device *dev,
-- 
2.7.4

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

* Re: [PATCH] macintosh/ams-input: Use true and false for boolean values
  2018-01-24  1:48 [PATCH] macintosh/ams-input: Use true and false for boolean values Gustavo A. R. Silva
@ 2018-01-24  1:55 ` Michael Hanselmann
  2018-01-29  4:13 ` Michael Ellerman
  1 sibling, 0 replies; 3+ messages in thread
From: Michael Hanselmann @ 2018-01-24  1:55 UTC (permalink / raw)
  To: Gustavo A. R. Silva, Michael Hanselmann, Benjamin Herrenschmidt
  Cc: linuxppc-dev, linux-kernel, Gustavo A. R. Silva

On 24.01.2018 02:48, Gustavo A. R. Silva wrote:
> Assign true or false to boolean variables instead of an integer value.
> 
> This issue was detected with the help of Coccinelle
> 
> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>

Reviewed-by: Michael Hanselmann <public@hansmi.ch>

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

* Re: macintosh/ams-input: Use true and false for boolean values
  2018-01-24  1:48 [PATCH] macintosh/ams-input: Use true and false for boolean values Gustavo A. R. Silva
  2018-01-24  1:55 ` Michael Hanselmann
@ 2018-01-29  4:13 ` Michael Ellerman
  1 sibling, 0 replies; 3+ messages in thread
From: Michael Ellerman @ 2018-01-29  4:13 UTC (permalink / raw)
  To: Gustavo A. R. Silva, Michael Hanselmann, Benjamin Herrenschmidt
  Cc: Gustavo A. R. Silva, linuxppc-dev, linux-kernel

On Wed, 2018-01-24 at 01:48:46 UTC, "Gustavo A. R. Silva" wrote:
> Assign true or false to boolean variables instead of an integer value.
> 
> This issue was detected with the help of Coccinelle
> 
> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
> Reviewed-by: Michael Hanselmann <public@hansmi.ch>

Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/516c32f64f144721ca05b881737e44

cheers

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

end of thread, other threads:[~2018-01-29  4:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-24  1:48 [PATCH] macintosh/ams-input: Use true and false for boolean values Gustavo A. R. Silva
2018-01-24  1:55 ` Michael Hanselmann
2018-01-29  4:13 ` Michael Ellerman

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).