mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-07-22 02:17:36 -04:00
Merge tag 'timers-urgent-2026-06-07' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull timer fixes from Ingo Molnar: - Fix the arch_inlined_clockevent_set_next_coupled() prototype in the !CONFIG_GENERIC_CLOCKEVENTS_MIN_ADJUST case (Naveen Kumar Chaudhary) - Fix an off-by-1 bug in the sys_settimeofday() usecs validation code (Naveen Kumar Chaudhary) - Mark vdso_k_*_data pointers as __ro_after_init (Thomas Weißschuh) - Fix livelock race in tmigr_handle_remote_up() (Amit Matityahu) * tag 'timers-urgent-2026-06-07' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: timers/migration: Fix livelock in tmigr_handle_remote_up() vdso/datastore: Mark vdso_k_*_data pointers as __ro_after_init time: Fix off-by-one in settimeofday() usec validation clockevents: Fix duplicate type specifier in stub function parameter
This commit is contained in:
@@ -301,7 +301,7 @@ static int clockevents_program_min_delta(struct clock_event_device *dev)
|
||||
#include <asm/clock_inlined.h>
|
||||
#else
|
||||
static __always_inline void
|
||||
arch_inlined_clockevent_set_next_coupled(u64 u64 cycles, struct clock_event_device *dev) { }
|
||||
arch_inlined_clockevent_set_next_coupled(u64 cycles, struct clock_event_device *dev) { }
|
||||
#endif
|
||||
|
||||
static inline bool clockevent_set_next_coupled(struct clock_event_device *dev, ktime_t expires)
|
||||
|
||||
@@ -207,7 +207,7 @@ SYSCALL_DEFINE2(settimeofday, struct __kernel_old_timeval __user *, tv,
|
||||
get_user(new_ts.tv_nsec, &tv->tv_usec))
|
||||
return -EFAULT;
|
||||
|
||||
if (new_ts.tv_nsec > USEC_PER_SEC || new_ts.tv_nsec < 0)
|
||||
if (new_ts.tv_nsec >= USEC_PER_SEC || new_ts.tv_nsec < 0)
|
||||
return -EINVAL;
|
||||
|
||||
new_ts.tv_nsec *= NSEC_PER_USEC;
|
||||
|
||||
@@ -978,8 +978,12 @@ static void tmigr_handle_remote_cpu(unsigned int cpu, u64 now,
|
||||
/* Drop the lock to allow the remote CPU to exit idle */
|
||||
raw_spin_unlock_irq(&tmc->lock);
|
||||
|
||||
if (cpu != smp_processor_id())
|
||||
timer_expire_remote(cpu);
|
||||
/*
|
||||
* This can't exclude the local CPU because jiffies might have advanced
|
||||
* after the timer softirq invoked run_timer_base(BASE_GLOBAL) and the
|
||||
* point where the jiffies snapshot @jif was taken in tmigr_handle_remote().
|
||||
*/
|
||||
timer_expire_remote(cpu);
|
||||
|
||||
/*
|
||||
* Lock ordering needs to be preserved - timer_base locks before tmigr
|
||||
|
||||
Reference in New Issue
Block a user