Re: [patch V3 06/14] x86: Select ARCH_MEMORY_ORDER_TOS
From: Thomas Gleixner
Date: Mon Mar 30 2026 - 15:49:14 EST
On Mon, Mar 30 2026 at 14:34, Mark Rutland wrote:
> On Mon, Mar 30, 2026 at 02:02:31PM +0200, Thomas Gleixner wrote:
>> The generic unsafe_atomic_store_release_user() implementation does:
>>
>> if (!IS_ENABLED(CONFIG_ARCH_MEMORY_ORDER_TOS))
>> smp_mb();
>> unsafe_put_user();
>>
>> As x86 implements Total Store Order (TOS) which means stores imply release,
>> select ARCH_MEMORY_ORDER_TOS to avoid the unnecessary smp_mb().
>>
>> Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxx>
>> Reviewed-by: André Almeida <andrealmeid@xxxxxxxxxx>
>> ---
>> V3: Rename to TOS - Peter
>
> As on the last patch, shouldn't that be TSO?
Duh. Yes. My dyslexia seems to get worse.