From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: kernel test robot <lkp@intel.com>
Cc: Michael Srba <Michael.Srba@seznam.cz>,
kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
linux-input@vger.kernel.org
Subject: Re: [PATCH] Input: fix boolreturn.cocci warnings
Date: Thu, 18 Feb 2021 19:35:57 -0800 [thread overview]
Message-ID: <YC8yHSYnLIJaRnR2@google.com> (raw)
In-Reply-To: <20210218095953.GA24768@4e7c6a388622>
Hi,
On Thu, Feb 18, 2021 at 05:59:53PM +0800, kernel test robot wrote:
> From: kernel test robot <lkp@intel.com>
>
> drivers/input/touchscreen/zinitix.c:250:8-9: WARNING: return of 0/1 in function 'zinitix_init_touch' with return type bool
>
> Return statements in functions returning bool should use
> true/false instead of 1/0.
> Generated by: scripts/coccinelle/misc/boolreturn.cocci
>
> Fixes: 26822652c85e ("Input: add zinitix touchscreen driver")
> CC: Michael Srba <Michael.Srba@seznam.cz>
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: kernel test robot <lkp@intel.com>
> ---
>
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head: f40ddce88593482919761f74910f42f4b84c004b
> commit: 26822652c85eff14e40115255727b2693400c524 Input: add zinitix touchscreen driver
>
> zinitix.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> --- a/drivers/input/touchscreen/zinitix.c
> +++ b/drivers/input/touchscreen/zinitix.c
> @@ -247,7 +247,7 @@ static bool zinitix_init_touch(struct bt
> udelay(10);
> }
>
> - return 0;
> + return false;
This is incorrect as function is trying to return error codes. It needs
to be changed to return int. I'll take care of it.
Thanks.
--
Dmitry
next prev parent reply other threads:[~2021-02-19 3:36 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-18 9:59 drivers/input/touchscreen/zinitix.c:250:8-9: WARNING: return of 0/1 in function 'zinitix_init_touch' with return type bool kernel test robot
2021-02-18 9:59 ` [PATCH] Input: fix boolreturn.cocci warnings kernel test robot
2021-02-19 3:35 ` Dmitry Torokhov [this message]
-- strict thread matches above, loose matches on Subject: below --
2018-08-16 2:02 [PATCH V1 3/3] Input: new da7280 haptic driver Roy Im
2018-08-16 6:46 ` [PATCH] Input: fix boolreturn.cocci warnings kbuild test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YC8yHSYnLIJaRnR2@google.com \
--to=dmitry.torokhov@gmail.com \
--cc=Michael.Srba@seznam.cz \
--cc=kbuild-all@lists.01.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox