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] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 6 Jun 2022 16:29:19 -0700
From:   Roman Gushchin <roman.gushchin@...ux.dev>
To:     Andrew Morton <akpm@...ux-foundation.org>
Cc:     syzbot <syzbot+300d27c79fe6d4cbcc39@...kaller.appspotmail.com>,
        linux-kernel@...r.kernel.org, linux-mm@...ck.org,
        syzkaller-bugs@...glegroups.com
Subject: Re: [syzbot] WARNING in register_shrinker_prepared

On Mon, Jun 06, 2022 at 12:23:02PM -0700, Andrew Morton wrote:
> (cc Roman)
> 
> On Mon, 06 Jun 2022 10:17:34 -0700 syzbot <syzbot+300d27c79fe6d4cbcc39@...kaller.appspotmail.com> wrote:
> 
> > Hello,
> > 
> > syzbot found the following issue on:
> > 
> > HEAD commit:    1cfd968b58a1 Add linux-next specific files for 20220603
> > git tree:       linux-next
> > console+strace: https://syzkaller.appspot.com/x/log.txt?x=12f7b6b3f00000
> > kernel config:  https://syzkaller.appspot.com/x/.config?x=7da8386e3742814f
> > dashboard link: https://syzkaller.appspot.com/bug?extid=300d27c79fe6d4cbcc39
> > compiler:       gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2
> > syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=103e5177f00000
> > C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=13545057f00000
> > 
> > IMPORTANT: if you fix the issue, please add the following tag to the commit:
> > Reported-by: syzbot+300d27c79fe6d4cbcc39@...kaller.appspotmail.com
> > 
> > loop0: detected capacity change from 0 to 20
> > ------------[ cut here ]------------
> > WARNING: CPU: 0 PID: 3694 at mm/vmscan.c:681 register_shrinker_prepared+0x119/0x150 mm/vmscan.c:681
> 
> That's
> 
> 	WARN_ON_ONCE(shrinker_debugfs_add(shrinker));
> 
> I assume that debugfs_create_dir() failed.  Please see the NOTE: in
> that function's kerneldoc.


I agree and we really need to just ignore it.

If it happens because shrinker_debugfs is not initialized yet, there will be
a second chance. Otherwise we can't do much anyway.

Thank you!

--

diff --git a/mm/vmscan.c b/mm/vmscan.c
index fd8a472b6501..ab885561d3e5 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -682,7 +682,7 @@ void register_shrinker_prepared(struct shrinker *shrinker)
        down_write(&shrinker_rwsem);
        list_add_tail(&shrinker->list, &shrinker_list);
        shrinker->flags |= SHRINKER_REGISTERED;
-       WARN_ON_ONCE(shrinker_debugfs_add(shrinker));
+       shrinker_debugfs_add(shrinker);
        up_write(&shrinker_rwsem);
 }
 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ