Message ID | 20240124115938.80132-16-byungchul@sk.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> 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 1E7BFC47DDF for <linux-mm@archiver.kernel.org>; Wed, 24 Jan 2024 12:00:45 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7CD018D0008; Wed, 24 Jan 2024 07:00:06 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 755328D0007; Wed, 24 Jan 2024 07:00:06 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 557F98D0008; Wed, 24 Jan 2024 07:00:06 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 42E318D0007 for <linux-mm@kvack.org>; Wed, 24 Jan 2024 07:00:06 -0500 (EST) Received: from smtpin28.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 000F9A1491 for <linux-mm@kvack.org>; Wed, 24 Jan 2024 12:00:05 +0000 (UTC) X-FDA: 81714061170.28.6D2B338 Received: from invmail4.hynix.com (exvmail4.hynix.com [166.125.252.92]) by imf27.hostedemail.com (Postfix) with ESMTP id F39C34001C for <linux-mm@kvack.org>; Wed, 24 Jan 2024 12:00:03 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=none; spf=pass (imf27.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=1706097604; 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=Z1Mu9mItqFFRxmNTCfIHg3Vgo+jSXM2iK+TaQ7EDB/s=; b=eQ0AEWXpL7k/0HYGJWqQopZ/L0HMwCtrrpyP6cfOjUZUyQJSFr9uOzYeLU97tg1i+dmust 78v1ZCHKAgTIHudIw2EslcqFcw4Oo60xUGw9dPv9N/4Z9biEJYOgTQ7AIj6mjvJumYDo8x lvFKCLhlgbahoH52cCgTP70l1mzXX6w= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=none; spf=pass (imf27.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=1706097604; a=rsa-sha256; cv=none; b=wa5UpC/VyZnsz8pAaTzeLvvkvTqfsyvdevflQKSe48Qk2tlBpvCm2g1qbKlpVP8npZptKb ssZA+1yWI5KFDHHocwYCuYo62QMceHEkwZD7Q3Y4JFONYP5U4DSb+RixmaRVnPj3VRSRaU fMOkc+A6fd+bcBoP5mn22HWtS2DksLE= X-AuditID: a67dfc5b-d85ff70000001748-35-65b0fbb6fc5a From: Byungchul Park <byungchul@sk.com> 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 v11 15/26] dept: Apply sdt_might_sleep_{start,end}() to dma fence wait Date: Wed, 24 Jan 2024 20:59:26 +0900 Message-Id: <20240124115938.80132-16-byungchul@sk.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20240124115938.80132-1-byungchul@sk.com> References: <20240124115938.80132-1-byungchul@sk.com> X-Brightmail-Tracker: H4sIAAAAAAAAAzXSW1BMcRwHcP9zb7XmzLqdynXNjpmMyxrMT2PIA04PGoZB9cCODrujFhvV MlHaqFW5TUU3tbLWlsouKaxJphKVpYZsabRTdI/YRheXlvHym8/8Lt+nH4NLKkhvRqU+JmjU ijApJSJEA575S8vGS4UVjTo/uJS8AlzfEwnILimiwF5ciKDoXhwGPdVb4N1IP4Lxhlc4ZKTZ EeR3fMDhXk07ApvpDAVNndOg2TVEQV3aeQrib5RQ8LpvAoO29MsYFFq2wsuLBgwqRz8TkNFD QVZGPDZZujEYNZppMMbKwGnKpGGiQw517W9JsDmWwLXcNgoe2+oIqCl3YtD0MJuC9qLfJLys eU6A/VIKCXcGDRT0jRhxMLqGaHhTmYdBqW4y6Oy3XyTUplRicLbgLgbN7x8heJL4EQNL0VsK nrn6MbBa0nAYu1WNwJk6QENC8igNWXGpCM4npBPw6mctCbq21TD+I5vy9+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QUO1ygGlfZcHH7eaUQwmDlGg+6ym4aClEwEl3RXCXjubSYhrS8EPD8KqfBNvGPUifNp lSf52ikjwbcVc/zj6+9oPq2ul+aN9kS+0hzAl9QMY/yt7y6St1suUrz9ew7NG8a6MX68o4Pm W655CP5Ddx62a8lBSWikqFJqRfXasAhJdObbDnQiRXrKXkQno48SA/JhOHY9V9yow2dNsau4 nh73X8vZ5VxlxifSgCQMzl6Yy5m/PqMMiGEWsPs488ie2RuCXcmVfmujZy1lN3BO1xf8X+cy zlpR/9c+M/t7+b3ErGVsCDdguUJnIYkRzbEguTJOGysoVSFBmpjopDjlqaCj8bF2NPMyprPT 2Y/QZNe2BsQySOErDbeUizJS0GqSYhsQx+AKubRnUZkok0YKSadFdfwRdaJK1DSgxQyhWCjd vl+MkLFRQoIYI4onRPX/FGN8/JLR/MNLI6u8+bvu6ir2/YzCgw9vVYX2h7qE8pGevf7Hgs+c G9dD1UWnPP7axv0Td7mh12FX3Hpv5u1Jw0S7XKJvPzdQV/3DI+R4OzYbDVmDhzYEhhWRCdXp q7V94Vbf7BV+x72yjT5hrjm7n24pPeKwObRj/gfGEsmhqtK3D/18JxWEJlpYF4CrNcIfhViG ai4DAAA= X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: F39C34001C X-Rspam-User: X-Stat-Signature: paqx6inrz4bgchqcxszdp8y7x7yareck X-Rspamd-Server: rspam01 X-HE-Tag: 1706097603-84999 X-HE-Meta: U2FsdGVkX19TfmHIxL4pR3caoDtF+q9abK0NU//4RqcEwyTbr8B/ea9a2uQsKvgYmkzUxjlzwHB8IWacCg3LHPHXNvCEAUKFtt5RauprwZqWh/zlQOokZi+hYKK3P5zK9UIoBFszVtffT2LWeJmWrKtJ27u0er8nFqp7rsRZZH3RGkgB3lN05O7+ox3NtbxII3/9v31rBKX17R6QiTUFFHzpal4lMDlW1wYqhY+OUJDXHh5UIWANKMKp3fyi26uFJqGk6J5k5iSuykGxQjHyOuBMzGSS6jei0v9iShD9m1cDo94PoJFRuuNZPJ9PMQCUXl+qn4fcM3tjNPfXPb9XclvoRxGwj8fQsFzvI22quOMR6hAyM8MR+w2eizv4dNABSVBAxxhYnPRxEnfCXCgvNM62ATOcD0RsmepOLgCayYTlEXt+3f8v06VCyf4LnXhBJYIoPxVEQjM7k8rOdJHwHZs4g15SKjHymZOnyCuFaG3xeWsK8kzaKLbkfLMRthfJv0gFWuhsK3zMPrJrk0nw93f+8MjsJAr7FbCum/UjwRk56IhMVVCn2oTKhh1ZqCw4ImGEhWEeNzaXsC8WUi77PkrFrjLI8fjv+5PN/qgqrhZRsQlZn0ernve+tBxcNlzMYkZoNKXSyLMid/Z5u4i/KhKt8BHc3Kj3kRwwSH/gaYEZJ3hsaWVFmQPPa2qBCCvkwbZwXrvoohj6llTn+1q3reDwxqjeCZVohvqO8ySEAxajqsAsvQwAt9KA49qAF5nOSEpWWznEHfTY18+NS6HeskQvYFcJA4Cqpou5TFT7n3KvAMPw9yiPylJrvGLy3VpmIChBnJ3CsmEbmjesBVS+YkBQwdIOVlH+fTI+DRT2G6flOcH14NaRp/WeGGajH20K0coVETMheU1wAP+fqDGhIJ38QqQ4v+EQ5RzZWvZ7Os+cvvDiQFiDJu0s6KBisOJF6odCI/UjSYHlPT2+5ot F/iwqGM7 wWaJelOzljk5FabOqcJ7uUHHGbAV+mHQCYTECgijl/TSaF9AKjXdqLzgSa15q4my34W2DL77AmSCHG9V8g6e8thqB1h2H2IRrDdENXaiB9bSxJqoCSW4kKmC9x3ITl4tI/Pyep3rp2zDMWsK/AHiSvdWgPg== 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: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
DEPT(Dependency Tracker)
|
expand
|
diff --git a/drivers/dma-buf/dma-fence.c b/drivers/dma-buf/dma-fence.c index 8aa8f8cb7071..76dba11f0dab 100644 --- a/drivers/dma-buf/dma-fence.c +++ b/drivers/dma-buf/dma-fence.c @@ -16,6 +16,7 @@ #include <linux/dma-fence.h> #include <linux/sched/signal.h> #include <linux/seq_file.h> +#include <linux/dept_sdt.h> #define CREATE_TRACE_POINTS #include <trace/events/dma_fence.h> @@ -783,6 +784,7 @@ dma_fence_default_wait(struct dma_fence *fence, bool intr, signed long timeout) cb.task = current; list_add(&cb.base.node, &fence->cb_list); + sdt_might_sleep_start(NULL); while (!test_bit(DMA_FENCE_FLAG_SIGNALED_BIT, &fence->flags) && ret > 0) { if (intr) __set_current_state(TASK_INTERRUPTIBLE); @@ -796,6 +798,7 @@ dma_fence_default_wait(struct dma_fence *fence, bool intr, signed long timeout) if (ret > 0 && intr && signal_pending(current)) ret = -ERESTARTSYS; } + sdt_might_sleep_end(); if (!list_empty(&cb.base.node)) list_del(&cb.base.node); @@ -885,6 +888,7 @@ dma_fence_wait_any_timeout(struct dma_fence **fences, uint32_t count, } } + sdt_might_sleep_start(NULL); while (ret > 0) { if (intr) set_current_state(TASK_INTERRUPTIBLE); @@ -899,6 +903,7 @@ dma_fence_wait_any_timeout(struct dma_fence **fences, uint32_t count, if (ret > 0 && intr && signal_pending(current)) ret = -ERESTARTSYS; } + sdt_might_sleep_end(); __set_current_state(TASK_RUNNING);
Makes Dept able to track dma fence waits. Signed-off-by: Byungchul Park <byungchul@sk.com> --- drivers/dma-buf/dma-fence.c | 5 +++++ 1 file changed, 5 insertions(+)