All of lore.kernel.org
 help / color / mirror / Atom feed
* [input:next 2591/2593] drivers/input/input.c:1749:5-8: Unneeded variable: "ret". Return "0" on line 1772
@ 2020-12-05  3:14 kernel test robot
  2020-12-05  3:14 ` [PATCH] Input: fix returnvar.cocci warnings kernel test robot
  0 siblings, 1 reply; 2+ messages in thread
From: kernel test robot @ 2020-12-05  3:14 UTC (permalink / raw)
  To: kbuild

[-- Attachment #1: Type: text/plain, Size: 1078 bytes --]

CC: kbuild-all(a)lists.01.org
CC: linux-input(a)vger.kernel.org
TO: Patrik Fimml <patrikf@chromium.org>
CC: Dmitry Torokhov <dmitry.torokhov@gmail.com>
CC: Andrzej Pietrasiewicz <andrzej.p@collabora.com>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git next
head:   7ce8d91b8a849c4b9a010a8b773e3838a8e3d030
commit: a181616487dbdbc953e476d1da15365f887859ed [2591/2593] Input: Add "inhibited" property
:::::: branch date: 7 hours ago
:::::: commit date: 2 days ago
config: sparc-randconfig-c003-20201204 (attached as .config)
compiler: sparc64-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Julia Lawall <julia.lawall@lip6.fr>


"coccinelle warnings: (new ones prefixed by >>)"
>> drivers/input/input.c:1749:5-8: Unneeded variable: "ret". Return "0" on line 1772

Please review and possibly fold the followup patch.

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 34294 bytes --]

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

* [PATCH] Input: fix returnvar.cocci warnings
  2020-12-05  3:14 [input:next 2591/2593] drivers/input/input.c:1749:5-8: Unneeded variable: "ret". Return "0" on line 1772 kernel test robot
@ 2020-12-05  3:14 ` kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2020-12-05  3:14 UTC (permalink / raw)
  To: kbuild

[-- Attachment #1: Type: text/plain, Size: 1605 bytes --]

CC: kbuild-all(a)lists.01.org
CC: linux-input(a)vger.kernel.org
TO: Patrik Fimml <patrikf@chromium.org>
CC: Dmitry Torokhov <dmitry.torokhov@gmail.com>
CC: Andrzej Pietrasiewicz <andrzej.p@collabora.com>
CC: linux-input(a)vger.kernel.org
CC: linux-kernel(a)vger.kernel.org

From: kernel test robot <lkp@intel.com>

drivers/input/input.c:1749:5-8: Unneeded variable: "ret". Return "0" on line 1772


 Remove unneeded variable used to store return value.

Generated by: scripts/coccinelle/misc/returnvar.cocci

Fixes: a181616487db ("Input: Add "inhibited" property")
CC: Patrik Fimml <patrikf@chromium.org>
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/dtor/input.git next
head:   7ce8d91b8a849c4b9a010a8b773e3838a8e3d030
commit: a181616487dbdbc953e476d1da15365f887859ed [2591/2593] Input: Add "inhibited" property
:::::: branch date: 7 hours ago
:::::: commit date: 2 days ago

Please take the patch only if it's a positive warning. Thanks!

 input.c |    4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

--- a/drivers/input/input.c
+++ b/drivers/input/input.c
@@ -1746,8 +1746,6 @@ EXPORT_SYMBOL(input_reset_device);
 
 static int input_inhibit_device(struct input_dev *dev)
 {
-	int ret = 0;
-
 	mutex_lock(&dev->mutex);
 
 	if (dev->inhibited)
@@ -1769,7 +1767,7 @@ static int input_inhibit_device(struct i
 
 out:
 	mutex_unlock(&dev->mutex);
-	return ret;
+	return 0;
 }
 
 static int input_uninhibit_device(struct input_dev *dev)

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

end of thread, other threads:[~2020-12-05  3:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-05  3:14 [input:next 2591/2593] drivers/input/input.c:1749:5-8: Unneeded variable: "ret". Return "0" on line 1772 kernel test robot
2020-12-05  3:14 ` [PATCH] Input: fix returnvar.cocci warnings kernel test robot

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.