[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2e8bf3e4-162d-4245-b438-8f8896a48960@intel.com>
Date: Mon, 9 Feb 2026 11:24:06 -0800
From: Dave Hansen <dave.hansen@...el.com>
To: Xie Yuanbin <qq570070308@...il.com>, peterz@...radead.org,
tglx@...nel.org, riel@...riel.com, segher@...nel.crashing.org,
david@...nel.org, hpa@...or.com, arnd@...db.de, anna-maria@...utronix.de,
mingo@...hat.com, juri.lelli@...hat.com, vincent.guittot@...aro.org,
dietmar.eggemann@....com, rostedt@...dmis.org, bsegall@...gle.com,
mgorman@...e.de, vschneid@...hat.com, bp@...en8.de,
dave.hansen@...ux.intel.com, luto@...nel.org, houwenlong.hwl@...group.com,
frederic@...nel.org, akpm@...ux-foundation.org, lorenzo.stoakes@...cle.com,
bhe@...hat.com, ryan.roberts@....com, urezki@...il.com, nysal@...ux.ibm.com,
max.kellermann@...os.com
Cc: linux-kernel@...r.kernel.org, x86@...nel.org
Subject: Re: [PATCH v6 RESEND 1/3] x86/mm/tlb: Make enter_lazy_tlb() always
inline on x86
On 2/9/26 08:23, Xie Yuanbin wrote:
> +/*
> + * Please ignore the name of this function. It should be called
> + * switch_to_kernel_thread().
> + *
> + * enter_lazy_tlb() is a hint from the scheduler that we are entering a
> + * kernel thread or other context without an mm. Acceptable implementations
> + * include doing nothing whatsoever, switching to init_mm, or various clever
> + * lazy tricks to try to minimize TLB flushes.
> + *
> + * The scheduler reserves the right to call enter_lazy_tlb() several times
> + * in a row. It will notify us that we're going back to a real mm by
> + * calling switch_mm_irqs_off().
> + */
> +#ifndef MODULE
What's with the #ifndef? Is this to avoid use spreading to modules and
then making us export some other gunk? That seems like a generally good
thing, but it's also totally random, different from the existing
'extern' declaration of enter_lazy_tlb(), and unique in the header.
Powered by blists - more mailing lists