Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp5313380rwd; Mon, 12 Jun 2023 03:18:17 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5ymkaaLyQO8eAEDT7a+KjGZoELTbq+U740rkNY+54WioTj+CVx/NbgnQ2TQifscKIHexa5 X-Received: by 2002:a05:6a20:4424:b0:10f:92c6:9a3b with SMTP id ce36-20020a056a20442400b0010f92c69a3bmr9622465pzb.27.1686565097301; Mon, 12 Jun 2023 03:18:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686565097; cv=none; d=google.com; s=arc-20160816; b=0zfwUOB1IA8utt+za90HOJms0A6gIZ/ypAof2tZl0WUqTV7mWbeS2PgtgKXcJI1kBq cbDwD7ZW3EbQeTBTwGa52CDKbuYJkbD185PkEPGgRoOuVGrhswliKCGvvUrye9xHwuKc Ag9P0zTLAQMeyrdOPd1iBC50aMlWFZm8GAY2a81nAApwDcTWJK/w2YZewhtSH8WcEc2j EQR2U+GxlXvrkgwQVYNbaoOQHSbr9oIU9pXoFf9Hejr6DX+3RtfWidOHjTHHAWr0pL6y xCeSKSkpNMp+in12WuhWWXV4MLwrmdQE31w40gcbbw1Z4exqWAZXvFtpj0e/M35X9KWZ KJmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=IqfnVQT4jPUzu/K8Y246jwqGdHKTcUC1Qd80+JDzJ9s=; b=Ep/GnzPtBKbSnZzhiEntozorEISoJPeREmBYU7azDxpd0qmhOFzeoCb19yrgAyw6JN sqq2zxpoKnEEWPC1RUBRdPnCaoNxvLa4De/wr72XjWmqh5cHpnWwCLUJ4uSNM9OUwCmu 9oFDGrGOJ4/vSu2wDzATpuG5LcgJ40rRQGisJjqhzWooVDjxHiKlXh5AofUQ5nDVqjwa KP3LGlANpPDLW6RGvyhaBNqu2Rq3b+CQR8sueGl9OLmrwGVy3hTil9eD7veqsyfi2ldy zslmqjBW6Pp3DvjDyy+PkRoLQH19sczO+11UyZVQ71xyNJomswimM1OyBy23uu7W9tLC iMew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=vOQbT4kL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m125-20020a633f83000000b0052cad187979si4030615pga.147.2023.06.12.03.18.05; Mon, 12 Jun 2023 03:18:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=vOQbT4kL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231555AbjFLJmL (ORCPT + 99 others); Mon, 12 Jun 2023 05:42:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57424 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233203AbjFLJlo (ORCPT ); Mon, 12 Jun 2023 05:41:44 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9EA0A76BE; Mon, 12 Jun 2023 02:30:58 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 10B8862267; Mon, 12 Jun 2023 09:30:58 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2F8E9C433D2; Mon, 12 Jun 2023 09:30:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686562257; bh=WbY/B6Q3ozR2xTABptQ4x506EjsUcTEnB64Q34jdZiQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=vOQbT4kLz546JuZehBh0+qAAJZgNnPPPBqK45UaaUioMGRHkVAxcjAMVvvYCAwIXm 6QP8oIkTF/wOyGwh16+i09h5E/Q42cNy1PLWlF2dI/S8500ki6+iaFtxieLjz96r6J toL+iJCzDQxX3UlnowwCD28iFAoAZl+In8DMDhZxI32A7r3N85C6Rr9ST7ijdAI9Ww OGAgGRwUx/2tCG7H4aLyVYU+MNNLmuwvVXDDAuqzJ68O9JX6r3LkN38DjMQrGpHLuy BxC7ThbCcK1dwZKAMJiLOW/RJUS4LtRPTitsAX61SC7hOVKluhFcSfONGD6jZcjw9D uhUMcjlMy1LnA== Date: Mon, 12 Jun 2023 17:30:51 +0800 From: Zorro Lang To: "Eric W. Biederman" Cc: Linus Torvalds , Dave Chinner , "Darrick J. Wong" , Zorro Lang , linux-xfs@vger.kernel.org, Mike Christie , "Michael S. Tsirkin" , linux-kernel@vger.kernel.org Subject: Re: [6.5-rc5 regression] core dump hangs (was Re: [Bug report] fstests generic/051 (on xfs) hang on latest linux v6.5-rc5+) Message-ID: <20230612093051.c5tkj3jwitwehyxd@zlang-mailbox> References: <20230611124836.whfktwaumnefm5z5@zlang-mailbox> <20230612015145.GA11441@frogsfrogsfrogs> <87r0qhrrvr.fsf@email.froward.int.ebiederm.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87r0qhrrvr.fsf@email.froward.int.ebiederm.org> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 12, 2023 at 03:45:12AM -0500, Eric W. Biederman wrote: > Linus Torvalds writes: > > > On Sun, Jun 11, 2023 at 10:49 PM Dave Chinner wrote: > >> > >> On Sun, Jun 11, 2023 at 10:34:29PM -0700, Linus Torvalds wrote: > >> > > >> > So that "!=" should obviously have been a "==". > >> > >> Same as without the condition - all the fsstress tasks hang in > >> do_coredump(). > > > > Ok, that at least makes sense. Your "it made things worse" made me go > > "What?" until I noticed the stupid backwards test. > > > > I'm not seeing anything else that looks odd in that commit > > f9010dbdce91 ("fork, vhost: Use CLONE_THREAD to fix freezer/ps > > regression"). > > > > Let's see if somebody else goes "Ahh" when they wake up tomorrow... > > It feels like there have been about half a dozen bugs pointed out in > that version of the patch. I am going to have to sleep before I can get > as far as "Ahh" > > One thing that really stands out for me is. > > if (test_if_loop_should_continue) { > set_current_state(TASK_INTERRUPTIBLE); > schedule(); > } > > /* elsewhere */ > llist_add(...); > wake_up_process() > > So it is possible that the code can sleep indefinitely waiting for a > wake-up that has already come, because the order of set_current_state > and the test are in the wrong order. > > Unfortunately I don't see what would effect a coredump on a process that > does not trigger the vhost_worker code. > > > > About the only thing I can image is if io_uring is involved. Some of > the PF_IO_WORKER code was changed, and the test > "((t->flags & (PF_USER_WORKER | PF_IO_WORKER)) != PF_USER_WORKER)" > was sprinkled around. > > That is the only code outside of vhost specific code that was changed. > > > Is io_uring involved in the cases that hang? Oh, right, I involved io_uring into in fstests' fsstress.c, and I built kernel with CONFIG_IO_URING=y. If Darrick (said he didn't hit this issue) didn't enable io_uring, that might mean it's io_uring related. > > > Eric >