Received: by 2002:a05:6a10:d5a5:0:0:0:0 with SMTP id gn37csp3150807pxb; Sat, 9 Oct 2021 03:13:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx1tJwu9U9360yP1REv7mxKqGw1cYasKrO6wl5YtgkMAlBIcbLN+9xkUvWePh8nbFjSs8I9 X-Received: by 2002:a05:6402:1157:: with SMTP id g23mr23468228edw.379.1633774385899; Sat, 09 Oct 2021 03:13:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1633774385; cv=none; d=google.com; s=arc-20160816; b=HXIS1ODVmBa9CKRUNgH5EJU8HW+UIFirDwiJXCQ2AQxQ6ffnl03WqWj774uBrslKux qFBcZKxhzbwzyYn316265e8oMBrqULj2ziOETRDRhUI4jHDhK9huRg4MZSBKufp2FKtx rRk1cuvovJwDp4X8qB7TuzRsnBu6LXY9SzzscwKYjLgx/WiGcBvCIeRQz+GsXIacYB9Z HqQzE9RMjMzSESNwU2jH8bSmVHnnrNvG1zA1JeVDYGK8bWLBeSdIHtclDqFJ30pz5+4M yYKHuT83ar1BPj6JePhTLJTd6MRQRztND+u2vPtbr0uJeqYYnes5hWALkp39sBNIWySL aPpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=m54HmauTfJyDhMz+3BwljSv9nHwcDn58lgjMVccyOPA=; b=b5G0nqAeWve1NY4ScuK3Cro7cF3zKN7TGBUjUXsfbwaOYnXIC9vdLxzUEkzLFAHc8Y pn3JkxMxnUqL/KkDkKV/QSA13qi3v5AEV6u6Rp3yuP/st8u758hy2NBNsh3dEUdmWDP9 Uer20PH4pJNSHkf+l0Ty1KB61j7QM+rmqR3+TeXipbahq2p7jmLvzFQYbtyBCkccT160 50Tuer8rdI6oN5v9zr84DF1EaJRsgSKOvZ4TyFBlSM5N9zkV/vzHUiM/KJYSGvYeqdK1 pSprSqDniOxtkd6akuaKnh4MmuM2/s4rZhm4NB2tM/FkowWMWCqD6rY9/FRI3oHHpEZx XL/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=A0mS4dAK; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y14si2928666ejo.377.2021.10.09.03.12.41; Sat, 09 Oct 2021 03:13:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=A0mS4dAK; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244892AbhJIKKi (ORCPT + 99 others); Sat, 9 Oct 2021 06:10:38 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:49610 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244783AbhJIKJg (ORCPT ); Sat, 9 Oct 2021 06:09:36 -0400 Date: Sat, 09 Oct 2021 10:07:37 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1633774058; 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=m54HmauTfJyDhMz+3BwljSv9nHwcDn58lgjMVccyOPA=; b=A0mS4dAKZj7SOhSCQ2e5SyTXLh72ECYS4NSxFV73x3WwEJxfyVQ5BIEsHfJUs+nCqOG2xG cCU5hNC4wF7rkgheB+PjkWGPqa9NBYg7cP98lE20cESPcibZ3nf6DEWZ/SLj64QU6vPyCS /uetmzS0TzK7aRM4p0nCe8QDATfUCjB1MzszVjI8uGvFlDkMX9sLjw+yK+6wT2psWCvKt+ D1mp2lYtheZBD4NPKbiSuu7ZeQC8fEdE1lJo3Ez7yy9XcSIyRK3crtTgqETo2daZpPQErD kaCiyHsQgBlfsZtowrJHLB3gUrOzcaln45cdOzCi+fJPlrm0Su+07MXZs4KDug== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1633774058; 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=m54HmauTfJyDhMz+3BwljSv9nHwcDn58lgjMVccyOPA=; b=31PLFUN5SxDdP3i8tcwErXtw2T+lW3pAeqXEpv0qMQkdOSPhz9VFo3BT5hp0bZhn9zZuhq w+7IxiC5BJafMdBA== From: "tip-bot2 for Bharata B Rao" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: sched/core] sched/numa: Replace hard-coded number by a define in numa_task_group() Cc: Bharata B Rao , "Peter Zijlstra (Intel)" , Mel Gorman , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20211004105706.3669-2-bharata@amd.com> References: <20211004105706.3669-2-bharata@amd.com> MIME-Version: 1.0 Message-ID: <163377405761.25758.2274556193360842826.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the sched/core branch of tip: Commit-ID: b6153093de41186e2c534ffffb8ce81b1666b110 Gitweb: https://git.kernel.org/tip/b6153093de41186e2c534ffffb8ce81b1666b110 Author: Bharata B Rao AuthorDate: Mon, 04 Oct 2021 16:27:03 +05:30 Committer: Peter Zijlstra CommitterDate: Thu, 07 Oct 2021 13:51:16 +02:00 sched/numa: Replace hard-coded number by a define in numa_task_group() While allocating group fault stats, task_numa_group() is using a hard coded number 4. Replace this by NR_NUMA_HINT_FAULT_STATS. No functionality change in this commit. Signed-off-by: Bharata B Rao Signed-off-by: Peter Zijlstra (Intel) Acked-by: Mel Gorman Link: https://lkml.kernel.org/r/20211004105706.3669-2-bharata@amd.com --- kernel/sched/fair.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 2468d1d..fc0a0ed 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -2438,7 +2438,8 @@ static void task_numa_group(struct task_struct *p, int cpupid, int flags, if (unlikely(!deref_curr_numa_group(p))) { unsigned int size = sizeof(struct numa_group) + - 4*nr_node_ids*sizeof(unsigned long); + NR_NUMA_HINT_FAULT_STATS * + nr_node_ids * sizeof(unsigned long); grp = kzalloc(size, GFP_KERNEL | __GFP_NOWARN); if (!grp)