linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: syzbot <syzbot+bb4c69145b4a52b40b27@syzkaller.appspotmail.com>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	syzkaller-bugs@googlegroups.com,
	Matthew Wilcox <willy@infradead.org>
Subject: Re: [syzbot] BUG: sleeping function called from invalid context in folio_copy
Date: Sun, 25 Jul 2021 22:18:34 -0700	[thread overview]
Message-ID: <20210725221834.35e077daff0005f3d78d08d7@linux-foundation.org> (raw)
In-Reply-To: <000000000000f84cad05c7ee4778@google.com>

(Cc Matthew)

(It might not be a folio thing at all - I haven't checked yet)

On Sun, 25 Jul 2021 01:18:27 -0700 syzbot <syzbot+bb4c69145b4a52b40b27@syzkaller.appspotmail.com> wrote:

> Hello,
> 
> syzbot found the following issue on:
> 
> HEAD commit:    b1347210b01d Add linux-next specific files for 20210721
> git tree:       linux-next
> console output: https://syzkaller.appspot.com/x/log.txt?x=1417aeca300000
> kernel config:  https://syzkaller.appspot.com/x/.config?x=86c6d14fadc3db60
> dashboard link: https://syzkaller.appspot.com/bug?extid=bb4c69145b4a52b40b27
> compiler:       gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.1
> syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=1202e6ca300000
> C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=12ca875a300000
> 
> IMPORTANT: if you fix the issue, please add the following tag to the commit:
> Reported-by: syzbot+bb4c69145b4a52b40b27@syzkaller.appspotmail.com
> 
> BUG: sleeping function called from invalid context at mm/util.c:761
> in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 1660, name: kcompactd0
> 1 lock held by kcompactd0/1660:
>  #0: ffff8880111a4f70 (&mapping->private_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:359 [inline]
>  #0: ffff8880111a4f70 (&mapping->private_lock){+.+.}-{2:2}, at: __buffer_migrate_page+0x3a8/0xa80 mm/migrate.c:722
> Preemption disabled at:
> [<0000000000000000>] 0x0
> CPU: 0 PID: 1660 Comm: kcompactd0 Not tainted 5.14.0-rc2-next-20210721-syzkaller #0
> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
> Call Trace:
>  __dump_stack lib/dump_stack.c:88 [inline]
>  dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:105
>  ___might_sleep.cold+0x1f3/0x239 kernel/sched/core.c:9182
>  folio_copy+0x10c/0x1a0 mm/util.c:761
>  folio_migrate_copy+0x19/0x30 mm/migrate.c:619
>  __buffer_migrate_page+0x820/0xa80 mm/migrate.c:757
>  move_to_new_page+0x339/0xf00 mm/migrate.c:904
>  __unmap_and_move mm/migrate.c:1069 [inline]
>  unmap_and_move mm/migrate.c:1210 [inline]
>  migrate_pages+0x2867/0x3890 mm/migrate.c:1487
>  compact_zone+0x1abb/0x3860 mm/compaction.c:2393
>  kcompactd_do_work+0x2c9/0x730 mm/compaction.c:2808
>  kcompactd+0x262/0xd10 mm/compaction.c:2903
>  kthread+0x3e5/0x4d0 kernel/kthread.c:319
>  ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
> BUG: sleeping function called from invalid context at mm/util.c:761
> in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 1660, name: kcompactd0
> 1 lock held by kcompactd0/1660:
>  #0: ffff8880111a4f70 (&mapping->private_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:359 [inline]
>  #0: ffff8880111a4f70 (&mapping->private_lock){+.+.}-{2:2}, at: __buffer_migrate_page+0x3a8/0xa80 mm/migrate.c:722
> Preemption disabled at:
> [<0000000000000000>] 0x0
> CPU: 0 PID: 1660 Comm: kcompactd0 Tainted: G        W         5.14.0-rc2-next-20210721-syzkaller #0
> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
> Call Trace:
>  __dump_stack lib/dump_stack.c:88 [inline]
>  dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:105
>  ___might_sleep.cold+0x1f3/0x239 kernel/sched/core.c:9182
>  folio_copy+0x10c/0x1a0 mm/util.c:761
>  folio_migrate_copy+0x19/0x30 mm/migrate.c:619
>  __buffer_migrate_page+0x820/0xa80 mm/migrate.c:757
>  move_to_new_page+0x339/0xf00 mm/migrate.c:904
>  __unmap_and_move mm/migrate.c:1069 [inline]
>  unmap_and_move mm/migrate.c:1210 [inline]
>  migrate_pages+0x2867/0x3890 mm/migrate.c:1487
>  compact_zone+0x1abb/0x3860 mm/compaction.c:2393
>  kcompactd_do_work+0x2c9/0x730 mm/compaction.c:2808
>  kcompactd+0x262/0xd10 mm/compaction.c:2903
>  kthread+0x3e5/0x4d0 kernel/kthread.c:319
>  ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
> 
> 
> ---
> This report is generated by a bot. It may contain errors.
> See https://goo.gl/tpsmEJ for more information about syzbot.
> syzbot engineers can be reached at syzkaller@googlegroups.com.
> 
> syzbot will keep track of this issue. See:
> https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
> syzbot can test patches for this issue, for details see:
> https://goo.gl/tpsmEJ#testing-patches

  reply	other threads:[~2021-07-26  5:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-25  8:18 [syzbot] BUG: sleeping function called from invalid context in folio_copy syzbot
2021-07-26  5:18 ` Andrew Morton [this message]
2021-07-26 12:45   ` Matthew Wilcox

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=20210725221834.35e077daff0005f3d78d08d7@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=syzbot+bb4c69145b4a52b40b27@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.com \
    --cc=willy@infradead.org \
    /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).