From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga18.intel.com ([134.134.136.126]:4270 "EHLO mga18.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726543AbeJCU5I (ORCPT ); Wed, 3 Oct 2018 16:57:08 -0400 Subject: Re: [RFC PATCH v4 09/27] x86/mm: Change _PAGE_DIRTY to _PAGE_DIRTY_HW References: <20180921150351.20898-1-yu-cheng.yu@intel.com> <20180921150351.20898-10-yu-cheng.yu@intel.com> <20181003133856.GA24782@bombadil.infradead.org> From: Dave Hansen Message-ID: <688c3f90-f86e-32e8-ce1a-7a10facb08a8@linux.intel.com> Date: Wed, 3 Oct 2018 07:05:23 -0700 MIME-Version: 1.0 In-Reply-To: <20181003133856.GA24782@bombadil.infradead.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-arch-owner@vger.kernel.org List-ID: To: Matthew Wilcox , Yu-cheng Yu Cc: x86@kernel.org, "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-mm@kvack.org, linux-arch@vger.kernel.org, linux-api@vger.kernel.org, Arnd Bergmann , Andy Lutomirski , Balbir Singh , Cyrill Gorcunov , Florian Weimer , "H.J. Lu" , Jann Horn , Jonathan Corbet , Kees Cook , Mike Kravetz , Nadav Amit , Oleg Nesterov , Pavel Machek , Peter Zijlstra , Randy Dunlap , "Ravi V. Shankar" , Vedvyas Shanbhogue Message-ID: <20181003140523.tCe5r_OskCYQ_0wGqEotEXx1S9EFDkBIcxqGgVxVif0@z> On 10/03/2018 06:38 AM, Matthew Wilcox wrote: > On Fri, Sep 21, 2018 at 08:03:33AM -0700, Yu-cheng Yu wrote: >> We are going to create _PAGE_DIRTY_SW for non-hardware, memory >> management purposes. Rename _PAGE_DIRTY to _PAGE_DIRTY_HW and >> _PAGE_BIT_DIRTY to _PAGE_BIT_DIRTY_HW to make these PTE dirty >> bits more clear. There are no functional changes in this >> patch. > I would like there to be some documentation in this patchset which > explains the difference between PAGE_SOFT_DIRTY and PAGE_DIRTY_SW. > > Also, is it really necessary to rename PAGE_DIRTY? It feels like a > lot of churn. This is a lot of churn? Are we looking a the same patch? :) arch/x86/include/asm/pgtable.h | 6 +++--- arch/x86/include/asm/pgtable_types.h | 17 +++++++++-------- arch/x86/kernel/relocate_kernel_64.S | 2 +- arch/x86/kvm/vmx.c | 2 +- 4 files changed, 14 insertions(+), 13 deletions(-) But, yeah, I think we need to. While it will take a little adjustment in the brains of us old-timers and a bit of pain when switching from old kernels to new, this makes it a lot more clear what is going on.