From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E5C32C77B7D for ; Wed, 12 Apr 2023 11:28:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231466AbjDLL2l (ORCPT ); Wed, 12 Apr 2023 07:28:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55282 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230272AbjDLL2R (ORCPT ); Wed, 12 Apr 2023 07:28:17 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9079F2D64 for ; Wed, 12 Apr 2023 04:27:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1681298818; h=from:from: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=bFstME57OpFndVBoorjybpUh09Bom8GSKJlx74kUL/g=; b=hJxv0yu0ZPeoKRdWoG26EyiBHb0TkcDiUPcCicUHxIr19qWi79w1Z4kKKSavOF9k6DXwaY KpzR3Ze2tgD0eyNL2F8JNK9ST5B0o+ygWs+OqrsRJCMo/Mo9rMrpEx5g8SnL4UU3hroI9Q hyeaavZ7fgZ759TQSDAFeKQFdDgbb6M= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-251-Ztk-kQy0M2-EYRh1x4468A-1; Wed, 12 Apr 2023 07:26:55 -0400 X-MC-Unique: Ztk-kQy0M2-EYRh1x4468A-1 Received: by mail-wm1-f69.google.com with SMTP id c19-20020a05600c0a5300b003f07515bce8so4866371wmq.5 for ; Wed, 12 Apr 2023 04:26:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681298814; x=1683890814; h=content-transfer-encoding:in-reply-to:organization:from:references :cc:to:content-language:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=bFstME57OpFndVBoorjybpUh09Bom8GSKJlx74kUL/g=; b=PwT/AB/K/YeopsvuXcWciROFn+sOvhKMWYxZhYzgx7Lri8cnRfstoL8XXta6QOuQ1y 4plr8h3dbPtsfJdylNbKGPGUFoGhy7vGEdKUl34tQaY3WhD85zC7tkUFhzAJzy1qXM6B DtFjl9B5GA4j7in2y1yGhz/kDusvebLKGAeWiNniIsqdomtrCIzCMwH2nq7URrQDSsYg yIUkU2TVWIG8c+89XEwIUXl2SZ0HIMpu4JTB8acjPeDeVRD/zfGGlo2IUM5nJXlqwIZ5 JNr+mZnwLfUqJStCungNH6WIkQ19QG7dlY5keGD+SOq+thovAy1gJDdo2Qa2+Upx1+7q qsFQ== X-Gm-Message-State: AAQBX9e6Kkn1zXGT/4zGC2fJT60tunwstnS+bvzT0dAQAH55HRPK6UxX nA6n3nvD8m/j6gE5F8F3Wg3RPG8ThgEW7FigaPbHiA6gk0Bi0vj9ltiWmUNQx9CsUagIP1qlVf7 HLvBiEWxs5cI4pvl7ckes X-Received: by 2002:adf:cd8b:0:b0:2cc:459b:8bc8 with SMTP id q11-20020adfcd8b000000b002cc459b8bc8mr11934598wrj.6.1681298814478; Wed, 12 Apr 2023 04:26:54 -0700 (PDT) X-Google-Smtp-Source: AKy350bKiPtn0M7N9Ns7kjv5Eqgc5pVwSYAJTLw8hVIz9qZoH9v7bIi2Kp/ypGNnNQvysM+4xb4xkw== X-Received: by 2002:adf:cd8b:0:b0:2cc:459b:8bc8 with SMTP id q11-20020adfcd8b000000b002cc459b8bc8mr11934589wrj.6.1681298814088; Wed, 12 Apr 2023 04:26:54 -0700 (PDT) Received: from ?IPV6:2003:cb:c702:4b00:c6fa:b613:dbdc:ab? (p200300cbc7024b00c6fab613dbdc00ab.dip0.t-ipconnect.de. [2003:cb:c702:4b00:c6fa:b613:dbdc:ab]) by smtp.gmail.com with ESMTPSA id x18-20020adfec12000000b002f2b8cb5d9csm5056882wrn.28.2023.04.12.04.26.53 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 12 Apr 2023 04:26:53 -0700 (PDT) Message-ID: Date: Wed, 12 Apr 2023 13:26:52 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.9.1 Subject: Re: FW: [LSF/MM/BPF TOPIC] BoF VM live migration over CXL memory To: Kyungsan Kim Cc: lsf-pc@lists.linux-foundation.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, linux-cxl@vger.kernel.org, a.manzanares@samsung.com, viacheslav.dubeyko@bytedance.com, dan.j.williams@intel.com, seungjun.ha@samsung.com, wj28.lee@samsung.com References: <20230412111033.434644-1-ks0204.kim@samsung.com> From: David Hildenbrand Organization: Red Hat In-Reply-To: <20230412111033.434644-1-ks0204.kim@samsung.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-cxl@vger.kernel.org On 12.04.23 13:10, Kyungsan Kim wrote: >>> Gregory Price writes: >>> >>>> On Tue, Apr 11, 2023 at 02:37:50PM +0800, Huang, Ying wrote: >>>>> Gregory Price writes: >>>>> >>>>> [snip] >>>>> >>>>>> 2. During the migration process, the memory needs to be forced not to be >>>>>> migrated to another node by other means (tiering software, swap, >>>>>> etc). The obvious way of doing this would be to migrate and >>>>>> temporarily pin the page... but going back to problem #1 we see that >>>>>> ZONE_MOVABLE and Pinning are mutually exclusive. So that's >>>>>> troublesome. >>>>> >>>>> Can we use memory policy (cpusets, mbind(), set_mempolicy(), etc.) to >>>>> avoid move pages out of CXL.mem node? Now, there are gaps in tiering, >>>>> but I think it is fixable. >>>>> >>>>> Best Regards, >>>>> Huang, Ying >>>>> >>>>> [snip] >>>> >>>> That feels like a hack/bodge rather than a proper solution to me. >>>> >>>> Maybe this is an affirmative argument for the creation of an EXMEM >>>> zone. >>> >>> Let's start with requirements. What is the requirements for a new zone >>> type? >> >> I'm stills scratching my head regarding this. I keep hearing all >> different kind of statements that just add more confusions "we want it >> to be hotunpluggable" "we want to allow for long-term pinning memory" >> "but we still want it to be movable" "we want to place some unmovable >> allocations on it". Huh? >> >> Just to clarify: ZONE_MOVABLE allows for pinning. It just doesn't allow >> for long-term pinning of memory. >> >> For good reason, because long-term pinning of memory is just the worst >> (memory waste, fragmentation, overcommit) and instead of finding new >> ways to *avoid* long-term pinnings, we're coming up with advanced >> concepts to work-around the fundamental property of long-term pinnings. >> >> We want all memory to be long-term pinnable and we want all memory to be >> movable/hotunpluggable. That's not going to work. > > Looks there is misunderstanding about ZONE_EXMEM argument. > Pinning and plubbability is mutual exclusive so it can not happen at the same time. > What we argue is ZONE_EXMEM does not "confine movability". an allocation context can determine the movability attribute. > Even one unmovable allocation will make the entire CXL DRAM unpluggable. > When you see ZONE_EXMEM just on movable/unmoable aspect, we think it is the same with ZONE_NORMAL, > but ZONE_EXMEM works on an extended memory, as of now CXL DRAM. > > Then why ZONE_EXMEM is, ZONE_EXMEM considers not only the pluggability aspect, but CXL identifier for user/kenelspace API, > the abstraction of multiple CXL DRAM channels, and zone unit algorithm for CXL HW characteristics. > The last one is potential at the moment, though. > > As mentioned in ZONE_EXMEM thread, we are preparing slides to explain experiences and proposals. > It it not final version now[1]. > [1] https://github.com/OpenMPDK/SMDK/wiki/93.-%5BLSF-MM-BPF-TOPIC%5D-SMDK-inspired-MM-changes-for-CXL Yes, hopefully we can discuss at LSF/MM also the problems we are trying to solve instead of focusing on one solution. [did not have the time to look at the slides yet, sorry] -- Thanks, David / dhildenb