Received: by 2002:ab2:710b:0:b0:1ef:a325:1205 with SMTP id z11csp1005744lql; Tue, 12 Mar 2024 05:00:44 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXgC9e/DZlMTQE54IaaURhxA0+jc4Y4zEK6w+ZN5Z2FSDnlrep8XIn9WpsYTxVSd0+49NrVgiz6I8BZe4SQ4cg7goquh9e2lSIeAnIHkQ== X-Google-Smtp-Source: AGHT+IGnOBRONkr8IHg1nK5LCfFoLT3xpnBWadYMBBO7Ne1AUZkl2yHg/MlB8LmD7UfHIm5FRQIy X-Received: by 2002:a05:6402:2267:b0:566:4aa9:7143 with SMTP id du7-20020a056402226700b005664aa97143mr150448edb.14.1710244844085; Tue, 12 Mar 2024 05:00:44 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710244844; cv=pass; d=google.com; s=arc-20160816; b=hf+9L2HMFseCqjbLa7H/pkhIIYNabm1wIbQlfuFRt8Ea61D47+gMTrqX02WzvgGVAI qGg7+g5HWCiM8M6T+uip6VMUdsr/BrylGJt33vR7KRqQNvATrrPqB/KRM0MCt5YKvx5Y 0dx6+y6gi0/P19MfAvdYEW6TDKrOnN5MVF4p6bFtPjKlUycdgQkixCKcFWQY4t5l0vX8 RddDAQ47HFQWSE5mCKmz2DitzYWIKR48/HyNu1LUXMI8yQusWtvCQS6JyjbfJMwof6QF r2xdMm7S0M38NMS9K/GBIyGTz0q6I8s9TOuHKanH+XSU6+JvqmoUYE2EFF6aFF5KCWXf DWlw== 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=zMtvvKeZc7giSCV1W6MW6IYY/wSgBtbI9oVH762vREY=; fh=t4l/6dU3pfnn7MYfnMazFZzgTmO0SkRDf37FwF3qJ8A=; b=tMYaPqQ3m7dzu6zzYhfiTtWXkzTnoTcqmKjinbX2irUD4wAdabOIKqPkNsef6VBdrP t95TR1z0hBazmfAb5ngC/fuZhGM7e1W09TrCAyNJrF9Jz6rODMyfadFboV4cwzCLNPpQ AujXWo+cZZYc0sculdhx284TCybJCLoPvFVrt7uUyQc+lCVCSDZ2ztSaIcuftK0aMSKJ O0sFg6QFdCDnBob0Vq5YP5QF7svOeCpQI5etW5UoElByIfDwzP0GtfC6S8SpnYOw+uDi kpASvYlWVQVuaV9d3JVxBe88y/cf+Ed5pnSu8AZgS5a5gFlY7e9rMmCv1exlMwMK07xO LKFg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=Ik00i3iG; 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-100203-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-100203-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. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id es19-20020a056402381300b00568562ecaa3si2163621edb.150.2024.03.12.05.00.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Mar 2024 05:00:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-100203-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=Ik00i3iG; 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-100203-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-100203-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 CC0FF1F226E8 for ; Tue, 12 Mar 2024 12:00:43 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C69FB7A13C; Tue, 12 Mar 2024 12:00:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="Ik00i3iG"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="MqA5L1Wu" 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 7FE9A79DBB; Tue, 12 Mar 2024 12:00:21 +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=1710244823; cv=none; b=qDkHmhQ4nqavYk9DxKkNsI6Hy9W1o4G0d/e4K8HvI9/ZYq4ShzDAF5zFXW+x9QiOtmAvQOT7D3UdS9z6Z8pKlUMEC42RrqLfZBXjWxL1CJm1RyEOw9iVsfEKSe6YR+2cx2BOZzT4kkZFCSF/qnwlQembzENTDQ4IBlyQMPWBbTU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710244823; c=relaxed/simple; bh=FK96rtOp3f2oT7fHvOHdFoWTeN1ZgxmZ/UprA8GS88E=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=svG/YFWxjt/lQ53ZRJ3ukDK/2XD/PnDHyriac/43q8Vi6mcXIuAejMJbiTSIkNS15ejdOiHbzncz9G2U7YlXezA8OgcnL8AqQk8lOJZut+lfcqJ1h0rbtZmdJnVAoNZBGkOsfrxWC07ZviR3A7047CiRN/lJ5xgRSooa6oH8WwM= 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=Ik00i3iG; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=MqA5L1Wu; 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: Tue, 12 Mar 2024 12:00:19 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1710244819; 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=zMtvvKeZc7giSCV1W6MW6IYY/wSgBtbI9oVH762vREY=; b=Ik00i3iGP0IjFPwYbUhr4YqKLObs4ZC9dFMUUmNWyTG9zIufSNcugcObq+AdHQGYn59Kml U528GowSqlzUJJzJaOqXIxyzlg/LtVrdaMc37x9mQyaVTpgDSHN4PAQ9xbsC/BK41d8o45 hlYI8DzspRkoIB0pJpXnJnKCWoQEyLu6rwIF+fBimKaSJ0bqY/LbjfmjFF3/xRorLZRj6Y 4MyYO4gwo5OTSG96kczijkAfUoVuOQDNRHEwvVzCSxkhDNpJSxR5c9jbXx8fDu2V8DbpRW FHDlJNv/o8gLWxYGsPctZIa/t1EXF2bIPln1i7TffvI6pemgEhsyDR5BtTzlFw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1710244819; 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=zMtvvKeZc7giSCV1W6MW6IYY/wSgBtbI9oVH762vREY=; b=MqA5L1WuUiY7Nid+V7fJ51aDbn8CfzgpWYXM9h6JXmEtrosqq2+NnOhG1S7v4oDu+xe42e T2Hxv+fPA5s9WbDQ== From: "tip-bot2 for Ingo Molnar" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: sched/core] sched/balancing: Rename find_idlest_group() => sched_balance_find_dst_group() Cc: Ingo Molnar , Shrikanth Hegde , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20240308111819.1101550-13-mingo@kernel.org> References: <20240308111819.1101550-13-mingo@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <171024481913.398.17633544271376353781.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/core branch of tip: Commit-ID: a88b17080294f735c4124acccfa2d803a6a7d46f Gitweb: https://git.kernel.org/tip/a88b17080294f735c4124acccfa2d803a6a7d46f Author: Ingo Molnar AuthorDate: Fri, 08 Mar 2024 12:18:18 +01:00 Committer: Ingo Molnar CommitterDate: Tue, 12 Mar 2024 12:00:00 +01:00 sched/balancing: Rename find_idlest_group() => sched_balance_find_dst_group() Standardize scheduler load-balancing function names on the sched_balance_() prefix. Also use 'dst' instead of 'idlest', because it's not really true that we return the 'idlest' group or CPU, we sort by idle-exit latency and only return the idlest CPUs from the lowest-latency set of CPUs. The true 'idlest' CPUs often remain idle for a long time and are never returned as long as the system is under-loaded. Signed-off-by: Ingo Molnar Reviewed-by: Shrikanth Hegde Link: https://lore.kernel.org/r/20240308111819.1101550-13-mingo@kernel.org --- kernel/sched/fair.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 02ff027..d0c3a09 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -7098,7 +7098,7 @@ static int wake_affine(struct sched_domain *sd, struct task_struct *p, } static struct sched_group * -find_idlest_group(struct sched_domain *sd, struct task_struct *p, int this_cpu); +sched_balance_find_dst_group(struct sched_domain *sd, struct task_struct *p, int this_cpu); /* * sched_balance_find_dst_group_cpu - find the idlest CPU among the CPUs in the group. @@ -7185,7 +7185,7 @@ static inline int find_idlest_cpu(struct sched_domain *sd, struct task_struct *p continue; } - group = find_idlest_group(sd, p, cpu); + group = sched_balance_find_dst_group(sd, p, cpu); if (!group) { sd = sd->child; continue; @@ -10296,13 +10296,13 @@ static bool update_pick_idlest(struct sched_group *idlest, } /* - * find_idlest_group() finds and returns the least busy CPU group within the + * sched_balance_find_dst_group() finds and returns the least busy CPU group within the * domain. * * Assumes p is allowed on at least one CPU in sd. */ static struct sched_group * -find_idlest_group(struct sched_domain *sd, struct task_struct *p, int this_cpu) +sched_balance_find_dst_group(struct sched_domain *sd, struct task_struct *p, int this_cpu) { struct sched_group *idlest = NULL, *local = NULL, *group = sd->groups; struct sg_lb_stats local_sgs, tmp_sgs;