time: alarmtimer: remove unnecessary ‘0’ values from ret

Message ID 20230609182856.4660-1-zeming@nfschina.com
State New
Headers
Series time: alarmtimer: remove unnecessary ‘0’ values from ret |

Commit Message

Li zeming June 9, 2023, 6:28 p.m. UTC
  ret is assigned first, so it does not need to initialize the assignment.

Signed-off-by: Li zeming <zeming@nfschina.com>
---
 kernel/time/alarmtimer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c
index 65c20c4f0b7f..8d7ead245089 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;