From: Oleg Nesterov <oleg@redhat.com>
To: syzbot <syzbot+e3cf8f93cf86936710db@syzkaller.appspotmail.com>
Cc: axboe@kernel.dk, linux-kernel@vger.kernel.org,
peterz@infradead.org, syzkaller-bugs@googlegroups.com
Subject: Re: WARNING: ODEBUG bug in get_signal
Date: Thu, 27 Aug 2020 13:24:26 +0200 [thread overview]
Message-ID: <20200827112426.GE28468@redhat.com> (raw)
In-Reply-To: <00000000000068340d05add74c29@google.com>
On 08/27, syzbot wrote:
>
> __debug_check_no_obj_freed lib/debugobjects.c:967 [inline]
> debug_check_no_obj_freed+0x301/0x41c lib/debugobjects.c:998
> kmem_cache_free.part.0+0x16d/0x1f0 mm/slab.c:3692
> task_work_run+0xdd/0x190 kernel/task_work.c:141
I don't understand this trace, work->func(work) can call kmem_cache_free()
but task_work_run() doesn't do this.
In theory the patch below makes sense anyway, but I have no idea if it can
explain the problem.
Oleg.
--- x/kernel/task_work.c
+++ x/kernel/task_work.c
@@ -137,7 +137,7 @@ void task_work_run(void)
raw_spin_unlock_irq(&task->pi_lock);
do {
- next = work->next;
+ next = READ_ONCE(work->next);
work->func(work);
work = next;
cond_resched();
prev parent reply other threads:[~2020-08-27 15:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-27 7:58 WARNING: ODEBUG bug in get_signal syzbot
2020-08-27 11:14 ` syzbot
2020-08-27 11:24 ` Oleg Nesterov [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=20200827112426.GE28468@redhat.com \
--to=oleg@redhat.com \
--cc=axboe@kernel.dk \
--cc=linux-kernel@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=syzbot+e3cf8f93cf86936710db@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;
as well as URLs for NNTP newsgroup(s).