Re: [PATCH for 4.16 08/10] membarrier: x86: Provide core serializing command (v3)
From: Mathieu Desnoyers
Date: Tue Jan 16 2018 - 15:41:14 EST
----- On Jan 16, 2018, at 2:22 PM, Mathieu Desnoyers mathieu.desnoyers@xxxxxxxxxxxx wrote:
> ----- On Jan 16, 2018, at 1:29 PM, Thomas Gleixner tglx@xxxxxxxxxxxxx wrote:
>
>> On Mon, 15 Jan 2018, Mathieu Desnoyers wrote:
>>
>>> There are two places where core serialization is needed by membarrier:
>>>
>>> 1) When returning from the membarrier IPI,
>>> 2) After scheduler updates curr to a thread with a different mm, before
>>> going back to user-space, since the curr->mm is used by membarrier to
>>> check whether it needs to send an IPI to that CPU.
>>
>> This wants to be split into x86 and core changes. Ideally you make the core
>> changes before the previous patch and add the empty inline into
>> linux/processor.h....
>
> Good point, done. The first commit introducing the new command now also
> introduces the generic stuff moved from the x86 patches.
Scratch this: it's cleaner if I add a separate generic patch to introduce
just the empty inline into linux/processor.h and the
ARCH_HAS_SYNC_CORE_BEFORE_USERMODE in init/Kconfig.
Thanks,
Mathieu
>
> Thanks,
>
> Mathieu
>
>>
>> Thanks,
>>
>> tglx
>
> --
> Mathieu Desnoyers
> EfficiOS Inc.
> http://www.efficios.com
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com