aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2020-06-10 13:36:38 +0100
committerGuenter Roeck <linux@roeck-us.net>2020-07-19 16:25:20 -0700
commit9e444234b6d8de48e9032f47997773cd98d863a5 (patch)
tree2a0f7e9a41648561ffb93d41693c097475f4c930 /drivers/hwmon
parentLinux 5.8-rc6 (diff)
downloadlinux-dev-9e444234b6d8de48e9032f47997773cd98d863a5.tar.xz
linux-dev-9e444234b6d8de48e9032f47997773cd98d863a5.zip
hwmon: (i5k_amb) remove redundant assignment to variable res
The variable res is being initialized with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King <colin.king@canonical.com> Link: https://lore.kernel.org/r/20200610123638.1133428-1-colin.king@canonical.com Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon')
-rw-r--r--drivers/hwmon/i5k_amb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hwmon/i5k_amb.c b/drivers/hwmon/i5k_amb.c
index eeac4b04df27..cd5b62905eee 100644
--- a/drivers/hwmon/i5k_amb.c
+++ b/drivers/hwmon/i5k_amb.c
@@ -396,7 +396,7 @@ exit_remove:
static int i5k_amb_add(void)
{
- int res = -ENODEV;
+ int res;
/* only ever going to be one of these */
amb_pdev = platform_device_alloc(DRVNAME, 0);