]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
phy: zynqmp: Take the phy mutex in xlate
authorSean Anderson <sean.anderson@linux.dev>
Fri, 28 Jun 2024 20:55:39 +0000 (16:55 -0400)
committerVinod Koul <vkoul@kernel.org>
Tue, 2 Jul 2024 13:18:09 +0000 (18:48 +0530)
commitd79c6840917097285e03a49f709321f5fb972750
treec5754dd0550cfbecc9e2c2941cd72f970957c74e
parent235d8b663ab9e6cc13f8374abfffa559f50b57b6
phy: zynqmp: Take the phy mutex in xlate

Take the phy mutex in xlate to protect against concurrent
modification/access to gtr_phy. This does not typically cause any
issues, since in most systems the phys are only xlated once and
thereafter accessed with the phy API (which takes the locks). However,
we are about to allow userspace to access phys for debugging, so it's
important to avoid any data races.

Signed-off-by: Sean Anderson <sean.anderson@linux.dev>
Link: https://lore.kernel.org/r/20240628205540.3098010-5-sean.anderson@linux.dev
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/xilinx/phy-zynqmp.c