On Tue, Feb 13, 2024 at 02:25:29PM +0100, Greg Kroah-Hartman wrote: > > The patch below does not apply to the 6.6-stable tree. > If someone wants it applied there, or to any other stable or longterm > tree, then please email the backport, including the original git commit > id to <stable@xxxxxxxxxxxxxxx>. > > To reproduce the conflict and resubmit, you may use the following commands: > > git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.6.y > git checkout FETCH_HEAD > git cherry-pick -x 1e560864159d002b453da42bd2c13a1805515a20 > # <resolve conflicts, build, test, etc.> > git commit -s > git send-email --to '<stable@xxxxxxxxxxxxxxx>' --in-reply-to '2024021328-stylus-ooze-f752@gregkh' --subject-prefix 'PATCH 6.6.y' HEAD^.. > > Possible dependencies: > > 1e560864159d ("PCI/ASPM: Fix deadlock when enabling ASPM") > ac865f00af29 ("Merge tag 'pci-v6.7-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/pci/pci") It's probably not worth trying to backport this one further back than 6.7 which had the commit that introduced the issue. If the offending commit itself is being backported then that may possibly affect some Intel devices, but this fix would not be needed for Qualcomm platforms before 6.7 at least. > ------------------ original commit in Linus's tree ------------------ > > From 1e560864159d002b453da42bd2c13a1805515a20 Mon Sep 17 00:00:00 2001 > From: Johan Hovold <johan+linaro@xxxxxxxxxx> > Date: Tue, 30 Jan 2024 11:02:43 +0100 > Subject: [PATCH] PCI/ASPM: Fix deadlock when enabling ASPM > > A last minute revert in 6.7-final introduced a potential deadlock when > enabling ASPM during probe of Qualcomm PCIe controllers as reported by > lockdep: > The deadlock can easily be reproduced on machines like the Lenovo ThinkPad > X13s by adding a delay to increase the race window during asynchronous > probe where another thread can take a write lock. > > Add a new pci_set_power_state_locked() and associated helper functions that > can be called with the PCI bus semaphore held to avoid taking the read lock > twice. > > Link: https://lore.kernel.org/r/ZZu0qx2cmn7IwTyQ@xxxxxxxxxxxxxxxxxxxx > Link: https://lore.kernel.org/r/20240130100243.11011-1-johan+linaro@xxxxxxxxxx > Fixes: f93e71aea6c6 ("Revert "PCI/ASPM: Remove pcie_aspm_pm_state_change()"") > Signed-off-by: Johan Hovold <johan+linaro@xxxxxxxxxx> > Signed-off-by: Bjorn Helgaas <bhelgaas@xxxxxxxxxx> > Cc: <stable@xxxxxxxxxxxxxxx> # 6.7 Johan