Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1009226rdb; Mon, 19 Feb 2024 00:46:48 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVYlG/z9DKM2io+HEAQUzJXcJdDXRuLmbEbuqpCwYVIzfBrxFVqtxaBl84xo2zxQ3qJf21cG2rx7p05B9TZ8Ueej4dzSsmyKQhWwup4QA== X-Google-Smtp-Source: AGHT+IFoZavxjxispjIZrJ6VWf++OCrvCxpoRDen4764FU7s435m7xdNvdUlYC8UdxmIB4YvoVHk X-Received: by 2002:a50:ec85:0:b0:564:1735:19d0 with SMTP id e5-20020a50ec85000000b00564173519d0mr5336557edr.1.1708332408703; Mon, 19 Feb 2024 00:46:48 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708332408; cv=pass; d=google.com; s=arc-20160816; b=SeatvpqcZO7h5KkNlYtZ1AwEG9Ew0lW7Z6yFWB3rdlB4TYrvE+nM0mc71GunRKql3E yxMMkritShzkqhKwtW1pXcu5FsWqu/1mbfYeBzSGJDb1gNBjRQVeIkw5Y5m9muqOCSbg kV49oJQnMCH9IxKlO75Im6TWXcw/F4pkyrVGDivIETbu2LT7Axuo/cAHcrFQPpcGCj+E wJtXSU9qmBkxpAYe4WtF4jTjwOl7HjRC0USs4FaGY+G5n5R/RAh41yOlItuOWGGUVHFw iz36Wg34PNki4OR6JtN6u8rC8b2vGpboG9P9MkV2rUp3mOfwulngU54Q0Z+MUs8t/wX+ kELA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :user-agent:message-id:date:references:in-reply-to:subject:cc:to :from:dkim-signature; bh=LK8OsKWuZ+RKTk1+LdvtuQA59BApktf6zpF7BXOZkJw=; fh=uOmlfVp8QCBOD+RYkKSqswXJq4ToUUsDV32JMSB+t5c=; b=EwCZGFVHQBbmJIwKJVZpgI7bKLCgAg9xD+rHil9xcQEpxk9rBWNYZh1ObceXvSWMwP hyYPejkLvGJiHzTDX9FqlHTsVzC+JnCVO8KpxZVucesKJnVxAjZG6ktBQ7YIWv3vX/1G 8pUWaOZesbIucqxBA7ef96UK0jGLjVHJx1d3l7dEbA4o1DHHcvIazZkZl5C54zBiYxPF DGgC5hnjMZweaV95OcF7cUalIvt1YlcTf4K1y+gzQpl/t9e9ViI8JRMpcj0dTh4PWmC/ PyhEW8XOoySMGdmp9PgvTd2G2KnbO5fwlCIkLxENWidA/3ah+xKViJQFAnHNeBm+9zjo QZGQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=N+Zqi9N1; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel+bounces-70955-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-70955-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id w6-20020a05640234c600b0056408784b15si2346631edc.390.2024.02.19.00.46.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Feb 2024 00:46:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-70955-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=@intel.com header.s=Intel header.b=N+Zqi9N1; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel+bounces-70955-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-70955-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com 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 0C9961F21824 for ; Mon, 19 Feb 2024 08:46:44 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 52D572377E; Mon, 19 Feb 2024 08:45:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="N+Zqi9N1" Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.14]) (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 F38FB21370 for ; Mon, 19 Feb 2024 08:45:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.14 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708332339; cv=none; b=o+/Qs/548WbJOcHI8Y3nwklwEmzBRE6xjIcJW/U8DwEiahvle4BOmuqycUARpwe47wWvbWofjcwnnZK8wAc7boiU/W69ujT7RhgTo9js6ijYsGqcFpV/3HWYjlGklWr0wvQyF/nrhfp584KZW8gmQeqNDtNPCtvkMySnYf+3aWw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708332339; c=relaxed/simple; bh=zVnfL6Jp+oSJOUtDQ+unuSLLB1RYfJ3Mtfu5OW3hnRo=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=cU3h5Qh0BYdzPjdVqg2jxlyijugyObJ4qUGHgc9duWm5mTJkqvsJjGXb5X7KGEFMPRQulYuF2NezdOd7Ukh/NXz3aL4yZepygkujVc3RCuN767ie0un97PNnrU/ud8MuPc2yNrs7Obfws9opLCiVKG+duWvk1VRHDiCnongoc4w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com; spf=pass smtp.mailfrom=intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=N+Zqi9N1; arc=none smtp.client-ip=198.175.65.14 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1708332337; x=1739868337; h=from:to:cc:subject:in-reply-to:references:date: message-id:mime-version; bh=zVnfL6Jp+oSJOUtDQ+unuSLLB1RYfJ3Mtfu5OW3hnRo=; b=N+Zqi9N1R2dD2p+HJnmeCpQPJrGxmzajWfMqTdSjo7rqGHk7mKxPcEnh dbwk/n7Gd8IEzVYpKXHDaw9PUQei9lHeUgVF6qW/Tgu/RlLePpz9qEwBj Rh1ewjMP7IIhzBWFkck8szydJOvbJTshBIXbfxE/9qvCO9F+RPBsOv2X8 DekDBMl5qD/56iYX9ElDOvCmk5+7JXWVOHTTRJxK+97orOFN89EYdn/Ve gdLJ4mdfclDnxkaeOq0Mr+o8nP/zGpBNkm4fP3NS83XxcNhq141yCJcNP CTpXrptL8+V/y6+XR7yGVFYPiiTUHM2Corn2UOF/H37QH5AXJATcAo4C5 Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10988"; a="6203668" X-IronPort-AV: E=Sophos;i="6.06,170,1705392000"; d="scan'208";a="6203668" Received: from orviesa005.jf.intel.com ([10.64.159.145]) by orvoesa106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Feb 2024 00:45:36 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.06,170,1705392000"; d="scan'208";a="9100008" Received: from yhuang6-desk2.sh.intel.com (HELO yhuang6-desk2.ccr.corp.intel.com) ([10.238.208.55]) by orviesa005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Feb 2024 00:45:33 -0800 From: "Huang, Ying" To: Byungchul Park Cc: mingo@redhat.com, peterz@infradead.org, juri.lelli@redhat.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de, bristot@redhat.com, vschneid@redhat.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, kernel_team@skhynix.com, akpm@linux-foundation.org Subject: Re: [PATCH v4] sched/numa, mm: do not try to migrate memory to memoryless nodes In-Reply-To: <20240219041920.1183-1-byungchul@sk.com> (Byungchul Park's message of "Mon, 19 Feb 2024 13:19:20 +0900") References: <20240219041920.1183-1-byungchul@sk.com> Date: Mon, 19 Feb 2024 16:43:36 +0800 Message-ID: <87o7ccrghz.fsf@yhuang6-desk2.ccr.corp.intel.com> User-Agent: Gnus/5.13 (Gnus v5.13) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ascii Hi, Byungchul, Byungchul Park writes: > Changes from v3: > 1. Rewrite the comment in code and the commit message to make it > more clear. (feedbacked by Oscar Salvador) > 2. Add "Reviewed-by: Oscar Salvador " > > Changes from v2: > 1. Rewrite the comment in code and the commit message becasue it > turns out that this patch is not the real fix for the oops > descriped. The real fix goes in another patch below: > > https://lore.kernel.org/lkml/20240216111502.79759-1-byungchul@sk.com/ > > Changes from v1: > 1. Trim the verbose oops in the commit message. (feedbacked by > Phil Auld) > 2. Rewrite a comment in code. (feedbacked by Phil Auld) > > --->8--- >>From 98f5d472c08e3ed5b9b6543290d392a2e50fcf3c Mon Sep 17 00:00:00 2001 > From: Byungchul Park > Date: Mon, 19 Feb 2024 13:10:47 +0900 > Subject: [PATCH v4] sched/numa, mm: do not try to migrate memory to memoryless nodes > > Memoryless nodes do not have any memory to migrate to, so stop trying > it. > > Signed-off-by: Byungchul Park > Reviewed-by: Oscar Salvador > --- > kernel/sched/fair.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c > index d7a3c63a2171..3e3b44ae72d1 100644 > --- a/kernel/sched/fair.c > +++ b/kernel/sched/fair.c > @@ -1828,6 +1828,12 @@ bool should_numa_migrate_memory(struct task_struct *p, struct folio *folio, > int dst_nid = cpu_to_node(dst_cpu); > int last_cpupid, this_cpupid; > > + /* > + * Cannot migrate to memoryless nodes. > + */ > + if (!node_state(dst_nid, N_MEMORY)) > + return false; > + > /* > * The pages in slow memory node should be migrated according > * to hot/cold instead of private/shared. Good catch! IIUC, you will use patch as fix to the issue in https://lore.kernel.org/lkml/20240216111502.79759-1-byungchul@sk.com/ If so, we need the Fixes: tag to make it land in -stable properly. Feel free to add Reviewed-by: "Huang, Ying"