Received: by 2002:ab2:3141:0:b0:1ed:23cc:44d1 with SMTP id i1csp1600923lqg; Sun, 3 Mar 2024 19:08:14 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUnvDYOlsEs+WPrLmu/AL3TZRPLGmOEem0zGEzfjd7G1uwjTtjLk2jlzm7jGsBNV2uaCf8g4Hd9VTmVG18JQejDuhFMttnrsryNedSLgA== X-Google-Smtp-Source: AGHT+IECgbghyA7YpYVUgKfzD52SBYrTy9BbZYnuHFBx1TytMGbmrRCHKmIBbPHI+ZZLjByOiOrn X-Received: by 2002:a05:6214:b14:b0:690:47ab:644e with SMTP id u20-20020a0562140b1400b0069047ab644emr11862685qvj.0.1709521694630; Sun, 03 Mar 2024 19:08:14 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709521694; cv=pass; d=google.com; s=arc-20160816; b=FEfo7CKVg4WJ4D+mTx8iOqpBxakD/JU7mBsLuoMCVVk/kvAh5dqBTuOQyp/9f1BuE2 7To7DdaGDtS0c9ab3YxoR1SFKsXBOMzPAB53kORA/RYw6UD5DzviLEIVRaMoBtaN7xW9 gg3gIRKI4iH+pE32sHoqY56wTdn9w6xVE5WTjOu3Hh0FeJQScN6JF8e/SpsMLG85K32Z Yl7+3jSikLbbA41K60BqDaqy2kwhajN4Yeig6PImnZd0RrJcLeDcrjB/nJBICuaX96tf 2GyjVDk2bBhnTMwE6+v41zJBS8PsuXLyYh9NySx6eicY4LvTeS0tHErqF7SkIoxHjRZB Q2Ug== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:date:from:dkim-signature; bh=09c5Ld8ZWpizXtKH4r3UpdHmyvyQCrCH0kV5BMr3LS0=; fh=m+QHWeHAhvb4Gns7ZGSSMSzxieVLarUXzen+benm1Ww=; b=mPxBTe8wJ4u30B0OcY+2OMhM4MMceTeTqn6Hd1wXGXBUN8AHESyGurYwVqdtR8lnoK 0wXIH79BP6xGiPoPv6R70I6ua39S/huPlhnC+/R5uvnwkrI4nyD82kas6alC8qQ5G+hR alEgevkJ0DmW4E7aCw0evi51VPheMEboMj/DzrKtIckM3WRuIPhr9PlHboT0S6bSkj0T LN4RpWwKl8ClqLKiHIE3I3PA5i0seazxAGkxpEykmTUHevjAkNBXmj3RSTgWGfn3epFA +qSjCzVVSM0tAL2Xj2en+an8XOQF1SCW4E3GHwVba9C7EnrbAYZ7kv3fddwaG70OuilP lV3A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QJbLIZXS; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-89998-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-89998-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id gh3-20020a05621429c300b006903078e18dsi8755138qvb.221.2024.03.03.19.08.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Mar 2024 19:08:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-89998-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=QJbLIZXS; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-89998-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-89998-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 5E8D01C20F48 for ; Mon, 4 Mar 2024 03:08:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 439804A34; Mon, 4 Mar 2024 03:08:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="QJbLIZXS" Received: from mail-pf1-f179.google.com (mail-pf1-f179.google.com [209.85.210.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F3ED217CE; Mon, 4 Mar 2024 03:08:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709521684; cv=none; b=oH4eTpdrAmJO6nZjrCLsAmatrS1ef7aUugsSJc2xdu4UfYzGMUS7ConQEZX3d+kCWiTCKFOF0Pqpr8FjNFlybGq0d0JUUaqPpT+oKoH9KmVDTZbgjAAueluHiVt5mt149Y3e6zDKkZgjgdrauqOIGBf7nljs3oCeDH/PAGvPJX8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709521684; c=relaxed/simple; bh=3BI8B2Bp4XeQbxQpsn++p8FJGrgiOurWA5aDjJl5cVM=; h=From:Date:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=i+t/l62vqLVD+ozBnmF7msudSU7JysRE7F+Kkz87EkS+ldxdHNfCVHZmd2ml4q1M5ISrdryzX9frRMwXymE7pCDynyoZajacjPCkDs9vcJtPktawdsGGU2BwlXQN4c5P1T5QsZc9ira0ur4jbCby9ulAr5UYvUysuLyJbG+ovqM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=QJbLIZXS; arc=none smtp.client-ip=209.85.210.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pf1-f179.google.com with SMTP id d2e1a72fcca58-6e5dddd3b95so1219277b3a.1; Sun, 03 Mar 2024 19:08:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709521682; x=1710126482; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:date:from:from:to:cc:subject:date:message-id:reply-to; bh=09c5Ld8ZWpizXtKH4r3UpdHmyvyQCrCH0kV5BMr3LS0=; b=QJbLIZXSrqr+kTTbEsicCODd2Q/7qSA5XMkjsNnu1lyoVMEd0PX4IuV5cbIunjyw66 gYjL8fEDIvNXgOA509EYO9Y5TxW2ZO0stAvFYLyFrTRQvfJXQ+Mn0YoM65SIKqIRklwy nMt7/9FCrkgnw66UhgZo6GiYsS5DIDsmdkB2alTRFzphDhno18N9fBpgax9qlRh5k/jJ e8xrNL9nLPqqcQAApZbEe7zCDkMvE40LVw81jfQBkHILjDCWOA22w8p5qXGfd01rXsdn NsoweUOE+DVrPa2r/tKzqWp6yyEQG1sREd9bzxxnK9YfP7aSpwgUxkUlkL15yjPPktz0 Gavw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709521682; x=1710126482; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:date:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=09c5Ld8ZWpizXtKH4r3UpdHmyvyQCrCH0kV5BMr3LS0=; b=QjcuBNKyBzWP5GTuAhNfzWUqMXjVQD04hEz8BoelDf2cc3xL6yL3R4XjH19Bsjf9tD ZaN5Dde3yRA0jepM5p6zh9e2l/lddwCbMqZ4L974iZObdtMqmL2zlv3ejjfvOUtxwLIG JnIlJIK1vp6CCBIx9DhRIqyoONLiDrqwyTaUhVCtE0lgb9KikqJSVk2TEbRAzvdfm20S 5rPIT+0scoQbWUpGexxUCq0imUnwFq8SxeRDBjpsFpdhRw4h7oFzzXhbahYdRKukjZC/ AoxGyTiqKZRic7zhYns/rphwpIPhOWnnbC5jpMg94ogaqe9ZhMDuBMEEntNNbrj8NEjg iXDg== X-Forwarded-Encrypted: i=1; AJvYcCWuMEWl0WrbE8EOFiIjnzIO4izAXCsEleWvYWEGDueQ1MqexzGuE4vhPsBsLCeSCM6h+EckfWzSPcjDpH5OCP/+vXW+P/1LwxLl6ffCpZvp3s4oCBCEF3SJSneiymb3nHswmRzTFhDy+MfRT3NJ7CF+nqIsWuYRCptt88H+vPeuxQvNAg== X-Gm-Message-State: AOJu0Yz3sAtTVoaRJ5cS/GxQIa/EyB70w/eFPc0XU36zgnSnpMQ/0na1 C7SifHf8g64R6qZmLA5ACNlHteRKroPgrUfByowdrCGnWbEsz5RO X-Received: by 2002:a05:6a20:8f29:b0:1a1:461a:3691 with SMTP id b41-20020a056a208f2900b001a1461a3691mr6916853pzk.15.1709521682220; Sun, 03 Mar 2024 19:08:02 -0800 (PST) Received: from debian ([2601:641:300:14de:bae0:aa65:8bdd:7233]) by smtp.gmail.com with ESMTPSA id a3-20020aa78643000000b006e0debc1b75sm6348979pfo.90.2024.03.03.19.08.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 03 Mar 2024 19:08:01 -0800 (PST) From: fan X-Google-Original-From: fan Date: Sun, 3 Mar 2024 19:07:40 -0800 To: "Ho-Ren (Jack) Chuang" Cc: Hao Xiang , Gregory Price , aneesh.kumar@linux.ibm.com, mhocko@suse.com, tj@kernel.org, john@jagalactic.com, Eishan Mirakhur , Vinicius Tavares Petrucci , Ravis OpenSrc , Alistair Popple , "Rafael J. Wysocki" , Len Brown , Andrew Morton , Dave Jiang , Dan Williams , Jonathan Cameron , Huang Ying , linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, "Ho-Ren (Jack) Chuang" , "Ho-Ren (Jack) Chuang" , linux-cxl@vger.kernel.org, qemu-devel@nongnu.org Subject: Re: [PATCH v1 0/1] Improved Memory Tier Creation for CPUless NUMA Nodes Message-ID: References: <20240301082248.3456086-1-horenchuang@bytedance.com> 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=us-ascii Content-Disposition: inline In-Reply-To: <20240301082248.3456086-1-horenchuang@bytedance.com> On Fri, Mar 01, 2024 at 08:22:44AM +0000, Ho-Ren (Jack) Chuang wrote: > The memory tiering component in the kernel is functionally useless for > CPUless memory/non-DRAM devices like CXL1.1 type3 memory because the nodes > are lumped together in the DRAM tier. > https://lore.kernel.org/linux-mm/PH0PR08MB7955E9F08CCB64F23963B5C3A860A@PH0PR08MB7955.namprd08.prod.outlook.com/T/ Is this the right patchset you want to refer to? It is about node migration between tiers, how is it related to the context here? Fan > > This patchset automatically resolves the issues. It delays the initialization > of memory tiers for CPUless NUMA nodes until they obtain HMAT information > at boot time, eliminating the need for user intervention. > If no HMAT specified, it falls back to using `default_dram_type`. > > Example usecase: > We have CXL memory on the host, and we create VMs with a new system memory > device backed by host CXL memory. We inject CXL memory performance attributes > through QEMU, and the guest now sees memory nodes with performance attributes > in HMAT. With this change, we enable the guest kernel to construct > the correct memory tiering for the memory nodes. > > Ho-Ren (Jack) Chuang (1): > memory tier: acpi/hmat: create CPUless memory tiers after obtaining > HMAT info > > drivers/acpi/numa/hmat.c | 3 ++ > include/linux/memory-tiers.h | 6 +++ > mm/memory-tiers.c | 76 ++++++++++++++++++++++++++++++++---- > 3 files changed, 77 insertions(+), 8 deletions(-) > > -- > Hao Xiang and Ho-Ren (Jack) Chuang >