diff options
author | Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org> | 2023-12-08 12:28:48 +0530 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2023-12-13 23:03:45 -0500 |
commit | 3a747c5cf9b6c36649783b28d2ef8f9c92b16a0f (patch) | |
tree | eb25e5bd941d4161cb6168d7a29a99a4b3d0995b /drivers/ufs | |
parent | 3bf7ab4ac30c03beecf57c052e87d5a38fb8aed6 (diff) |
scsi: ufs: qcom: Fix the return value when platform_get_resource_byname() fails
The return value should be -ENODEV indicating that the resource is not
provided in DT, not -ENOMEM. Fix it!
Fixes: c263b4ef737e ("scsi: ufs: core: mcq: Configure resource regions")
Reviewed-by: Andrew Halaney <ahalaney@redhat.com>
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Link: https://lore.kernel.org/r/20231208065902.11006-4-manivannan.sadhasivam@linaro.org
Tested-by: Andrew Halaney <ahalaney@redhat.com> # sa8775p-ride
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/ufs')
-rw-r--r-- | drivers/ufs/host/ufs-qcom.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ufs/host/ufs-qcom.c b/drivers/ufs/host/ufs-qcom.c index 852179e456f2..778df0a9c65e 100644 --- a/drivers/ufs/host/ufs-qcom.c +++ b/drivers/ufs/host/ufs-qcom.c @@ -1701,7 +1701,7 @@ static int ufs_qcom_mcq_config_resource(struct ufs_hba *hba) if (!res->resource) { dev_info(hba->dev, "Resource %s not provided\n", res->name); if (i == RES_UFS) - return -ENOMEM; + return -ENODEV; continue; } else if (i == RES_UFS) { res_mem = res->resource; |