From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9864537754D for ; Thu, 5 Mar 2026 17:25:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772731525; cv=none; b=qCGrkM9ELeWP29IZquwx6lpkOWApUbg/lq7bsNPyeP/7LwH3iamZTzM9jwiWBlYHP2Cx9KpRA/7C5nFfE3e/umeasXPgF1X6sKsqzK/pyqZX5iml1y8lFxDkfKC/6/IYKapxxYcyBWAGIfL8BCxzJqIkCo6eb4idB+V2Ta/l+Cg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772731525; c=relaxed/simple; bh=zZ4G0235ZF/pe22pAkFZM13VdmyO2zIcEVgnuLOr+2A=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=LpU83AMmC3IauSYUxW4lBKvlyDZI+/XULdlmXOhmGr1s07JrwwHm285iPNRK5+Vel5Ih2h3yZBefPspZSwQ/0X5wH2mhPO1ZZctMRN1Myy7Ju4qXjdeI7Ab/6YZ7KIiCPI5BLbEIzFoSYXFc498YNi/znNhBCOlFO/DyqZV5yVQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=dpa+omYb; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="dpa+omYb" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 39345C19425 for ; Thu, 5 Mar 2026 17:25:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1772731525; bh=zZ4G0235ZF/pe22pAkFZM13VdmyO2zIcEVgnuLOr+2A=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=dpa+omYbL2SoVZLrPZ+8np54Cr8g/RjaHwDpMuVSjB2+2YmW2meJPalx3CztpdhdS RJULpJgKgl+Xw3NWKkRjd7k4suhhic7L8eDgusm77pTZBmfmZeXy8A6G3sRU/x4hU0 94YuQPCNuKiDBPYQz87w7zp2CZCtKM/+psbxZoScjFcnZfetGO//+gvR2pIgjh7SBH YGvBd7TYP78s3HURUdwsTik1rGtazcWxy87xXspqfNQ7ScMvBSHCHJ9po1I+qXd5dn auvAfkjZ17vCtNhd9y0OzI1Zsu8tqV0Fcn0j2w2hUxXgJzYPkojQxcyIQKlnu2NIQD 1RFXTpZvaxYFA== Received: by mail-qt1-f169.google.com with SMTP id d75a77b69052e-50335b926c2so76141081cf.2 for ; Thu, 05 Mar 2026 09:25:25 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCVjGJI4kO7D2aNWhwZVUddnW6yeCr4coNPjpnt50/3uIBCqDjYEeeQ0R/WaZxKR8PKftVoVZ7s1cTa4/n8=@vger.kernel.org X-Gm-Message-State: AOJu0YxbJiP8ZddN94tembJPCS9zWk/8Zuc0mW2iQlFdMvkp5ZXcqypB 4NXTzjqJVd13CvpC935jt6Z7FDrrb68oZZSPWO7Nb587QNjdaszyy6poKf+AZrgzIIYc/qwpr7j EsVXiMa8myYa3HxFrlPS1vn4HdF1dDPQ= X-Received: by 2002:a05:622a:130f:b0:4f4:de66:5901 with SMTP id d75a77b69052e-508f1ce585emr5848801cf.5.1772731524389; Thu, 05 Mar 2026 09:25:24 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20260305-wqstall_start-at-v2-0-b60863ee0899@debian.org> <20260305-wqstall_start-at-v2-5-b60863ee0899@debian.org> In-Reply-To: <20260305-wqstall_start-at-v2-5-b60863ee0899@debian.org> From: Song Liu Date: Thu, 5 Mar 2026 09:25:13 -0800 X-Gmail-Original-Message-ID: X-Gm-Features: AaiRm509JctOsskwVada8G7pyGAI3LPOWEOIdW-Okq6l-9PihECFS_SINdqTU4Q Message-ID: Subject: Re: [PATCH v2 5/5] workqueue: Add stall detector sample module To: Breno Leitao Cc: Tejun Heo , Lai Jiangshan , Andrew Morton , linux-kernel@vger.kernel.org, Omar Sandoval , Danielle Costantino , kasan-dev@googlegroups.com, Petr Mladek , kernel-team@meta.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Thu, Mar 5, 2026 at 8:16=E2=80=AFAM Breno Leitao wro= te: > > Add a sample module under samples/workqueue/stall_detector/ that > reproduces a workqueue stall caused by PF_WQ_WORKER misuse. The > module queues two work items on the same per-CPU pool, then clears > PF_WQ_WORKER and sleeps in wait_event_idle(), hiding from the > concurrency manager and stalling the second work item indefinitely. Clearing PF_WQ_WORKER is an interesting way to trigger the stall. > > This is useful for testing the workqueue watchdog stall diagnostics. > > Signed-off-by: Breno Leitao Acked-by: Song Liu > --- > samples/workqueue/stall_detector/Makefile | 1 + > samples/workqueue/stall_detector/wq_stall.c | 98 +++++++++++++++++++++++= ++++++ > 2 files changed, 99 insertions(+)