From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 4473E346AD6 for ; Mon, 12 Jan 2026 21:59:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768255197; cv=none; b=oWFqnJIxhednZzOyMbLXecTm7T+r7WPIwuiYt4ERay2LE6tqKhltBo3Gz58eUNhmFKLsCXQrhBc9k6xjNs4jbuQ8y/pNW5Ld88tlvDX+as2Wj+nnnMkdvRi8B4oW7eNGhc+9ONsDnBrpMIdOQb4i4+CvkFQf1DThiT/tdqPVMJ0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768255197; c=relaxed/simple; bh=6TWaUCs+hh1jde0s1NAHj/agGsET2CeuvW17XQ4LcLg=; h=From:To:Cc:In-Reply-To:References:Subject:Message-Id:Date: MIME-Version:Content-Type; b=OqZpAfjmP2vcWOvkCQoJcj4vTxtdNj7LxQA85KcXQPfVeV3eDykOaf8OpiN5uLP6nvI4tgYWaAYlYtdhpj0qyhzp891mW+ah+YQiFRMuvDEnYqvMsvQhIUucV/6oo3yLhF5pDtjQPk4e81kOyWMphy1hU0+W9DmPmtIOL8Dse2E= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Rap+mg4z; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Rap+mg4z" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 13C7AC19422; Mon, 12 Jan 2026 21:59:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1768255196; bh=6TWaUCs+hh1jde0s1NAHj/agGsET2CeuvW17XQ4LcLg=; h=From:To:Cc:In-Reply-To:References:Subject:Date:From; b=Rap+mg4zn4TUEyzDTH75ZGAN0RFnHhjFxeSegNKP1HOJhx6W7nJTWS1e9MON0lMBS TJi6dLvgl+VLpBOxRdAcZcWBAZrNq8rPPTpwusmgz9XmFdfpJcorPdMTQnXdWwPGWL AsyPpYoNEUVplZpynFOjhTddk3t41YZi+M4/RWvFY9CUt8nmhx5QvlGy1HChurXL/k 9iGAnNfyhHch02m+BZRnKeDhdHJOPdzXkfCaQdoX9wsqUDvWsPbQ8bJBCviwNwAMpn gi+thlwHjpV8KK84H3BZ1wwTpkNWy8NaaZsJ1QulHZlK1h75UyBsUZjLgwJZeYrm/w 79Csua4z0rMDg== From: Mark Brown To: gregkh@linuxfoundation.org, rafael@kernel.org, dakr@kernel.org, baolin.wang@linux.alibaba.com, cylee12@realtek.com, Yu-Chun Lin Cc: linux-kernel@vger.kernel.org, james.tai@realtek.com, cy.huang@realtek.com, stanley_chang@realtek.com In-Reply-To: <20260107032610.13166-1-eleanor.lin@realtek.com> References: <20260107032610.13166-1-eleanor.lin@realtek.com> Subject: Re: [PATCH v2] regmap: Fix race condition in hwspinlock irqsave routine Message-Id: <176825519481.237017.5137209377182553330.b4-ty@kernel.org> Date: Mon, 12 Jan 2026 21:59:54 +0000 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Mailer: b4 0.15-dev-47773 On Wed, 07 Jan 2026 11:26:10 +0800, Yu-Chun Lin wrote: > Previously, the address of the shared member '&map->spinlock_flags' was > passed directly to 'hwspin_lock_timeout_irqsave'. This creates a race > condition where multiple contexts contending for the lock could overwrite > the shared flags variable, potentially corrupting the state for the > current lock owner. > > Fix this by using a local stack variable 'flags' to store the IRQ state > temporarily. > > [...] Applied to https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap.git for-next Thanks! [1/1] regmap: Fix race condition in hwspinlock irqsave routine commit: 4b58aac989c1e3fafb1c68a733811859df388250 All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark