From: Thomas Gleixner <tglx@linutronix.de>
To: Nicholas Piggin <npiggin@gmail.com>,
linux-kernel@vger.kernel.org, mm-commits@vger.kernel.org,
torvalds@linux-foundation.org, peterz@infradead.org,
akpm@linux-foundation.org
Subject: Re: + lazy-tlb-fix-hotplug-exit-race-with-mmu_lazy_tlb_shootdown.patch added to mm-hotfixes-unstable branch
Date: Tue, 20 Jun 2023 08:32:31 +0200 [thread overview]
Message-ID: <87jzvyprsw.ffs@tglx> (raw)
In-Reply-To: <CTH8ZNDRMLEZ.2WS18IS2E38T7@wheely>
On Tue, Jun 20 2023 at 16:02, Nicholas Piggin wrote:
> On Sun Jun 11, 2023 at 5:29 AM AEST, Thomas Gleixner wrote:
>> /*
>> * Invoked on the outgoing CPU in context of the CPU hotplug thread
>> * after ensuring that there are no user space tasks left on the CPU.
>> *
>> * If there is a lazy mm in use on the hotplug thread, drop it and
>> * switch to init_mm.
>> *
>> * The reference count on init_mm is dropped in finish_cpu().
>> */
>> static void sched_force_init_mm(void)
>> {
>>
>> No?
>
> It could be done in many places. Peter touched it last and it's
> been in the tree since prehistoric times.
That's an argument for slapping it into some randomly chosen place and
be done with it, right?
>> > +/*
>> > + * After the CPU is offline, double check that it was previously switched to
>> > + * init_mm. This call can be removed because the condition is caught in
>> > + * finish_cpu() as well.
>>
>> So why adding it in the first place?
>>
>> The changelog mumbles something about reducing churn, but I fail to see
>> that reduction. This adds 10 lines of pointless code and comments for
>> zero value.
>
> Not sure what you're talking about. The patch didn't add it. Removing it
> requires removing it from all archs, which is the churn.
Sure. That's left as an exercise for others, right?
Oh well.
tglx
next prev parent reply other threads:[~2023-06-20 6:32 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-25 20:52 + lazy-tlb-fix-hotplug-exit-race-with-mmu_lazy_tlb_shootdown.patch added to mm-hotfixes-unstable branch Andrew Morton
2023-06-10 19:29 ` Thomas Gleixner
2023-06-20 6:02 ` Nicholas Piggin
2023-06-20 6:32 ` Thomas Gleixner [this message]
2023-06-20 8:10 ` Nicholas Piggin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87jzvyprsw.ffs@tglx \
--to=tglx@linutronix.de \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mm-commits@vger.kernel.org \
--cc=npiggin@gmail.com \
--cc=peterz@infradead.org \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.