Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp2406216imm; Mon, 10 Sep 2018 00:06:07 -0700 (PDT) X-Google-Smtp-Source: ANB0Vdbi286IIt4n0FcHX5snjB3xaanXImaKE7EYsqn19k12Ydx7RjKdSzdlQBAVZau4SFfgV4wh X-Received: by 2002:a63:1a5a:: with SMTP id a26-v6mr21123015pgm.9.1536563167747; Mon, 10 Sep 2018 00:06:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536563167; cv=none; d=google.com; s=arc-20160816; b=lp8QojRO4FSe8isugemkhh8OXvmUurmpz8Slw8o1kHz/vDGtMXVgpVAe3CU24NT9Tz J5qXz4Tqc9jndQwPS1bRpBdHm3eDE69LsKjEE+xlXI1HCDFPCgGYMTOcpq48YiIu6PrY d9wDviCRE5VKUxyyweBYJaQeMn9m5vHP0o4bENJ0GUnRdn0iAfZClND0YRs2VJEg9h3b 2Shs1mAgMyrLOIu2L6nEgX1/XKK9Rtg0zofDGflb0NvHQJOERIb9bDuZeAH5GvyOFI32 xUsMkzRDTy+WQt1/uvmUd6uCZAu6wHposk+243WeG2qHOMRXv209ptlqbgq3RVhg6R1A 6yCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date; bh=GvKJKxMRqnX3nlfCYOZpjrolJZlAw9WJDm87JMLL0N0=; b=f8H2K/rTNhU+PI+1C1Kcy9r148g6pJkqKPsyTiyHhIDBvCRiNJ28pHpNFeJ0gPiZBz ytINtKpH7Qu3a3Ij2Sxfn6aNF2p0BLrCBPdyidQfYQzom7UWKlBTUcc1dDWpqXuFjCTW y85gFojvttQWcoezPM7jv+JmPb8tFvUVIjjcQClWM/M2U7fFLBACLsec/0l+CBRugXum R8TIfhnQWBz+RGtTQEfmWcayxkoLBeuf+vD1/Warc4VFjPLmvqYItdOyMO5Lj5J53dFr sXb7KGOeNZZBs6+Sl0ZfN4ahG/WZGCIZ8qExrNzdZKBX21k2tTSP8K3eFFzshD8vpZYY IuiQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r7-v6si15856020pgh.473.2018.09.10.00.05.52; Mon, 10 Sep 2018 00:06:07 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727709AbeIJL5R (ORCPT + 99 others); Mon, 10 Sep 2018 07:57:17 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:38528 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726185AbeIJL5R (ORCPT ); Mon, 10 Sep 2018 07:57:17 -0400 Received: from p4fea45ac.dip0.t-ipconnect.de ([79.234.69.172] helo=nanos) by Galois.linutronix.de with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1fzGFR-000153-9w; Mon, 10 Sep 2018 09:04:37 +0200 Date: Mon, 10 Sep 2018 09:04:36 +0200 (CEST) From: Thomas Gleixner To: "Yang, Bin" cc: "linux-kernel@vger.kernel.org" , "Gross, Mark" , "peterz@infradead.org" , "x86@kernel.org" , "Hansen, Dave" Subject: Re: [patch 01/10] x86/mm/cpa: Split, rename and clean up try_preserve_large_page() In-Reply-To: <10a05617853975fce8560ec688b6aa1bb58868ae.camel@intel.com> Message-ID: References: <20180907150119.325866892@linutronix.de> <20180907152054.463798054@linutronix.de> <10a05617853975fce8560ec688b6aa1bb58868ae.camel@intel.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 10 Sep 2018, Yang, Bin wrote: Can you please trim your replies? It's a pain in the neck to find the single line of information within a large pile of useless quoted text. > On Fri, 2018-09-07 at 17:01 +0200, Thomas Gleixner wrote: > > /* > > - * We need to check the full range, whether > > - * static_protection() requires a different pgprot for one of > > - * the pages in the range we try to preserve: > > + * Make sure that the requested pgprot does not violate the static > > + * protections. Check the full large page whether one of the pages > > + * in it results in a different pgprot than the first one of the > > + * requested range. If yes, then the page needs to be split. > > */ > > - addr = address & pmask; > > + new_prot = static_protections(req_prot, address, pfn, 1); > > "npg" is introduced by patch #3. It might be better to keep old API in > this patch. Yes. That's bogus. Will fix. Thanks, tglx