From patchwork Mon Jan 9 03:33:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Byungchul Park X-Patchwork-Id: 13092904 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8CCA4C5479D for ; Mon, 9 Jan 2023 03:34:24 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E9348900005; Sun, 8 Jan 2023 22:34:01 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 83799900004; Sun, 8 Jan 2023 22:34:01 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A0D40900002; Sun, 8 Jan 2023 22:34:00 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 27575900010 for ; Sun, 8 Jan 2023 22:33:58 -0500 (EST) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id ED445C032E for ; Mon, 9 Jan 2023 03:33:57 +0000 (UTC) X-FDA: 80333841714.10.0663C0B Received: from lgeamrelo11.lge.com (lgeamrelo12.lge.com [156.147.23.52]) by imf15.hostedemail.com (Postfix) with ESMTP id DCB22A000A for ; Mon, 9 Jan 2023 03:33:54 +0000 (UTC) Authentication-Results: imf15.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf15.hostedemail.com: domain of byungchul.park@lge.com designates 156.147.23.52 as permitted sender) smtp.mailfrom=byungchul.park@lge.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1673235235; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=QAnKx25EnCHzfO9e1nXHVYee4OzFWf1qOriQKe5vGDA=; b=iwAK3mPiu1IiKuEV1pPZh80igdnFbwPwlWHbc9nGBdBvHnX/PRG8pCoAOR51B3X1fMcfLB 9uLNUAVxAgY+tf7nzFNv+ohHGes8aQ6iJcqM7+/DuYxERkvJrFFsVe+FJaWgKxMDTMhAU3 9QIdmJRuHDXpEdDSpTPh1roCZHSDt2Y= ARC-Authentication-Results: i=1; imf15.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf15.hostedemail.com: domain of byungchul.park@lge.com designates 156.147.23.52 as permitted sender) smtp.mailfrom=byungchul.park@lge.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1673235235; a=rsa-sha256; cv=none; b=kxMeoeNIoQfj7Hc1fdKCYy3Dptwe4bf3uwdrhWamK6NYBRDw6RzC1HZ9/YkOPR5A22BWvY pQqTiMQMwP/B3eslwRylag3TDMjAQBrBKvRByy75w0rr8lwyW1qd0K/EFDJhI2VulUf5Py 5ZST6i4euUKigAKbPC/SPK6n7nVfKQo= Received: from unknown (HELO lgemrelse6q.lge.com) (156.147.1.121) by 156.147.23.52 with ESMTP; 9 Jan 2023 12:33:52 +0900 X-Original-SENDERIP: 156.147.1.121 X-Original-MAILFROM: byungchul.park@lge.com Received: from unknown (HELO localhost.localdomain) (10.177.244.38) by 156.147.1.121 with ESMTP; 9 Jan 2023 12:33:52 +0900 X-Original-SENDERIP: 10.177.244.38 X-Original-MAILFROM: byungchul.park@lge.com From: Byungchul Park To: linux-kernel@vger.kernel.org Cc: torvalds@linux-foundation.org, damien.lemoal@opensource.wdc.com, linux-ide@vger.kernel.org, adilger.kernel@dilger.ca, linux-ext4@vger.kernel.org, mingo@redhat.com, peterz@infradead.org, will@kernel.org, tglx@linutronix.de, rostedt@goodmis.org, joel@joelfernandes.org, sashal@kernel.org, daniel.vetter@ffwll.ch, duyuyang@gmail.com, johannes.berg@intel.com, tj@kernel.org, tytso@mit.edu, willy@infradead.org, david@fromorbit.com, amir73il@gmail.com, gregkh@linuxfoundation.org, kernel-team@lge.com, linux-mm@kvack.org, akpm@linux-foundation.org, mhocko@kernel.org, minchan@kernel.org, hannes@cmpxchg.org, vdavydov.dev@gmail.com, sj@kernel.org, jglisse@redhat.com, dennis@kernel.org, cl@linux.com, penberg@kernel.org, rientjes@google.com, vbabka@suse.cz, ngupta@vflare.org, linux-block@vger.kernel.org, paolo.valente@linaro.org, josef@toxicpanda.com, linux-fsdevel@vger.kernel.org, viro@zeniv.linux.org.uk, jack@suse.cz, jlayton@kernel.org, dan.j.williams@intel.com, hch@infradead.org, djwong@kernel.org, dri-devel@lists.freedesktop.org, rodrigosiqueiramelo@gmail.com, melissa.srw@gmail.com, hamohammed.sa@gmail.com, 42.hyeyoo@gmail.com, chris.p.wilson@intel.com, gwan-gyeong.mun@intel.com Subject: [PATCH RFC v7 10/23] dept: Apply sdt_might_sleep_weak() to waitqueue wait Date: Mon, 9 Jan 2023 12:33:38 +0900 Message-Id: <1673235231-30302-11-git-send-email-byungchul.park@lge.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1673235231-30302-1-git-send-email-byungchul.park@lge.com> References: <1673235231-30302-1-git-send-email-byungchul.park@lge.com> X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: DCB22A000A X-Stat-Signature: 6tzkz39ezsdkmso6oq4fjkggn4o9xagg X-Rspam-User: X-HE-Tag: 1673235234-530136 X-HE-Meta: U2FsdGVkX1/9Znc4TPNqOvH+Avg5OMpV1Bq4fpEv9U8E5C0KBYKKRjQpxkP8gRbGc8jiQ+9ZGuwttLB8sHPjiFAGolBDmhQsp5pS5bXaLHwqKHHnWeEOfSrPkGVvjgk4rJFcNI7TG7NbrDVtJE3NFg2oshlB/56GEVX2tjZt6AciozLhjvzhzWIjkUDBrIeT/GXWHoLn3fhw6MfmyH5iYYQQhtnML1F6uFZiuQWQmNeOtg/ccifh27znf9IaYj51DKzv2OiUKPmqsgFE5imvh0sbtZFpBQKWV09CH1fcg1DxvCeUm3PlNYSBBIjFIn/IJ6eRLKgw9mFo1Oo3JxyYn2KRZL4gsJ3Z1BdUmpOKFjtS5W5UCtA5QWHd9FMDjnmtJmaAnAKXmnTbmca0Uc0qQLrM5gS7prevbi1nNIbnga55aSQTemzm8m3+gTCKo8zR+GF0PVp7z9mu5MWnO6LAARz8wcaWaxtkNu1Xxy8jjXpMFzbcyxJLSVd0zYfQs1I3Odw1+1K7WvK9qHcVdoditBJI9G69Kl6GTDexFKl0If5JfbqCno4nV+rjehuxKzsfcbdsTzeUOznJn0s6H+iwDBOOT3CsM19dciLkGRAHoDwrW5CErE0adMZ1QZJ4QpgbKpKur/b1pUOoBljfy3el7K9NCCWJwwlBuz68PQf/PR3uFkz6yvYq+y4i9TCWz0WVkUwzThnojn2sbZArtq5acn/mF2ThMOeqtqCfRRk7BqoJTowFkT+CDeoh9DjzRmGO1ir1FuENyIXuLPvSE4/sr10RAri+J30QluEXovSD742dR/gUeZ8k5p8zxEcMwvTdykMFiIvW60nivDyV1kreVuL3luSUnxWEjjnRLoPMLeWdMye84IUah6vt5/NiECka X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Makes Dept able to track dependencies by waitqueue waits, but weakly. Signed-off-by: Byungchul Park --- include/linux/wait.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/wait.h b/include/linux/wait.h index a0307b5..ede466c 100644 --- a/include/linux/wait.h +++ b/include/linux/wait.h @@ -7,6 +7,7 @@ #include #include #include +#include #include #include @@ -303,6 +304,7 @@ static inline void wake_up_pollfree(struct wait_queue_head *wq_head) struct wait_queue_entry __wq_entry; \ long __ret = ret; /* explicit shadow */ \ \ + sdt_might_sleep_weak(NULL); \ init_wait_entry(&__wq_entry, exclusive ? WQ_FLAG_EXCLUSIVE : 0); \ for (;;) { \ long __int = prepare_to_wait_event(&wq_head, &__wq_entry, state);\ @@ -318,6 +320,7 @@ static inline void wake_up_pollfree(struct wait_queue_head *wq_head) cmd; \ } \ finish_wait(&wq_head, &__wq_entry); \ + sdt_might_sleep_finish(); \ __out: __ret; \ })