The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Jiri Slaby <jirislaby@kernel.org>
To: syzbot <syzbot+1ebbc20f223b99446034@syzkaller.appspotmail.com>,
	gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org,
	linux-serial@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [serial?] WARNING in register_console
Date: Fri, 7 Aug 2026 08:45:50 +0200	[thread overview]
Message-ID: <c60f8248-dbba-4a87-ab29-ab6315a9932a@kernel.org> (raw)
In-Reply-To: <6a7411dd.9c11d2ce.289b96.0094.GAE@google.com>

On 06. 08. 26, 6:47, syzbot wrote:
> syzbot has found a reproducer for the following issue on:
> 
> HEAD commit:    0d8395707651 Merge tag 'soc-fixes-7.2-2' of git://git.kern..
> git tree:       upstream
> console output: https://syzkaller.appspot.com/x/log.txt?x=10883c99580000
> kernel config:  https://syzkaller.appspot.com/x/.config?x=cb17729fb04b1e3a
> dashboard link: https://syzkaller.appspot.com/bug?extid=1ebbc20f223b99446034
> compiler:       Debian clang version 22.1.8 (++20260613092233+e80beda6e255-1~exp1~20260613092250.77), Debian LLD 22.1.8
> syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=15b1bbb9580000
> 
> Downloadable assets:
> disk image: https://storage.googleapis.com/syzbot-assets/14b35ca281d5/disk-0d839570.raw.xz
> vmlinux: https://storage.googleapis.com/syzbot-assets/68c2ac2fdce0/vmlinux-0d839570.xz
> kernel image: https://storage.googleapis.com/syzbot-assets/29bdd737b48f/bzImage-0d839570.xz
> mounted in repro: https://storage.googleapis.com/syzbot-assets/cce97dbb2265/mount_0.gz
>    fsck result: failed (log: https://syzkaller.appspot.com/x/fsck.log?x=11da8e49580000)
> 
> IMPORTANT: if you fix the issue, please add the following tag to the commit:
> Reported-by: syzbot+1ebbc20f223b99446034@syzkaller.appspotmail.com
> 
> printk: legacy console [ttyS0] enabled
> ------------[ cut here ]------------
> IS_ERR(kt)

Well, the creation of "pr/legacy" thread failed. Would be nice to see 
what is actual PTR_ERR(kt).

> WARNING: kernel/printk/printk.c:3728 at legacy_kthread_create kernel/printk/printk.c:3728 [inline], CPU#0: syz.4.49/6392
> WARNING: kernel/printk/printk.c:3728 at printk_kthreads_check_locked+0x2a7/0x3f0 kernel/printk/printk.c:3802, CPU#0: syz.4.49/6392
> Modules linked in:
> CPU: 0 UID: 0 PID: 6392 Comm: syz.4.49 Not tainted syzkaller #0 PREEMPT_{RT,(full)}
> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
> RIP: 0010:legacy_kthread_create kernel/printk/printk.c:3728 [inline]
> RIP: 0010:printk_kthreads_check_locked+0x2a7/0x3f0 kernel/printk/printk.c:3802
> Code: fe c1 38 c1 7c 9a 4c 89 f7 e8 c5 85 8a 00 eb 90 e8 7e 12 21 00 eb 05 e8 77 12 21 00 b0 01 88 05 2f a4 08 18 e9 e2 00 00 00 90 <0f> 0b 90 48 c7 c7 80 bd 6d 8b e8 1a 9f 82 ff 48 8b 1d 93 9e 04 18
> RSP: 0018:ffffc9000509fa70 EFLAGS: 00010206
> RAX: fffffffffffffffc RBX: 0000000000000001 RCX: 10959546c0351c00
> RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
> RBP: ffffc9000509fb70 R08: ffff888032eb2daf R09: 1ffff110065d65b5
> R10: dffffc0000000000 R11: ffffed10065d65b6 R12: 0000000000000000
> R13: dffffc0000000000 R14: 1ffff92000a13f5c R15: dffffc0000000000
> FS:  00007f7f4a99d6c0(0000) GS:ffff888125c3e000(0000) knlGS:0000000000000000
> CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
> CR2: 00007fd99747f000 CR3: 000000003dd70000 CR4: 00000000003526f0
> Call Trace:
>   <TASK>
>   register_console+0xc19/0xfc0 kernel/printk/printk.c:4221
>   console_store+0x359/0x4f0 drivers/tty/serial/serial_core.c:2999

console_store() is serialized by a mutex. So this should not be a race. 
I cannot reproduce using:
while :; do
   echo 0 >/sys/class/tty/ttyS0/console
   echo 1 > /sys/class/tty/ttyS0/console
done

That's what the reproducer suggests is the cause.

thanks,
-- 
js
suse labs

      reply	other threads:[~2026-08-07  6:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-04  3:17 [syzbot] [serial?] WARNING in register_console syzbot
2026-08-06  4:47 ` syzbot
2026-08-07  6:45   ` Jiri Slaby [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c60f8248-dbba-4a87-ab29-ab6315a9932a@kernel.org \
    --to=jirislaby@kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=syzbot+1ebbc20f223b99446034@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox