summaryrefslogtreecommitdiff
path: root/drivers/base
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2021-04-16 15:43:52 +0300
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2021-04-22 16:22:38 +0300
commite48802333acecfa3ada7b13eb55fa03b08df9e74 (patch)
treedf8e5f0ed0589b16767ad5fefdbbd01f0251cabd /drivers/base
parentf5d1499ae2096d7ea301023c4cc54e427300eb0a (diff)
downloadlinux-e48802333acecfa3ada7b13eb55fa03b08df9e74.tar.xz
PM: wakeup: remove redundant assignment to variable retval
The variable retval 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> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/base')
-rw-r--r--drivers/base/power/wakeup_stats.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/base/power/wakeup_stats.c b/drivers/base/power/wakeup_stats.c
index 5ade7539ac02..924fac493c4f 100644
--- a/drivers/base/power/wakeup_stats.c
+++ b/drivers/base/power/wakeup_stats.c
@@ -137,7 +137,7 @@ static struct device *wakeup_source_device_create(struct device *parent,
struct wakeup_source *ws)
{
struct device *dev = NULL;
- int retval = -ENODEV;
+ int retval;
dev = kzalloc(sizeof(*dev), GFP_KERNEL);
if (!dev) {