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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 91BB1C77B6E for ; Wed, 12 Apr 2023 11:27:00 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 130696B0074; Wed, 12 Apr 2023 07:27:00 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 0E11B6B0075; Wed, 12 Apr 2023 07:27:00 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EEA9E900002; Wed, 12 Apr 2023 07:26:59 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id E00A36B0074 for ; Wed, 12 Apr 2023 07:26:59 -0400 (EDT) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay03.hostedemail.com (Postfix) with ESMTP id AFB41A0109 for ; Wed, 12 Apr 2023 11:26:59 +0000 (UTC) X-FDA: 80672512158.10.3D1C9AD Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf13.hostedemail.com (Postfix) with ESMTP id 7AF7D20002 for ; Wed, 12 Apr 2023 11:26:57 +0000 (UTC) Authentication-Results: imf13.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=NTjp5EBY; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf13.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1681298817; h=from:from:sender: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:dkim-signature; bh=bFstME57OpFndVBoorjybpUh09Bom8GSKJlx74kUL/g=; b=XuRVUQvomZxi0Lp5JdGWkrSY1yDVBwa06bJl3ZXvcG8WgDVaQgEK6WD+qlnn8zwiYRmNcE WWKm1Rbij91rEg1BFhf2DhKg7JcEpz8/+FrTKRY0cPkynCuESBEYHCqlwgOCsOQhNxfPgt 2rQwTcfx12ZLXMnnm/a7JJ4xYS26HNY= ARC-Authentication-Results: i=1; imf13.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=NTjp5EBY; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf13.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1681298817; a=rsa-sha256; cv=none; b=Yi84eEGomGEjenWIRKxw0XDxBMSc02zoxvT4zdS71cgjhSMqaRaDmsUmXrrGJPRn79Ut5r +KGWfhcY3uxQWNnAL3R3qpNaypMMlSf+1oiRXmH3pnBrBE/K9EozSCkPVKTTWAW/wAkoHV A3kVsJVHg763haLp1DxUYvDQMtdhF8E= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1681298816; 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=NTjp5EBYjSWiUm5sQQsRzFKBvJw3TibFvft5wDapPowNe41b1+vwSBBmh5GUvSvzCtUxpU lB6NHAVkK6RcgqN+7wOV2ZOYlJMhi/1HwGZcMxh+8za72DoqXzZ2JwdCDx8rXaVbdfxotW okj1lI0KOfLI7uCJ9bkVJoz+vI4zwd0= 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-199-vPUW2sr0Mh29CFOXBwXRYg-1; Wed, 12 Apr 2023 07:26:55 -0400 X-MC-Unique: vPUW2sr0Mh29CFOXBwXRYg-1 Received: by mail-wm1-f69.google.com with SMTP id d8-20020a05600c3ac800b003edf7d484d4so2947543wms.0 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=4xILjMXF8IGKmDS8WGSeRthFlzNYZuLbliT2XMPRHsVfk+sqJhSyBbafbaRmQyW7Ur t296DT7JJNE4/bq6X19zGHgG3iLdWvdTuA/zuxp2qgACC+zhgB51+UdpyYVfKrAvPor/ XB3thPdMA87RReV7Ob3zeVzVm6NjftYj0crqDlTFG6PcwTMCq+tknabLWktk6Hp8UKGk 0SkNadse8zOimllYSlNtlVF4RjI4hgI8kSkfGDoOtd4lUvxpLEt0xBX7MeCIVHzRLNt0 AzHfaiQiuNnrfqVax9Dw+6D03Q970TU8mq1kghe8b+UtIT0d50zJi4dNsb+yVsTQORZj k9Cg== X-Gm-Message-State: AAQBX9fc+l4HpfsaaZzOXCpU8sc/IXiV8TIgN6DpcbrSDU+GMV3E4VCz ZgaD/TmBgVn+sAz5ZJ90OdYCfKQRNG8dyV3+cIdOEuYw9otA82Aco99jz2TDQovuAcQvG+h+Zia fsFBkHXzqSxM= X-Received: by 2002:adf:cd8b:0:b0:2cc:459b:8bc8 with SMTP id q11-20020adfcd8b000000b002cc459b8bc8mr11934604wrj.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 X-Rspamd-Queue-Id: 7AF7D20002 X-Rspamd-Server: rspam09 X-Rspam-User: X-Stat-Signature: d1s7g87519oewt1jp6i7ukf7aq4zx5mi X-HE-Tag: 1681298817-654466 X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u0tsLbu/n6f0AxmQH34LLd72KH2H+uhhunBw78cE+t+nwWFrzAmOtPWkNgZKb189UWyO4Np/jR08WpJFLmGgKdKKPrmS4TVozOPrKrc/PQjAtzKMXGtqp32hs6gLjZNtkiXqcuHfX6pcQIyqORIenr2D+VFQSfcpwxEk42MO9bR34tmxNRW2gh972J+CeL0WPAwsNteGebEMlG5qpN5RDpBI4RUWp7ITRH9hQTKpA+LEOV7vi6yCGrSDj6DJNRGHfpu31fxiGqRADtaPdjo5xcnZaf6yVAhau3xqL+gnWn3M7Jm3HimpBgC3+LM9aYFP/8j/j5kyS8ZVpJ1ECPVvjHPQxMhzqNTrfDm+xkQPZMCPzDtta0mLkaDnMHPb69/utQVjFWoZ28/JLFVU4= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000443, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: 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