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 lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B3729C7EE23 for ; Wed, 31 May 2023 13:41:37 +0000 (UTC) Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4QWVmH6PSCz3f8p for ; Wed, 31 May 2023 23:41:35 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=lM5Gf4c3; dkim-atps=neutral Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=kernel.org (client-ip=139.178.84.217; helo=dfw.source.kernel.org; envelope-from=sashal@kernel.org; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=lM5Gf4c3; dkim-atps=neutral Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4QWVm75Nq8z3cD5 for ; Wed, 31 May 2023 23:41:27 +1000 (AEST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 3026063B06; Wed, 31 May 2023 13:41:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BD8F6C4339B; Wed, 31 May 2023 13:41:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1685540483; bh=e6FiqSpPzrIqBr4ifo3Fy2T912kqqu+DYRXAE8MmA+A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lM5Gf4c3fJiYTFcu/4MvT6RW4g62v9bgno8RmTgrW+4oLsyJBesv7aN3Bwphb1ykH VpiRgMJFImfZJ4mhoLCHUDtLUk0fB2Juh+Tjp/sSvqK250B4yVHbm6k0lef8uOyolJ CPVW8hFcGY6GdyCc11Sx8h1BARpBkuBmTOKqhaBdjPFuRJs6SaW2rsaceMeky8OJCN xXqRS4W06nytudlUAqpyZ83x9b6GrLQMxPjUWC0qi0i2hwvZjRxODqk5Lh59cJ7q3i vgXU2067PyJJrRBiSoxMCzSBWK6/9V9ClpfKuXS9Rm3wmrQi6N2IXIac3g2ExwwASI 9Fldel0C6+TtA== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: [PATCH AUTOSEL 6.3 27/37] erofs: use HIPRI by default if per-cpu kthreads are enabled Date: Wed, 31 May 2023 09:40:09 -0400 Message-Id: <20230531134020.3383253-27-sashal@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230531134020.3383253-1-sashal@kernel.org> References: <20230531134020.3383253-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit X-BeenThere: linux-erofs@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development of Linux EROFS file system List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sasha Levin , Sandeep Dhavale , Yue Hu , Gao Xiang , linux-erofs@lists.ozlabs.org Errors-To: linux-erofs-bounces+linux-erofs=archiver.kernel.org@lists.ozlabs.org Sender: "Linux-erofs" From: Gao Xiang [ Upstream commit cf7f2732b4b83026842832e7e4e04bf862108ac2 ] As Sandeep shown [1], high priority RT per-cpu kthreads are typically helpful for Android scenarios to minimize the scheduling latencies. Switch EROFS_FS_PCPU_KTHREAD_HIPRI on by default if EROFS_FS_PCPU_KTHREAD is on since it's the typical use cases for EROFS_FS_PCPU_KTHREAD. Also clean up unneeded sched_set_normal(). [1] https://lore.kernel.org/r/CAB=BE-SBtO6vcoyLNA9F-9VaN5R0t3o_Zn+FW8GbO6wyUqFneQ@mail.gmail.com Reviewed-by: Yue Hu Reviewed-by: Sandeep Dhavale Reviewed-by: Chao Yu Signed-off-by: Gao Xiang Link: https://lore.kernel.org/r/20230522092141.124290-1-hsiangkao@linux.alibaba.com Signed-off-by: Sasha Levin --- fs/erofs/Kconfig | 1 + fs/erofs/zdata.c | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/fs/erofs/Kconfig b/fs/erofs/Kconfig index 704fb59577e09..f259d92c97207 100644 --- a/fs/erofs/Kconfig +++ b/fs/erofs/Kconfig @@ -121,6 +121,7 @@ config EROFS_FS_PCPU_KTHREAD config EROFS_FS_PCPU_KTHREAD_HIPRI bool "EROFS high priority per-CPU kthread workers" depends on EROFS_FS_ZIP && EROFS_FS_PCPU_KTHREAD + default y help This permits EROFS to configure per-CPU kthread workers to run at higher priority. diff --git a/fs/erofs/zdata.c b/fs/erofs/zdata.c index f1708c77a9912..d7add72a09437 100644 --- a/fs/erofs/zdata.c +++ b/fs/erofs/zdata.c @@ -369,8 +369,6 @@ static struct kthread_worker *erofs_init_percpu_worker(int cpu) return worker; if (IS_ENABLED(CONFIG_EROFS_FS_PCPU_KTHREAD_HIPRI)) sched_set_fifo_low(worker->task); - else - sched_set_normal(worker->task, 0); return worker; } -- 2.39.2