Fix braino and move the lockdep assertion after put_super() otherwise we
risk a use-after-free.
Fixes: 2c18a63b760a ("super: wait until we passed kill super")
Reviewed-by: Jan Kara <jack@suse.cz>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Message-Id: <
20230828-vfs-super-fixes-v1-1-
b37a4a04a88f@kernel.org>
Signed-off-by: Christian Brauner <brauner@kernel.org>
return true;
}
wait_var_event(&sb->s_flags, wait_dead(sb));
- put_super(sb);
lockdep_assert_not_held(&sb->s_umount);
+ put_super(sb);
return false;
}