linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] platform/x86: acer-wmi: use true and false for boolean values
@ 2018-08-05  0:18 Gustavo A. R. Silva
  2018-08-05 10:26 ` Andy Shevchenko
  0 siblings, 1 reply; 6+ messages in thread
From: Gustavo A. R. Silva @ 2018-08-05  0:18 UTC (permalink / raw)
  To: Lee, Chun-Yi, Darren Hart, Andy Shevchenko
  Cc: platform-driver-x86, linux-kernel, Gustavo A. R. Silva

Return statements in functions returning bool should use true or false
instead of an integer value.

This code was detected with the help of Coccinelle.

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

diff --git a/drivers/platform/x86/acer-wmi.c b/drivers/platform/x86/acer-wmi.c
index 8952173..ede92be 100644
--- a/drivers/platform/x86/acer-wmi.c
+++ b/drivers/platform/x86/acer-wmi.c
@@ -673,9 +673,9 @@ static void __init find_quirks(void)
 static bool has_cap(u32 cap)
 {
 	if ((interface->capability & cap) != 0)
-		return 1;
+		return true;
 
-	return 0;
+	return false;
 }
 
 /*
-- 
2.7.4


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

end of thread, other threads:[~2018-08-06 19:06 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-05  0:18 [PATCH] platform/x86: acer-wmi: use true and false for boolean values Gustavo A. R. Silva
2018-08-05 10:26 ` Andy Shevchenko
2018-08-06 16:41   ` David Laight
2018-08-06 16:42     ` Joe Perches
2018-08-06 17:24       ` Gustavo A. R. Silva
2018-08-06 19:06       ` Andy Shevchenko

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