lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <87cy9pr4fc.ffs@tglx>
Date: Thu, 24 Jul 2025 17:31:35 +0200
From: Thomas Gleixner <tglx@...utronix.de>
To: syzbot <syzbot+e84a763987edd173d82f@...kaller.appspotmail.com>,
 anna-maria@...utronix.de, frederic@...nel.org,
 linux-kernel@...r.kernel.org, syzkaller-bugs@...glegroups.com
Cc: Alexander Potapenko <glider@...gle.com>, Marco Elver <elver@...gle.com>,
 Dmitry Vyukov <dvyukov@...gle.com>
Subject: Re: [syzbot] [kernel?] KMSAN: uninit-value in hrtimer_wakeup

On Thu, Jul 24 2025 at 03:44, syzbot wrote:
> HEAD commit:    bf61759db409 Merge tag 'sched_ext-for-6.16-rc6-fixes' of g..
> git tree:       upstream
> console output: https://syzkaller.appspot.com/x/log.txt?x=1693938c580000
> kernel config:  https://syzkaller.appspot.com/x/.config?x=5227c65742122bdd
> dashboard link: https://syzkaller.appspot.com/bug?extid=e84a763987edd173d82f
> compiler:       Debian clang version 20.1.7 (++20250616065708+6146a88f6049-1~exp1~20250616065826.132), Debian LLD 20.1.7
>
> Unfortunately, I don't have any reproducer for this issue yet.
>
> Downloadable assets:
> disk image: https://storage.googleapis.com/syzbot-assets/c9e297bb553f/disk-bf61759d.raw.xz
> vmlinux: https://storage.googleapis.com/syzbot-assets/7f2d1bf53414/vmlinux-bf61759d.xz
> kernel image: https://storage.googleapis.com/syzbot-assets/9a4f67426eab/bzImage-bf61759d.xz
>
> IMPORTANT: if you fix the issue, please add the following tag to the commit:
> Reported-by: syzbot+e84a763987edd173d82f@...kaller.appspotmail.com
>
> =====================================================
> BUG: KMSAN: uninit-value in hrtimer_wakeup+0xcb/0xd0 kernel/time/hrtimer.c:1997
>  hrtimer_wakeup+0xcb/0xd0 kernel/time/hrtimer.c:1997

...

> Local variable t created at:
>  hrtimer_nanosleep+0x48/0x480 kernel/time/hrtimer.c:2142
>  common_nsleep+0x118/0x160 kernel/time/posix-timers.c:1353

This makes absolutely no sense. hrtimer_nanosleep() initializes the
local variable

      struct hrtimer_sleeper t;

in two steps:

      hrtimer_setup_sleeper_on_stack(&t, clockid, mode);
      hrtimer_set_expires_range_ns(&t.timer, rqtp, current->timer_slack_ns);
      
and the complaint in hrtimer_wakeup() is:

 1989 static enum hrtimer_restart hrtimer_wakeup(struct hrtimer *timer)
 1990 {
 1991         struct hrtimer_sleeper *t =
 1992                 container_of(timer, struct hrtimer_sleeper, timer);
 1993         struct task_struct *task = t->task;
 1994 
 1995         t->task = NULL;
 1996         if (task)
 1997                 wake_up_process(task);    <---- here
 1998 
 1999         return HRTIMER_NORESTART;
 2000 }

t->task was initialized:

 2027 static void __hrtimer_setup_sleeper(struct hrtimer_sleeper *sl,
 2028                                     clockid_t clock_id, enum hrtimer_mode mode)
 2029 {
 ...
 2054         __hrtimer_setup(&sl->timer, hrtimer_wakeup, clock_id, mode);
 2055         sl->task = current;              <---- here
 2056 }

This code hasn't changed in a very long time. Looks like KMSAN is confused...


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ