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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 2 Jul 2021 09:13:20 -0400
From:   "Theodore Ts'o" <tytso@....edu>
To:     Guoqing Jiang <guoqing.jiang@...ux.dev>
Cc:     Sachin Sant <sachinp@...ux.vnet.ibm.com>,
        linux-ext4@...r.kernel.org, linux-fsdevel@...r.kernel.org,
        linuxppc-dev@...ts.ozlabs.org, yi.zhang@...wei.com, jack@...e.cz
Subject: Re: [powerpc][5.13.0-next-20210701] Kernel crash while running
 ltp(chdir01) tests

On Fri, Jul 02, 2021 at 05:38:10PM +0800, Guoqing Jiang wrote:
> 
> 
> I guess the problem is j_jh_shrink_count was destroyed in ext4_put_super _> 
> jbd2_journal_unregister_shrinker
> which is before the path ext4_put_super -> jbd2_journal_destroy ->
> jbd2_log_do_checkpoint to call
> percpu_counter_dec(&journal->j_jh_shrink_count).
> 
> And since jbd2_journal_unregister_shrinker is already called inside
> jbd2_journal_destroy, does it make sense
> to do this?
> 
> --- a/fs/ext4/super.c
> +++ b/fs/ext4/super.c
> @@ -1176,7 +1176,6 @@ static void ext4_put_super(struct super_block *sb)
>         ext4_unregister_sysfs(sb);
> 
>         if (sbi->s_journal) {
> -               jbd2_journal_unregister_shrinker(sbi->s_journal);
>                 aborted = is_journal_aborted(sbi->s_journal);
>                 err = jbd2_journal_destroy(sbi->s_journal);
>                 sbi->s_journal = NULL;

Good catch.  There's another place where we call
jbd2_journal_unregister_shrinker(), in the failure path for
ext4_fill_super().

					- Ted

P.S.  Whatever outgoing mailer you are using, it's not preserving TAB
characters correctly.  You might want to look into that before trying
to submit a patch.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ