From mboxrd@z Thu Jan 1 00:00:00 1970 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 49481C25B75 for ; Wed, 15 May 2024 12:51:08 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 725406B0285; Wed, 15 May 2024 08:51:07 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 6D4FD6B0286; Wed, 15 May 2024 08:51:07 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 59C766B0289; Wed, 15 May 2024 08:51:07 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 3C8E46B0285 for ; Wed, 15 May 2024 08:51:07 -0400 (EDT) Received: from smtpin30.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id E0B1281588 for ; Wed, 15 May 2024 12:51:06 +0000 (UTC) X-FDA: 82120615332.30.6A8A93B Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf09.hostedemail.com (Postfix) with ESMTP id 296F7140029 for ; Wed, 15 May 2024 12:51:03 +0000 (UTC) Authentication-Results: imf09.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=NVcjqQbO; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf09.hostedemail.com: domain of pauld@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=pauld@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1715777464; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=0tRd5oikkwXvkBagrbVtw4/yuIwLwdR1d/3o6srHP1U=; b=syOmChz+swIyGS5vGZoY9TLPw6/e0u1v1EUimhaNEsolYarZ8VN56rBoiay4p0Y/FGsmFW hPtMB11ZwuWe4ZV+dPbLnZTRzrz222a9stZBYPhs7IWS9YUBko9qQraoWu0SqOcQMGO01N UQetvP8FjNXyx8s/F/uehx+FMw+/Ltc= ARC-Authentication-Results: i=1; imf09.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=NVcjqQbO; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf09.hostedemail.com: domain of pauld@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=pauld@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1715777464; a=rsa-sha256; cv=none; b=dMF32wFdNAcqEEHmbuvzBhK9ScPVcSu4gyR83idVgXmqMp2YM14BCgMFn9SKPsRgFFFnTg N+8/zJz6ejUWpDFqJ8wQ3TZEO36dIhgOgNaETcFGswtxa5cG9wnSqn9T2YgxFNQrWkjJSe FkVxVby3jBiLdCNjpDONxVbjKwXWPa4= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1715777463; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=0tRd5oikkwXvkBagrbVtw4/yuIwLwdR1d/3o6srHP1U=; b=NVcjqQbOjAITbSaUhYhZZcJS6dHDDQOJCXIvTvpjWHEY6A4rVrNM92QfPLYWv9Eg8K05bQ yYEmWYjJt9qDcdX+CQs7G/Synz0WiJ5wee0C6dRHCivEgZZ6IyRq2hRULzJqJXOhXWavkD taL91M10z4Z6K96RK0PQ3bwPCli0plc= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-659-POCGVL3zNPmxVDYqGTjeCg-1; Wed, 15 May 2024 08:50:59 -0400 X-MC-Unique: POCGVL3zNPmxVDYqGTjeCg-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 221AA101A52C; Wed, 15 May 2024 12:50:58 +0000 (UTC) Received: from lorien.usersys.redhat.com (unknown [10.39.194.32]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 806F2400059; Wed, 15 May 2024 12:50:52 +0000 (UTC) Date: Wed, 15 May 2024 08:50:49 -0400 From: Phil Auld To: Qais Yousef Cc: Peter Zijlstra , Ingo Molnar , Juri Lelli , Steven Rostedt , Vincent Guittot , Daniel Bristot de Oliveira , Thomas Gleixner , Sebastian Andrzej Siewior , Alexander Viro , Christian Brauner , Andrew Morton , Jens Axboe , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH] sched/rt: Clean up usage of rt_task() Message-ID: <20240515125049.GA29065@lorien.usersys.redhat.com> References: <20240514234112.792989-1-qyousef@layalina.io> <20240514235851.GA6845@lorien.usersys.redhat.com> <20240515083238.GA40213@noisy.programming.kicks-ass.net> <20240515112050.GA25724@lorien.usersys.redhat.com> <20240515120613.m6ajyxyyxhat7eb5@airbuntu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240515120613.m6ajyxyyxhat7eb5@airbuntu> X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.9 X-Rspamd-Queue-Id: 296F7140029 X-Stat-Signature: wxuoymmqssjqaufy45bofnurxy4o1fpy X-Rspam-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eTMGj+3GiUliMKgPdWLUcgz/RMaxfi1MZOnzbvoElzIgsjhj/guqHmtD3uOZ5u02BVQXaKMnI7OP6qgxeePQYaNlmZPgsp970aSk3Xhrq41jlERiAFz+gpliNK6qesACUYUSx4pNWhgX3DniDUAJNHvaFgD1Zk/ZDlzCDB2AHgRWcN8t6I= 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: List-Subscribe: List-Unsubscribe: On Wed, May 15, 2024 at 01:06:13PM +0100 Qais Yousef wrote: > On 05/15/24 07:20, Phil Auld wrote: > > On Wed, May 15, 2024 at 10:32:38AM +0200 Peter Zijlstra wrote: > > > On Tue, May 14, 2024 at 07:58:51PM -0400, Phil Auld wrote: > > > > > > > > Hi Qais, > > > > > > > > On Wed, May 15, 2024 at 12:41:12AM +0100 Qais Yousef wrote: > > > > > rt_task() checks if a task has RT priority. But depends on your > > > > > dictionary, this could mean it belongs to RT class, or is a 'realtime' > > > > > task, which includes RT and DL classes. > > > > > > > > > > Since this has caused some confusion already on discussion [1], it > > > > > seemed a clean up is due. > > > > > > > > > > I define the usage of rt_task() to be tasks that belong to RT class. > > > > > Make sure that it returns true only for RT class and audit the users and > > > > > replace them with the new realtime_task() which returns true for RT and > > > > > DL classes - the old behavior. Introduce similar realtime_prio() to > > > > > create similar distinction to rt_prio() and update the users. > > > > > > > > I think making the difference clear is good. However, I think rt_task() is > > > > a better name. We have dl_task() still. And rt tasks are things managed > > > > by rt.c, basically. Not realtime.c :) I know that doesn't work for deadline.c > > > > and dl_ but this change would be the reverse of that pattern. > > > > > > It's going to be a mess either way around, but I think rt_task() and > > > dl_task() being distinct is more sensible than the current overlap. > > > > > > > Yes, indeed. > > > > My point was just to call it rt_task() still. > > It is called rt_task() still. I just added a new realtime_task() to return true > for RT and DL. rt_task() will return true only for RT now. > > How do you see this should be done instead? I'm not seeing the problem. > Right, sorry. I misread your commit message completely and then all the places where you changed rt_task() to realtime_task() fit my misreading. rt_task() means rt class and realtime_task does what rt_task() used to do. That's how I would do it, too :) (Re) Reviewed-by: Phil Auld Cheers, Phil --