From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from fanzine2.igalia.com (fanzine2.igalia.com [213.97.179.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F01863B3882 for ; Fri, 20 Mar 2026 16:08:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.97.179.56 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774022890; cv=none; b=nSeEVv6Z4/bBpAXbpYqdEdDAoMgON8IlfyRemTmUvRUpFBn6ISPzmSHUv9ZMhTJEYC9T9jRksz3p/FxYSyF1lr9D5fMsaK7M9bmxRWnIzIPQP5c7jKiuQY5/7z+8HwHhAX57DJ3SrreUjTFZxr9Lt4exKuqK1T4u/mymgtMV3rs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774022890; c=relaxed/simple; bh=VRszGCMevLwIuc0CLNlQQwZKOhNoLoUNFOlJCJoIkLE=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=ZRYAmYIZA4Rqn7jHAC2qM/y7mWGGGGVws7YOgFPOkLMHIwqHK1K5sSQ+xScTeY7Eiij35Q+c804sxfRmdETQlDWEhjkNtdjsy+5NuWBwQAJEzfEt3aaMOfp8EeTdgAcqqJ2mBogJBb7SpuMCT1RGi8LAmjmEW2pF1WzFTpLw81s= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=igalia.com; spf=pass smtp.mailfrom=igalia.com; dkim=pass (2048-bit key) header.d=igalia.com header.i=@igalia.com header.b=Rm5w0lMT; arc=none smtp.client-ip=213.97.179.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=igalia.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=igalia.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=igalia.com header.i=@igalia.com header.b="Rm5w0lMT" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Content-Transfer-Encoding:Content-Type:In-Reply-To:From: References:Cc:To:Subject:MIME-Version:Date:Message-ID:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=T0eU4+3acKLIBHRvwpId+GJh8rassNvU2ol37qBITDk=; b=Rm5w0lMTSIzSe+PRQ3FsuERvXi ywMi2ojI8NDACVR9Jg10XxQ6mSHAt0ifRNKfJB1JRc9bGgSB7vyDk/fzIPV48SFxWHUB6QrDcsn5c bmUL7mP0xhokRVCfAoK2AxKyael0OIdZngF8smd9ISU4hxB9BL6L6lZG/07b6hTypRTTAbWZ+Kdlc x6oa0mYpDina2i52HJclZLZONq4rHXBuRw6Tlwg5N9BguwoDK0iGwQhrByCA33u9SzBRpSe4EM3aD 5tmsQt3mYgKlPkI8ehNN9cCVYChpIUNfPDHcP/m9GRgyU+r16w+dVormsrJTeyaU/IEWlYLiYofCU SL4MliCg==; Received: from [179.118.189.200] (helo=[192.168.15.100]) by fanzine2.igalia.com with esmtpsa (Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_128_GCM:128) (Exim) id 1w3cNt-003sZ5-G7; Fri, 20 Mar 2026 17:07:37 +0100 Message-ID: <830886a9-001d-4d35-911c-fa5b2aacc26d@igalia.com> Date: Fri, 20 Mar 2026 13:07:29 -0300 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Beta Subject: Re: [patch v2 04/11] uaccess: Provide unsafe_atomic_store_release_user() To: Thomas Gleixner Cc: Mathieu Desnoyers , Sebastian Andrzej Siewior , Carlos O'Donell , Peter Zijlstra , Florian Weimer , Rich Felker , LKML , Torvald Riegel , Darren Hart , Ingo Molnar , Davidlohr Bueso , Arnd Bergmann , "Liam R . Howlett" , Uros Bizjak , =?UTF-8?Q?Thomas_Wei=C3=9Fschuh?= References: <20260319225224.853416463@kernel.org> <20260319231239.410326941@kernel.org> Content-Language: en-US From: =?UTF-8?Q?Andr=C3=A9_Almeida?= In-Reply-To: <20260319231239.410326941@kernel.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Em 19/03/2026 20:24, Thomas Gleixner escreveu: > The upcoming support for unlocking robust futexes in the kernel requires > store release semantics. Syscalls do not imply memory ordering on all > architectures so the unlock operation requires a barrier. > > This barrier can be avoided when stores imply release like on x86. > > Provide a generic version with a smp_mb() before the unsafe_put_user(), > which can be overridden by architectures. > > Provide also a ARCH_STORE_IMPLIES_RELEASE Kconfig option, which can be > selected by architectures where store implies release, so that the smp_mb() > in the generic implementation can be avoided. > > Signed-off-by: Thomas Gleixner Reviewed-by: André Almeida