Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp1098449imm; Wed, 13 Jun 2018 13:18:42 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKDUZjnlSqX9XJ7WVTsoWaB4ouDHQsySfRT/XG2yVvNjcgzE2VbAvN7eTJ0tzCokIG8+PxJ X-Received: by 2002:a17:902:57d8:: with SMTP id g24-v6mr6711784plj.116.1528921122477; Wed, 13 Jun 2018 13:18:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528921122; cv=none; d=google.com; s=arc-20160816; b=dvsp527WXN4iy1+x4MfdkFmqfa5u1VC85+Apr3KUq/AGkR5L+skPFx2Dn0V1C3tsPn ZIzFGO5F3jtyynjW/lRHMnzTmLXBNUOIH5OhDrBxFACSLqNCN+DRGQs5bjgLvTSND+hr 9oaCJImTik/30S+qXRP4/BKwnVFDZuGZ9KZ8Lpcemo01DxG0WCLYJfG2KiYEO7ZIq1Oz W5mmQmYZpGCtT5ItX562SOOtsOAUCT1MIdQP+7EgFhY55bDtBGSANdY4Oi26IP4Hh92H nHrhDpmX4Lbf3bNYS5GeLvigT7aqnhQVr+Axl4QJeRgXDPRJ1ODzIiMbAIiTCvWwZOk7 G0jw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=Q2A59r7a584XWT7GfEKnLISgx4uQhKaXnRy3UNjqiwM=; b=Es22No7SBX+Julgi6xagV2AI4KPvxr+OIbiMcOTMyJ5m9UB4a/fGBjRjw+a7CopsI+ hn4GOdf5mZ339Ep7qiOhxjXVPq8yI0IxOOvo/o500mn4keg3w1slFGyflmmufnzJYhrO sr++OQstE+aFWaXp1Cv+qX7QOZHxDdG/Hx59h3gwVPh2Pro22T9IC4uW3smm2ADvhTjo Yy7hBPK74+hZNbBrgCHZV1ZVt64rGXmyayidPkdU14jX2rwTbK1vUDq66MWvu4L/m1Hr JiUEB3QWJDMw5mhylIS7TMFLRi467UMwvEiq5kmVzgvmeAz0oszwzTHiZ+Dt8NPk+mrb QQxA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id b67-v6si3721430plb.272.2018.06.13.13.18.27; Wed, 13 Jun 2018 13:18:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S935540AbeFMUSG (ORCPT + 99 others); Wed, 13 Jun 2018 16:18:06 -0400 Received: from mga14.intel.com ([192.55.52.115]:28029 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935335AbeFMUSF (ORCPT ); Wed, 13 Jun 2018 16:18:05 -0400 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 13 Jun 2018 13:18:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,220,1526367600"; d="scan'208";a="232373606" Received: from black.fi.intel.com ([10.237.72.28]) by orsmga005.jf.intel.com with ESMTP; 13 Jun 2018 13:18:02 -0700 Received: by black.fi.intel.com (Postfix, from userid 1000) id 735D1166; Wed, 13 Jun 2018 23:18:02 +0300 (EEST) Date: Wed, 13 Jun 2018 23:18:02 +0300 From: "Kirill A. Shutemov" To: Dave Hansen Cc: Ingo Molnar , x86@kernel.org, Thomas Gleixner , "H. Peter Anvin" , Tom Lendacky , Kai Huang , Jacob Pan , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCHv3 02/17] mm/khugepaged: Do not collapse pages in encrypted VMAs Message-ID: <20180613201802.45m2745soztmkxmp@black.fi.intel.com> References: <20180612143915.68065-1-kirill.shutemov@linux.intel.com> <20180612143915.68065-3-kirill.shutemov@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170714-126-deb55f (1.8.3) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 13, 2018 at 05:50:24PM +0000, Dave Hansen wrote: > On 06/12/2018 07:39 AM, Kirill A. Shutemov wrote: > > Pages for encrypted VMAs have to be allocated in a special way: > > we would need to propagate down not only desired NUMA node but also > > whether the page is encrypted. > > > > It complicates not-so-trivial routine of huge page allocation in > > khugepaged even more. It also puts more pressure on page allocator: > > we cannot re-use pages allocated for encrypted VMA to collapse > > page in unencrypted one or vice versa. > > > > I think for now it worth skipping encrypted VMAs. We can return > > to this topic later. > > You're asking for this to be included, but without a major piece of THP > support. Is THP support unimportant for this feature? > > Are we really asking the x86 maintainers to merge this feature with this > restriction in place? I gave it more thought after your comment and I think I see a way to get khugepaged work with memory encryption. Let me check it tomorrow. -- Kirill A. Shutemov