From patchwork Mon Jul 3 09:47: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: 13299825 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 70116C04A6A for ; Mon, 3 Jul 2023 09:50:04 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id CFC6A8E00A8; Mon, 3 Jul 2023 05:49:51 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id CD6C58E00AB; Mon, 3 Jul 2023 05:49:51 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B25E48E00A8; Mon, 3 Jul 2023 05:49:51 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 9CDA68E00AB for ; Mon, 3 Jul 2023 05:49:51 -0400 (EDT) Received: from smtpin19.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 6BEA61C8780 for ; Mon, 3 Jul 2023 09:49:51 +0000 (UTC) X-FDA: 80969828982.19.04B8639 Received: from invmail4.hynix.com (exvmail4.skhynix.com [166.125.252.92]) by imf01.hostedemail.com (Postfix) with ESMTP id 72D0040006 for ; Mon, 3 Jul 2023 09:49:49 +0000 (UTC) Authentication-Results: imf01.hostedemail.com; dkim=none; spf=pass (imf01.hostedemail.com: domain of byungchul@sk.com designates 166.125.252.92 as permitted sender) smtp.mailfrom=byungchul@sk.com; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1688377789; 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=z7OkeT6xvSEqQwLdFXJGyxH34kbodoT4wnSvM20EAlw=; b=yfG9pvymF1pGSOdsS1UXmmLBPjyHG7DIL2tRxb9/vROPWWdGsfmhIXDjdSZDI0piJcMdxf NJtBveAKG/fj45HftB6HFCMwB9ipRtARgYF01g48E8X5hTDoNRHCy04tYzuUsexeF/qTGj HCD/dYqrLcRWh+2TJs4WEXXjkNSbGss= ARC-Authentication-Results: i=1; imf01.hostedemail.com; dkim=none; spf=pass (imf01.hostedemail.com: domain of byungchul@sk.com designates 166.125.252.92 as permitted sender) smtp.mailfrom=byungchul@sk.com; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1688377789; a=rsa-sha256; cv=none; b=gR1q+OeezVusFpP3gLMna0yQNZWDvFWz5gPQGgKynmdxQtjWD0zxQVvk8/liBjksjTr1JE 1v/fRsG3NIk5qFwIZt2VQmCGdWDT6lS/aPiGMIZpP2Vdueimdch1QPl9OHdAtIYfyy92Eu gWaQXle+jR2mvWRpU2tVfMtiLRXcY1M= X-AuditID: a67dfc5b-d85ff70000001748-86-64a299b34ffc From: Byungchul Park To: linux-kernel@vger.kernel.org Cc: kernel_team@skhynix.com, 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, 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, max.byungchul.park@gmail.com, boqun.feng@gmail.com, longman@redhat.com, hdanton@sina.com, her0gyugyu@gmail.com Subject: [PATCH v10 rebased on v6.4 11/25] dept: Apply sdt_might_sleep_{start,end}() to hashed-waitqueue wait Date: Mon, 3 Jul 2023 18:47:38 +0900 Message-Id: <20230703094752.79269-12-byungchul@sk.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20230703094752.79269-1-byungchul@sk.com> References: <20230703094752.79269-1-byungchul@sk.com> X-Brightmail-Tracker: H4sIAAAAAAAAAzWSfUzMcRzHfb+/x05nvx2bH23YbcbymInPDMsf1s9Dxox5+IOb+9FxXbn0 aKaUpEe15fSA6+LcuvN0h4mylFKUosahjlooelrczbmKK/XPZ6+9P+/Pe+8/Piwhe0TNZlWa E6JWo1DLaQkp6fM1LLHlG5TLe/PmQU7GcnD+SiWh6LaFhuZbZgSWe4kYemqC4Z2rF4GnsYkA XV4zguKOdgLu1ToQVJjO0NDSNQ1anQM01Oel05BUcpuG1z+GMbRdzMVgtobAywsGDJXubyTo emgo1CVh7+jG4DaWMmBMmA+dpgIGhjsCoN7xloKKD4sg/0obDeUV9STUPuzE0PKoiAaH5S8F L2vrSGjOyaTgZr+Bhh8uIwFG5wADbyr1GO4ke4NSfo5S8DyzEkPKtbsYWt8/RvAk9TMGq+Ut DdXOXgw2ax4Bf27UIOjM6mPgbIabgcLELATpZy+S0DTynILktkDw/C6ig9YI1b0DhJBs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MtomL/2GMFgyRgHeefmOLiUVYLgbN4FBro/tLGQ2x8LodlK /H0caR6doEmu4zhxzlQzpN0ikrsX/RzJffiCI9V2I3HYNpCrD0YoUjMZZIm9thAT+2QpR4rG eiky3tXFkSflIYYM9Zqpvat/k8WrpRRNmqTfsjNRlvTab2J1Pv7Eh5a7XCby4SIUwYvCt2L3 m3l2kbGwXvT55uhFjhTWiI7i4bCX8bRwZploe9e5dLBCSBWLsvKXQoywTiwsH1/ycmGb+DFo 4v4r/Uqsu+VaykSE/avZErTICiFW7K8I4PNIVo0+q0WRGm1aqkqTErvZkJyUrtWc2HzwSKod hZ/GmrFguoOmvbuakMAj5XK571SNWsGq0gzpqU1I5GllpDxn4IpaIVer0k9K+iMH9MYUydCE VvGM8gv57l+lRIVwSHVMSpYknaT/f0vxEVGZqCUUlefVbNSFGnTlv3zXZVtLjiZ4HGXb9s3/ 8fRQQkys5Sd/jNEvvHL9/U3L6ss/Ru6HtTHtiTr51+4+o9BTWJo1tcO5s3Py9309a4ZGdw+b Gz3t3tuWwS+r1KGMlXkDZriS3TDb98MN7fbh+GijdnnGHr4jeSLjr5OnA21Few/LlIwhSbV1 A603qP4FQqFgYTADAAA= X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: 72D0040006 X-Rspam-User: X-Stat-Signature: 7wh5nq5edegdc8b7oucfde8qyhsmjhmq X-Rspamd-Server: rspam01 X-HE-Tag: 1688377789-357281 X-HE-Meta: U2FsdGVkX1/rY/+stlW/AITQXbemYDFsl7SXhTOlhRCGsW05i2rzOUJYzLc8wNwzcrT6QGoNcOk/qxBosFEuCsFJi8643EhdaU4bX9bUkcai12p6jYHVyn2xaNRYIizTJbFgaWWjKenCeNRJ/AhofxYeumgi9f2R1Har1MY0pEV4BoNFKdN9XQoWBDiKUOZxKVnfBTTObsJqeVSBWI1EDCHb75TOzG2DYWw27Bz3F4fcnqA2vuEg6UV1aVwDYNmgIMrySxQPDEwvIUO9IGVSTUWhhwEF9O0oc1yU60+nznl+2B+PYypbAEKt08GMhL+LAHconRDxDfdI1Jx8sYsZLjjF5SIN0t7JJhdIsqWJfLxZxFV+8Eu0/px5hvXFWflyMvY54la3ReEQ1Rk17oLAwWmXBTD9ayfd4o2UL5dogdqD4FS6IHu9dn8vW8OeGJtRuBz7C09LBj+WRQnjP6eQFacirROBGgKuoLvAUIuYw5Ws4gshkj+OR8iR9C8vSaElH5q7/eJuKEZagFYaXTMzcnQqrZu+Io8CKRgYTaOkeOK+0KOujMB/3xhSJRLs4MHHl9v3nyGZHtTvD4j3rJ8RAF7sFGJCM6qLTybh603WLgZ37zyIDJ24PvqdOgelmAwsdXtYwihrP6B1GhRPSzBtddcsfBT2lfjp7WA3uAip3r+OlkPPpiGbxFQuqsSXh5MkPPnSfP2LBFORKoExtVeKx6zqsGRfmDoTrant6N3I0JsHJhurSnECFU5Vfl8V/6uyRJwOfuKCoM6VhZORVJxhtEMFBNq7Cmx4eTyWVdK5QMZLo4Nab5hkMPvvvgcivtDJgYPQXdCPwFqS2LVJJVAldaklruq+kqCtcVwIP2iHqw0hJ6nD2y3ETB5taf1SWy3bW+wO/fNuJ2Qhj9BGYfpkhONVyOa/1Kf8LT60c/yXVw4iriya6cSPOD5FfD03KWFWtSh2fJVYo8hGLDqkLuu bDGngqi9 qa1jy5uScxGgka9zC6/Vz+5GmCaWg4zJQU1C5GfT9FEw7B521JR1EeDO870L70gUmhjEFlTGGJl6zkQnkNywN5O34+1A0DNyo45PT4Vf44AtKZIU= 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 hashed-waitqueue waits. Signed-off-by: Byungchul Park --- include/linux/wait_bit.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/wait_bit.h b/include/linux/wait_bit.h index 7725b7579b78..fe89282c3e96 100644 --- a/include/linux/wait_bit.h +++ b/include/linux/wait_bit.h @@ -6,6 +6,7 @@ * Linux wait-bit related types and methods: */ #include +#include struct wait_bit_key { void *flags; @@ -246,6 +247,7 @@ extern wait_queue_head_t *__var_waitqueue(void *p); struct wait_bit_queue_entry __wbq_entry; \ long __ret = ret; /* explicit shadow */ \ \ + sdt_might_sleep_start(NULL); \ init_wait_var_entry(&__wbq_entry, var, \ exclusive ? WQ_FLAG_EXCLUSIVE : 0); \ for (;;) { \ @@ -263,6 +265,7 @@ extern wait_queue_head_t *__var_waitqueue(void *p); cmd; \ } \ finish_wait(__wq_head, &__wbq_entry.wq_entry); \ + sdt_might_sleep_end(); \ __out: __ret; \ })