[PATCH v7 0/5] soc: qcom: ice: Fix race between qcom_ice_probe() and of_qcom_ice_get()

Manivannan Sadhasivam via B4 Relay posted 5 patches 6 days, 14 hours ago
drivers/mmc/host/sdhci-msm.c | 10 ++++-----
drivers/soc/qcom/ice.c       | 49 ++++++++++++++++++++++++++++++++------------
drivers/ufs/host/ufs-qcom.c  | 10 ++++-----
3 files changed, 46 insertions(+), 23 deletions(-)
[PATCH v7 0/5] soc: qcom: ice: Fix race between qcom_ice_probe() and of_qcom_ice_get()
Posted by Manivannan Sadhasivam via B4 Relay 6 days, 14 hours ago
Hi,

This series fixes the race betwen qcom_ice_probe() and of_qcom_ice_get()
but synchronizing the two APIs and properly propagating the error codes to
clients.

Merge Strategy
==============

Due to dependency, all patches should go through Qcom SoC tree.

Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
---
Changes in v7:
- Rebased on top of v7.1-rc1
- Collected tags

Changes in v6:
- Fixed sparse warnings
- Link to v5: https://lore.kernel.org/r/20260308-qcom-ice-fix-v5-0-e47e8a44b6c4@oss.qualcomm.com

Changes in v5:
- Used Xarray instead of platform drvdata for passing the pointer since driver
  core frees drvdata on probe failure.
- Link to v4: https://lore.kernel.org/r/20260302-qcom-ice-fix-v4-0-0e65740a5dcc@oss.qualcomm.com

Changes in v4:
- For supporting multi-ice instances in a SoC, stored the err ptr in platform
  drvdata instead of in a global pointer.
- Link to v3: https://lore.kernel.org/r/20260223-qcom-ice-fix-v3-0-6ca5846329f7@oss.qualcomm.com

Changes in v3:
- Dropped the platform driver removal patch and used the ice_handle to pass
  error codes. This was done as I learned that we need to have the platform
  driver design going forward and also removing it introduces other issues.
- Link to v2: https://lore.kernel.org/r/20260210-qcom-ice-fix-v2-0-9c1ab5d6502c@oss.qualcomm.com

Changes in v2:

- Added MODULE_* macros back
- Removed spurious platform_device_put()
- Added patches to remove NULL return

---
Manivannan Sadhasivam (5):
      soc: qcom: ice: Fix race between qcom_ice_probe() and of_qcom_ice_get()
      soc: qcom: ice: Return -ENODEV if the ICE platform device is not found
      soc: qcom: ice: Return proper error codes from devm_of_qcom_ice_get() instead of NULL
      mmc: sdhci-msm: Remove NULL check from devm_of_qcom_ice_get()
      scsi: ufs: ufs-qcom: Remove NULL check from devm_of_qcom_ice_get()

 drivers/mmc/host/sdhci-msm.c | 10 ++++-----
 drivers/soc/qcom/ice.c       | 49 ++++++++++++++++++++++++++++++++------------
 drivers/ufs/host/ufs-qcom.c  | 10 ++++-----
 3 files changed, 46 insertions(+), 23 deletions(-)
---
base-commit: 254f49634ee16a731174d2ae34bc50bd5f45e731
change-id: 20260210-qcom-ice-fix-d2a3a045b32d

Best regards,
-- 
Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com>
Re: [PATCH v7 0/5] soc: qcom: ice: Fix race between qcom_ice_probe() and of_qcom_ice_get()
Posted by Bjorn Andersson 6 days, 1 hour ago
On Mon, 18 May 2026 19:22:16 +0530, Manivannan Sadhasivam wrote:
> This series fixes the race betwen qcom_ice_probe() and of_qcom_ice_get()
> but synchronizing the two APIs and properly propagating the error codes to
> clients.
> 
> Merge Strategy
> ==============
> 
> [...]

Applied, thanks!

[1/5] soc: qcom: ice: Fix race between qcom_ice_probe() and of_qcom_ice_get()
      commit: d922113ef91e6e7e8065e9070f349365341ba32e
[2/5] soc: qcom: ice: Return -ENODEV if the ICE platform device is not found
      commit: 5a4dc805a80e6fe303d6a4748cd451ea15987ffd
[3/5] soc: qcom: ice: Return proper error codes from devm_of_qcom_ice_get() instead of NULL
      commit: b9ab7217dd7d567c50311afa94d6d6746cb77e04
[4/5] mmc: sdhci-msm: Remove NULL check from devm_of_qcom_ice_get()
      commit: 2ccbb3fa5cf47d05849cf6722aad1b4cc14df6d9
[5/5] scsi: ufs: ufs-qcom: Remove NULL check from devm_of_qcom_ice_get()
      commit: 4ac19b36bf4108706238cbc4f300b17dba8b881e

Best regards,
-- 
Bjorn Andersson <andersson@kernel.org>