Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp219456pxu; Fri, 4 Dec 2020 01:19:17 -0800 (PST) X-Google-Smtp-Source: ABdhPJxosFvrNHG8RauBcoHc/ilXAgQEMtIYv8Qe+PRGOFEw/wXlbyuvyPYsXsxxqPZ6671KcZ/Z X-Received: by 2002:a17:906:268c:: with SMTP id t12mr6106650ejc.91.1607073557407; Fri, 04 Dec 2020 01:19:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607073557; cv=none; d=google.com; s=arc-20160816; b=DeE+4ZwROr19fyc5jl+/sQZuhFPxb3D1m6DTTw/xpCpF+mUgD/LA471TWRsWC+W33d 081z2zo8G2SWhsW7PArj4I4tWBwTd2EfBEuNHAn2EqMZL/CGZwtKHNnglh5e65yoXKox 70Z/RSLgFUZqDCWnNHU9coD42p2bP+CbFNwHXGa+QYVNnbwwFZPFABwDXlIR6r7bZ7Nb rqEJQ8AZtGHP7tactDS3128eSFhO3VdRJjblZSFSYEWtdidE0p3jQPSRa8Iedk4VTda7 bA7mNMkwR+9nVW9p4DUYpKGPVig/ghYNhFdp9aYnsRuLdMcNnWGqW9mBMMdnspvuVeXc gEog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :ironport-sdr:ironport-sdr; bh=iNo/i1Ed5XP2fnYvkbT15/JsVhM+ZdoP1WxhAMKn6jE=; b=LEzGqb4yJZMsdE3p+FQD6Kl4PU5v8WlrMNg8Fi6oNLbL0VRetxI4Ya/kKJ4Cw9bVRe jHyjK/KDZrcwfXZmlT2mFNQEJuRoZtdm7KGwECjfoc6ctJ0TEx9XyIWQkYiGCVh8DwF9 ZnZL3Ll1D/TO9O9yDiLsfPPt5SKzD0T8MZNSYULy/etckQKgbcd9L/izf79s2UkNSVc8 DkDyqfzdgg52oQTJvowig6+PzIUN9F1VElQrcN7O5DBQnGfUwd8K7jASUBafHjgl/7+m /e+TTM3yypgqW3nounOc6GFtp7BeW6hnloW9xKxQEOP6ExURWcqiM90HGPG/4vwBpklJ /i7g== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h14si3078450edl.381.2020.12.04.01.18.54; Fri, 04 Dec 2020 01:19:17 -0800 (PST) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387594AbgLDJQl (ORCPT + 99 others); Fri, 4 Dec 2020 04:16:41 -0500 Received: from mga04.intel.com ([192.55.52.120]:30529 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726056AbgLDJQl (ORCPT ); Fri, 4 Dec 2020 04:16:41 -0500 IronPort-SDR: Dt0TPe/VYFR7rWNtL0bBdbf0/f7I6gMbQwQciKIfYMaTTrZWO6iYy42ggQM63DPQ1rrNi0YgK7 5+y6R2CnkKMA== X-IronPort-AV: E=McAfee;i="6000,8403,9824"; a="170782858" X-IronPort-AV: E=Sophos;i="5.78,392,1599548400"; d="scan'208";a="170782858" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Dec 2020 01:15:55 -0800 IronPort-SDR: mr3ZlqUTIVb4q01Y8bYFcGc7DlSPk1NYe3aLoAsL1ACoNptIQJPUbeYEwco8ur2IdZ1BRjhMfs rCdQc26eTcwQ== X-IronPort-AV: E=Sophos;i="5.78,392,1599548400"; d="scan'208";a="550879507" Received: from unknown (HELO yhuang6-mobl1.ccr.corp.intel.com) ([10.254.212.254]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Dec 2020 01:15:51 -0800 From: Huang Ying To: Peter Zijlstra , Mel Gorman Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Huang Ying , "Matthew Wilcox (Oracle)" , Rafael Aquini , Andrew Morton , Ingo Molnar , Rik van Riel , Johannes Weiner , Dave Hansen , Andi Kleen , Michal Hocko , David Rientjes , linux-api@vger.kernel.org Subject: [PATCH -V7 2/3] NOT kernel/man2/set_mempolicy.2: Add mode flag MPOL_F_NUMA_BALANCING Date: Fri, 4 Dec 2020 17:15:33 +0800 Message-Id: <20201204091534.72239-3-ying.huang@intel.com> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201204091534.72239-1-ying.huang@intel.com> References: <20201204091534.72239-1-ying.huang@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: "Huang, Ying" --- man2/set_mempolicy.2 | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/man2/set_mempolicy.2 b/man2/set_mempolicy.2 index 68011eecb..fb2e6fd96 100644 --- a/man2/set_mempolicy.2 +++ b/man2/set_mempolicy.2 @@ -113,6 +113,15 @@ A nonempty .I nodemask specifies node IDs that are relative to the set of node IDs allowed by the process's current cpuset. +.TP +.BR MPOL_F_NUMA_BALANCING " (since Linux 5.11)" +When +.I mode +is MPOL_BIND, enable the Linux kernel NUMA balancing for the task if +it is supported by kernel. +If the flag isn't supported by Linux kernel, or is used with +.I mode +other than MPOL_BIND, return -1 and errno is set to EINVAL. .PP .I nodemask points to a bit mask of node IDs that contains up to @@ -293,6 +302,11 @@ argument specified both .B MPOL_F_STATIC_NODES and .BR MPOL_F_RELATIVE_NODES . +Or, the +.B MPOL_F_NUMA_BALANCING +isn't supported by the Linux kernel, or is used with +.I mode +other than MPOL_BIND. .TP .B ENOMEM Insufficient kernel memory was available. -- 2.29.2