[PATCH 0/2] Fix fallback qcom,ipc parse

Barnabás Czémán posted 2 patches 7 months, 3 weeks ago
drivers/rpmsg/qcom_smd.c | 2 +-
drivers/soc/qcom/smp2p.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
[PATCH 0/2] Fix fallback qcom,ipc parse
Posted by Barnabás Czémán 7 months, 3 weeks ago
mbox_request_channel() returning value was changed in case of error.
It uses returning value of of_parse_phandle_with_args().
It is returning with -ENOENT instead of -ENODEV when no mboxes property
exists.

ENODEV was checked before fallback to parse qcom,ipc property.

Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
---
Barnabás Czémán (2):
      rpmsg: qcom_smd: Fix fallback to qcom,ipc parse
      soc: qcom: smp2p: Fix fallback to qcom,ipc parse

 drivers/rpmsg/qcom_smd.c | 2 +-
 drivers/soc/qcom/smp2p.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
base-commit: bc8aa6cdadcc00862f2b5720e5de2e17f696a081
change-id: 20250421-fix-qcom-smd-76f7c414a11a

Best regards,
-- 
Barnabás Czémán <barnabas.czeman@mainlining.org>

Re: [PATCH 0/2] Fix fallback qcom,ipc parse
Posted by Stephan Gerhold 7 months, 3 weeks ago
On Mon, Apr 21, 2025 at 04:04:15AM +0200, Barnabás Czémán wrote:
> mbox_request_channel() returning value was changed in case of error.
> It uses returning value of of_parse_phandle_with_args().
> It is returning with -ENOENT instead of -ENODEV when no mboxes property
> exists.
> 
> ENODEV was checked before fallback to parse qcom,ipc property.
> 

Thanks for the fix!

Would be good to mention clearly that this fixes booting 6.15-rc on SoCs
that still use qcom,ipc (e.g. MSM8917, MSM8939).

Anyway, for both patches:

Reviewed-by: Stephan Gerhold <stephan.gerhold@linaro.org>
Tested-by: Stephan Gerhold <stephan.gerhold@linaro.org> # msm8939

> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
> ---
> Barnabás Czémán (2):
>       rpmsg: qcom_smd: Fix fallback to qcom,ipc parse
>       soc: qcom: smp2p: Fix fallback to qcom,ipc parse
> 
>  drivers/rpmsg/qcom_smd.c | 2 +-
>  drivers/soc/qcom/smp2p.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> ---
> base-commit: bc8aa6cdadcc00862f2b5720e5de2e17f696a081
> change-id: 20250421-fix-qcom-smd-76f7c414a11a
> 
> Best regards,
> -- 
> Barnabás Czémán <barnabas.czeman@mainlining.org>
> 
Re: [PATCH 0/2] Fix fallback qcom,ipc parse
Posted by Nayeemahmed Badebade 4 months, 2 weeks ago
On Tue, Apr 22, 2025 at 10:21:18AM +0200, Stephan Gerhold wrote:
> On Mon, Apr 21, 2025 at 04:04:15AM +0200, Barnabás Czémán wrote:
> > mbox_request_channel() returning value was changed in case of error.
> > It uses returning value of of_parse_phandle_with_args().
> > It is returning with -ENOENT instead of -ENODEV when no mboxes property
> > exists.
> > 
> > ENODEV was checked before fallback to parse qcom,ipc property.
> > 
> 
> Thanks for the fix!
> 
> Would be good to mention clearly that this fixes booting 6.15-rc on SoCs
> that still use qcom,ipc (e.g. MSM8917, MSM8939).
> 
> Anyway, for both patches:
> 
> Reviewed-by: Stephan Gerhold <stephan.gerhold@linaro.org>
> Tested-by: Stephan Gerhold <stephan.gerhold@linaro.org> # msm8939
>

Hi,

I think we should consider applying these fixes to stable versions such
as linux-5.15.y and linux-5.10.y

On v5.15.186 and v5.10.240, we noticed below errors with msm8916
platform:
  [    0.185835] qcom_smp2p: probe of smp2p-hexagon failed with error -2
  [    0.185905] qcom_smp2p: probe of smp2p-wcnss failed with error -2
  [    1.525302]  smd:rpm: failed to parse smd edge

On these versions, msm8916 device tree still uses qcom,ipc, due to which
drivers in question fail with above errors.

Applying these patches on those versions, fixes the issues.

Also, only one patch which updates drivers/soc/qcom/smp2p.c seems to be
merged to mainline, while drivers/rpmsg/qcom_smd.c is not updated yet.

Thank you.

Tested-by: Nayeemahmed Badebade <nayeemahmed.badebade@sony.com> #msm8916

Regards,
Nayeem

> > Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
> > ---
> > Barnabás Czémán (2):
> >       rpmsg: qcom_smd: Fix fallback to qcom,ipc parse
> >       soc: qcom: smp2p: Fix fallback to qcom,ipc parse
> > 
> >  drivers/rpmsg/qcom_smd.c | 2 +-
> >  drivers/soc/qcom/smp2p.c | 2 +-
> >  2 files changed, 2 insertions(+), 2 deletions(-)
> > ---
> > base-commit: bc8aa6cdadcc00862f2b5720e5de2e17f696a081
> > change-id: 20250421-fix-qcom-smd-76f7c414a11a
> > 
> > Best regards,
> > -- 
> > Barnabás Czémán <barnabas.czeman@mainlining.org>
> > 
Re: (subset) [PATCH 0/2] Fix fallback qcom,ipc parse
Posted by Bjorn Andersson 7 months, 1 week ago
On Mon, 21 Apr 2025 04:04:15 +0200, Barnabás Czémán wrote:
> mbox_request_channel() returning value was changed in case of error.
> It uses returning value of of_parse_phandle_with_args().
> It is returning with -ENOENT instead of -ENODEV when no mboxes property
> exists.
> 
> ENODEV was checked before fallback to parse qcom,ipc property.
> 
> [...]

Applied, thanks!

[2/2] soc: qcom: smp2p: Fix fallback to qcom,ipc parse
      commit: 421777a02bbd9cdabe0ae05a69ee06253150589d

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