diff options
author | Lee Jones <lee.jones@linaro.org> | 2020-07-01 11:58:49 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-07-01 16:05:38 +0300 |
commit | f33e92e50c82319718a21ec372f3df9eff59bfa9 (patch) | |
tree | 1abddf58aefe73a69189b6ef0488b265896dd31c /drivers/misc/genwqe/card_base.c | |
parent | 6a57251c70a4ab48ed5efa8a55f43d0f6b47d508 (diff) | |
download | linux-f33e92e50c82319718a21ec372f3df9eff59bfa9.tar.xz |
misc: genwqe: card_base: Remove set but unused variable 'rc'
Variable 'rc' hasn't been checked since the driver's inception
in 2013. If it hasn't caused any issues since then, it's unlikely
to in the future. Let's take it out for now.
Fixes the following W=1 kernel build warning(s):
drivers/misc/genwqe/card_base.c: In function ‘genwqe_health_check_stop’:
/home/lee/projects/linux/kernel/drivers/misc/genwqe/card_base.c:1046:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable]
1046 | int rc;
| ^~
Cc: Michael Jung <mijung@gmx.net>
Cc: Michael Ruettger <michael@ibmra.de>
Cc: Frank Haverkamp <haver@linux.ibm.com>
Cc: Joerg-Stephan Vogt <jsvogt@de.ibm.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Reviewed-by: Frank Haverkamp <haver@linux.ibm.com>
Link: https://lore.kernel.org/r/20200701085853.164358-17-lee.jones@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/genwqe/card_base.c')
-rw-r--r-- | drivers/misc/genwqe/card_base.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/misc/genwqe/card_base.c b/drivers/misc/genwqe/card_base.c index 9969c0003f15..0e83192a8285 100644 --- a/drivers/misc/genwqe/card_base.c +++ b/drivers/misc/genwqe/card_base.c @@ -1043,12 +1043,10 @@ static int genwqe_health_thread_running(struct genwqe_dev *cd) static int genwqe_health_check_stop(struct genwqe_dev *cd) { - int rc; - if (!genwqe_health_thread_running(cd)) return -EIO; - rc = kthread_stop(cd->health_thread); + kthread_stop(cd->health_thread); cd->health_thread = NULL; return 0; } |