summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorLi zeming <zeming@nfschina.com>2023-06-09 21:28:56 +0300
committerThomas Gleixner <tglx@linutronix.de>2023-06-18 23:41:53 +0300
commit986af8dc5af834071a8a7afdf2c3b7a57d562df2 (patch)
tree2824c2dd2b154ec434d37e4fd35cbfa2c33830ab /kernel
parentb9a40f24d8ea86f89f1299a3f2dccd601febe3e5 (diff)
downloadlinux-986af8dc5af834071a8a7afdf2c3b7a57d562df2.tar.xz
alarmtimer: Remove unnecessary initialization of variable 'ret'
ret is assigned before checked, so it does not need to initialize the variable Signed-off-by: Li zeming <zeming@nfschina.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/r/20230609182856.4660-1-zeming@nfschina.com
Diffstat (limited to 'kernel')
-rw-r--r--kernel/time/alarmtimer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c
index 82b28ab0f328..09c9cde06f20 100644
--- a/kernel/time/alarmtimer.c
+++ b/kernel/time/alarmtimer.c
@@ -847,7 +847,7 @@ static int alarm_timer_nsleep(const clockid_t which_clock, int flags,
struct restart_block *restart = &current->restart_block;
struct alarm alarm;
ktime_t exp;
- int ret = 0;
+ int ret;
if (!alarmtimer_get_rtcdev())
return -EOPNOTSUPP;