Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp785228lqo; Fri, 17 May 2024 01:07:24 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWqrJCsshViJJGT9GHJfACKdGtgHM2feATGWzIZznyZ6KTdAQI2Hcmn5Uc0BR9r7FpKsC8QcS1tHkaMfjmq/cPTnZBILzb2Km7GXhBgow== X-Google-Smtp-Source: AGHT+IEOPhc5pCkmqGHzVL3p3lbAIwU5RoyyVkp0E0Ab6zrmZ0vWvMYiavYwC7ii9pRV4juCu22b X-Received: by 2002:a50:d745:0:b0:56e:3774:749b with SMTP id 4fb4d7f45d1cf-5734d6dfeedmr12140590a12.42.1715933243079; Fri, 17 May 2024 01:07:23 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715933242; cv=pass; d=google.com; s=arc-20160816; b=1I/55jkSEa/fpwxn3VEfz3Oc3UWQZyiPnas0rf2zdbY6VdPAFb7/NIBnn04tSQfUN0 SRv9PU76P3qi3UxvzgX1RgULhWDaOZ4ThX/LMl2qlCBw+FOCuJRaUgypcNSQo0DnRs27 WfIGSDP9SeYTa+xXlC13+gA8hgdloJpJFA3+wzDLaIuIYi3vSGU9g/fzzeKztuz/ANJe sY1lkF9buhmF1mUwdH623wtCpVEe1E1lRoo6Msnr+ImehHsk042ZnqXCgxGRwitMW2X6 CiHoKOekY4N4Q+eTQeTDWQEs67c5A+iVMQtaa3iej/ruCDSLDK+5rxKivCjFYn5POQHy ll7g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:precedence:robot-unsubscribe:robot-id :message-id:mime-version:list-unsubscribe:list-subscribe:list-id :precedence:references:in-reply-to:cc:subject:to:reply-to:sender :from:dkim-signature:dkim-signature:date; bh=bfjV75NO9SZUF1uggmWNt6tuHqlxRKiRhZjsLp2Oy8c=; fh=e4EMVLXyz6bh+rJEZcoGAMHlRMQsv79Qh3iQLh/UeCM=; b=g+kyjkmaHs/NBMUCnurALRNXkS2O7kVKGvHGu+ugG/G9GPo5XYNMeKxli+7yChbyUB USc8WiYiG+AXSn1UhuJcQjU9+Ti7UO0+aJgk9cwKy0SpAkRdv1Fsmvzv0i6YluGcQa0i +HSKjyrnzlGkkKmyAuuLhU7dHryGBNpsuFjmCQb6ZhIU7AW6IvnZnOcRQx645waoSugQ hCZ18c460MYAKy8NfCQsyPZvrWScl5ORjZ9uUehtqjnQGfc1VsbLv4NtgQLvdto9Iu1X 0SM0OtHeGGB8qRRH/QBVUqs+BI3ucz75yXb2cbtCJwQSHInyA8uUV8en2j++Q+KDxMXo 02Ng==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=ZJLyqTjU; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-181855-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181855-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id 4fb4d7f45d1cf-5733c3287d4si9570590a12.418.2024.05.17.01.07.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 01:07:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-181855-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=ZJLyqTjU; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-181855-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181855-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 5B0B71F224E1 for ; Fri, 17 May 2024 08:07:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8B409364AB; Fri, 17 May 2024 08:06:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="ZJLyqTjU"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="Yo1/S+FT" Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4483328DB7; Fri, 17 May 2024 08:06:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715933176; cv=none; b=INE3PWSS+hJ2tue/K3RJqZLjBF3rJJ7G6WXJ0XM0A0fVlMoo+QRj0hz/9M/SH8U12mJCxG79lphzqMv1fsaiPCnIUyOa8zfl37Xwry9KGMR+JuXNBOWu1BawC+VDXrwDZNoliAIlbaPrTWn3mX70v3StED6thLMWwFQLWgODDMg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715933176; c=relaxed/simple; bh=I7vKyuuBa21buoq2JjLNZ10zt4Ov1stKHuENPHh67ec=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=PgeYPpKQQmKOlipQXZ86LLeSsZU9I49pI14jKeMX9dYChP54YIWrHexTuj7f1rIHNMLmGQSqRIULph3ySgnGTLIS7sXw6pBgmCC8Q9KCW/rU8dIs5lAzG5Ds6vntS28nReb9b8WgOCs40k0tdCVEbGqhbmCZPH71PLTMZjTX65I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=ZJLyqTjU; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=Yo1/S+FT; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Date: Fri, 17 May 2024 08:06:11 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1715933171; h=from:from:sender:sender:reply-to: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:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bfjV75NO9SZUF1uggmWNt6tuHqlxRKiRhZjsLp2Oy8c=; b=ZJLyqTjUAOGP+q9C0T355PG4hKWKv+W23F/CDGAvvKUwZCzpcSMOa6Tj4qFtXkAxLXcpe5 0fjXYW80YUIKawKIHTWGTbUVyuDvebItIXBQpmyaG3pP/0p2gaRYin1U4MHqNtwbcqt/7A oD2yot78xRQcN6GXTDGreH/GgUGCuAvSlWtp9w1qsizTCJcn6sfdf3LKHGehXufC8XWGlF EKyQUyMxOyqhHd2I1tq4o3LNvc2JZiQsbeZe4o/w9yTdXcZBD5Za6bzI2qRDDouHqoscxE jdgw6/IaRaj2t4+LcKzhk3XJ74WMuXkAoIALXF9QQ8J525+Of/0NfavrwT9xeQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1715933171; h=from:from:sender:sender:reply-to: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:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bfjV75NO9SZUF1uggmWNt6tuHqlxRKiRhZjsLp2Oy8c=; b=Yo1/S+FTeIV4A5EpbSXynjpmKMbyN5PGQo/GWwaYKeERVRi2234kxXo+riZ5Aj3YXwRGKZ TdSMqchlCgpUFODA== From: "tip-bot2 for Vitalii Bursov" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: sched/urgent] sched/fair: Allow disabling sched_balance_newidle with sched_relax_domain_level Cc: Vitalii Bursov , Ingo Molnar , Dietmar Eggemann , Vincent Guittot , Valentin Schneider , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <171593317134.10875.3767772724461271480.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit The following commit has been merged into the sched/urgent branch of tip: Commit-ID: a1fd0b9d751f840df23ef0e75b691fc00cfd4743 Gitweb: https://git.kernel.org/tip/a1fd0b9d751f840df23ef0e75b691fc00cfd4743 Author: Vitalii Bursov AuthorDate: Tue, 30 Apr 2024 18:05:23 +03:00 Committer: Ingo Molnar CommitterDate: Fri, 17 May 2024 09:48:24 +02:00 sched/fair: Allow disabling sched_balance_newidle with sched_relax_domain_level Change relax_domain_level checks so that it would be possible to include or exclude all domains from newidle balancing. This matches the behavior described in the documentation: -1 no request. use system default or follow request of others. 0 no search. 1 search siblings (hyperthreads in a core). "2" enables levels 0 and 1, level_max excludes the last (level_max) level, and level_max+1 includes all levels. Fixes: 1d3504fcf560 ("sched, cpuset: customize sched domains, core") Signed-off-by: Vitalii Bursov Signed-off-by: Ingo Molnar Tested-by: Dietmar Eggemann Reviewed-by: Vincent Guittot Reviewed-by: Valentin Schneider Link: https://lore.kernel.org/r/bd6de28e80073c79466ec6401cdeae78f0d4423d.1714488502.git.vitaly@bursov.com --- kernel/cgroup/cpuset.c | 2 +- kernel/sched/topology.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/cgroup/cpuset.c b/kernel/cgroup/cpuset.c index 4237c87..da24187 100644 --- a/kernel/cgroup/cpuset.c +++ b/kernel/cgroup/cpuset.c @@ -2948,7 +2948,7 @@ bool current_cpuset_is_being_rebound(void) static int update_relax_domain_level(struct cpuset *cs, s64 val) { #ifdef CONFIG_SMP - if (val < -1 || val >= sched_domain_level_max) + if (val < -1 || val > sched_domain_level_max + 1) return -EINVAL; #endif diff --git a/kernel/sched/topology.c b/kernel/sched/topology.c index 63aecd2..67a777b 100644 --- a/kernel/sched/topology.c +++ b/kernel/sched/topology.c @@ -1475,7 +1475,7 @@ static void set_domain_attribute(struct sched_domain *sd, } else request = attr->relax_domain_level; - if (sd->level > request) { + if (sd->level >= request) { /* Turn off idle balance on this domain: */ sd->flags &= ~(SD_BALANCE_WAKE|SD_BALANCE_NEWIDLE); }