Files
android_kernel_fxtec_sm6115/kernel
Zhan Xusheng 49ec7d1192 alarmtimer: Fix argument order in alarm_timer_forward()
commit 5d16467ae56343b9205caedf85e3a131e0914ad8 upstream.

alarm_timer_forward() passes arguments to alarm_forward() in the wrong
order:

  alarm_forward(alarm, timr->it_interval, now);

However, alarm_forward() is defined as:

  u64 alarm_forward(struct alarm *alarm, ktime_t now, ktime_t interval);

and uses the second argument as the current time:

  delta = ktime_sub(now, alarm->node.expires);

Passing the interval as "now" results in incorrect delta computation,
which can lead to missed expirations or incorrect overrun accounting.

This issue has been present since the introduction of
alarm_timer_forward().

Fix this by swapping the arguments.

Fixes: e7561f1633 ("alarmtimer: Implement forward callback")
Signed-off-by: Zhan Xusheng <zhanxusheng@xiaomi.com>
Signed-off-by: Thomas Gleixner <tglx@kernel.org>
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20260323061130.29991-1-zhanxusheng@xiaomi.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ulrich Hecht <uli@kernel.org>
2026-05-07 10:55:21 +02:00
..
2025-12-22 04:34:09 +01:00
2025-04-04 11:11:29 +02:00
2019-12-13 08:51:11 +01:00
2023-12-20 15:38:01 +01:00
2025-07-17 10:08:05 +02:00
2026-05-07 10:55:14 +02:00
2021-02-10 09:21:06 +01:00
2020-03-25 08:06:13 +01:00
2024-11-08 16:19:12 +01:00
2021-02-07 14:48:38 +01:00
2020-01-09 10:18:59 +01:00