From nobody Fri Oct 2 06:18:53 2026 Received: from www262.sakura.ne.jp (www262.sakura.ne.jp [202.181.97.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BE46D469855 for ; Tue, 4 Aug 2026 13:53:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=202.181.97.72 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785851591; cv=none; b=h1f3m3QPNKIPdNZBW+fSHIoORqKXjpSq1v/UAs5Czfc06q2WMTjnWY2UCMkvgUNsqHyPbbxEGnMH16XPVH6bPViP2xnWB/DCX/fARXgvh4zEOik4hNyuaKfnruiaoqIYPxbrVjLHKPeatwKBsw44hcMnrAYhC8QTOgHRIEPaJZs= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785851591; c=relaxed/simple; bh=PwAXIKGkr+7SjX5A9YRcD1z0a7BXOd14biV/xdB0WUc=; h=Message-ID:Date:MIME-Version:From:Subject:To:Content-Type; b=hPaG+OJ5hz/QvzmDtHmdBrsmj759NL7QddlZhzoTCE/ZNS1P3hx8pC2GrsSGPQKuGDBM0cjgVGuOdCckBgeIvHiQmAlyViUgDw/tz63+u9ZHWlYFQRv+mIFUKnDL4i1DrXE44bZpUlOIpOPRqA42AlN3QUFLvIPsDvUSTr+XFJ0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=I-love.SAKURA.ne.jp; spf=pass smtp.mailfrom=I-love.SAKURA.ne.jp; arc=none smtp.client-ip=202.181.97.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=I-love.SAKURA.ne.jp Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=I-love.SAKURA.ne.jp Received: from www262.sakura.ne.jp (localhost [127.0.0.1]) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTP id 674DqL49035896; Tue, 4 Aug 2026 22:52:21 +0900 (JST) (envelope-from penguin-kernel@I-love.SAKURA.ne.jp) Received: from [192.168.1.6] (M106072072000.v4.enabler.ne.jp [106.72.72.0]) (authenticated bits=0) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTPSA id 674DqLFH035893 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NO); Tue, 4 Aug 2026 22:52:21 +0900 (JST) (envelope-from penguin-kernel@I-love.SAKURA.ne.jp) Message-ID: <76bb4c1c-5d85-4635-b3bb-fc06f292c59e@I-love.SAKURA.ne.jp> Date: Tue, 4 Aug 2026 22:52:19 +0900 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Tetsuo Handa Subject: [PATCH] printk: Don't WARN on kthread_run failure. To: Petr Mladek , Steven Rostedt , John Ogness , Sergey Senozhatsky , Thomas Gleixner , LKML Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Virus-Status: clean X-Anti-Virus-Server: fsav304.rs.sakura.ne.jp Content-Type: text/plain; charset="utf-8" Since __kthread_create_on_node() returns -EINTR upon SIGKILL, we should not use WARN_ON() in order to catch kthread_run() failure. Reported-by: syzbot+1ebbc20f223b99446034@syzkaller.appspotmail.com Closes: https://syzkaller.appspot.com/bug?extid=3D1ebbc20f223b99446034 Fixes: 5f53ca3ff83b ("printk: Implement legacy printer kthread for PREEMPT_= RT") Fixes: 76f258bf3f2a ("printk: nbcon: Introduce printer kthreads") Signed-off-by: Tetsuo Handa Reviewed-by: John Ogness Reviewed-by: Petr Mladek --- kernel/printk/nbcon.c | 2 +- kernel/printk/printk.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/printk/nbcon.c b/kernel/printk/nbcon.c index 4b03b019cd5e..a5921a84a80e 100644 --- a/kernel/printk/nbcon.c +++ b/kernel/printk/nbcon.c @@ -1382,7 +1382,7 @@ bool nbcon_kthread_create(struct console *con) return true; =20 kt =3D kthread_run(nbcon_kthread_func, con, "pr/%s%d", con->name, con->in= dex); - if (WARN_ON(IS_ERR(kt))) { + if (IS_ERR(kt)) { con_printk(KERN_ERR, con, "failed to start printing thread\n"); return false; } diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c index 2fe9a963c823..cf15ed75fd26 100644 --- a/kernel/printk/printk.c +++ b/kernel/printk/printk.c @@ -3725,7 +3725,7 @@ static bool legacy_kthread_create(void) lockdep_assert_console_list_lock_held(); =20 kt =3D kthread_run(legacy_kthread_func, NULL, "pr/legacy"); - if (WARN_ON(IS_ERR(kt))) { + if (IS_ERR(kt)) { pr_err("failed to start legacy printing thread\n"); return false; } --=20 2.52.0