[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZHed6OuO/ALNfvaX@ziepe.ca>
Date: Wed, 31 May 2023 16:20:08 -0300
From: Jason Gunthorpe <jgg@...pe.ca>
To: Yu Zhao <yuzhao@...gle.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Paolo Bonzini <pbonzini@...hat.com>,
Alistair Popple <apopple@...dia.com>,
Anup Patel <anup@...infault.org>,
Ben Gardon <bgardon@...gle.com>,
Borislav Petkov <bp@...en8.de>,
Catalin Marinas <catalin.marinas@....com>,
Chao Peng <chao.p.peng@...ux.intel.com>,
Christophe Leroy <christophe.leroy@...roup.eu>,
Dave Hansen <dave.hansen@...ux.intel.com>,
Fabiano Rosas <farosas@...ux.ibm.com>,
Gaosheng Cui <cuigaosheng1@...wei.com>,
Gavin Shan <gshan@...hat.com>,
"H. Peter Anvin" <hpa@...or.com>, Ingo Molnar <mingo@...hat.com>,
James Morse <james.morse@....com>,
"Jason A. Donenfeld" <Jason@...c4.com>,
Jonathan Corbet <corbet@....net>,
Marc Zyngier <maz@...nel.org>,
Masami Hiramatsu <mhiramat@...nel.org>,
Michael Ellerman <mpe@...erman.id.au>,
Michael Larabel <michael@...haellarabel.com>,
Mike Rapoport <rppt@...nel.org>,
Nicholas Piggin <npiggin@...il.com>,
Oliver Upton <oliver.upton@...ux.dev>,
Paul Mackerras <paulus@...abs.org>,
Peter Xu <peterx@...hat.com>,
Sean Christopherson <seanjc@...gle.com>,
Steven Rostedt <rostedt@...dmis.org>,
Suzuki K Poulose <suzuki.poulose@....com>,
Thomas Gleixner <tglx@...utronix.de>,
Thomas Huth <thuth@...hat.com>, Will Deacon <will@...nel.org>,
Zenghui Yu <yuzenghui@...wei.com>, kvmarm@...ts.linux.dev,
kvm@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, linuxppc-dev@...ts.ozlabs.org,
linux-trace-kernel@...r.kernel.org, x86@...nel.org,
linux-mm@...gle.com
Subject: Re: [PATCH mm-unstable v2 02/10] mm/kvm: use
mmu_notifier_ops->test_clear_young()
On Fri, May 26, 2023 at 05:44:27PM -0600, Yu Zhao wrote:
> Replace test_young() and clear_young() with test_clear_young().
>
> Signed-off-by: Yu Zhao <yuzhao@...gle.com>
> ---
> include/linux/mmu_notifier.h | 29 ++-----------------
> include/trace/events/kvm.h | 15 ----------
> mm/mmu_notifier.c | 42 ----------------------------
> virt/kvm/kvm_main.c | 54 ------------------------------------
> 4 files changed, 2 insertions(+), 138 deletions(-)
>
> diff --git a/include/linux/mmu_notifier.h b/include/linux/mmu_notifier.h
> index dfdbb370682d..c8f35fc08703 100644
> --- a/include/linux/mmu_notifier.h
> +++ b/include/linux/mmu_notifier.h
> @@ -104,26 +104,6 @@ struct mmu_notifier_ops {
> unsigned long start,
> unsigned long end);
>
> - /*
> - * clear_young is a lightweight version of clear_flush_young. Like the
> - * latter, it is supposed to test-and-clear the young/accessed bitflag
> - * in the secondary pte, but it may omit flushing the secondary tlb.
> - */
> - int (*clear_young)(struct mmu_notifier *subscription,
> - struct mm_struct *mm,
> - unsigned long start,
> - unsigned long end);
> -
> - /*
> - * test_young is called to check the young/accessed bitflag in
> - * the secondary pte. This is used to know if the page is
> - * frequently used without actually clearing the flag or tearing
> - * down the secondary mapping on the page.
> - */
> - int (*test_young)(struct mmu_notifier *subscription,
> - struct mm_struct *mm,
> - unsigned long address);
> -
> int (*test_clear_young)(struct mmu_notifier *mn, struct mm_struct *mm,
> unsigned long start, unsigned long end,
> bool clear, unsigned long *bitmap);
Oh, you split the patch. This MMU notifier stuff seems OK for both
patches then, and KVM is the only user:
Reviewed-by: Jason Gunthorpe <jgg@...dia.com>
Jason
Powered by blists - more mailing lists