All of lore.kernel.org
 help / color / mirror / Atom feed
From: barnabas.czeman@mainlining.org
To: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Cc: Bjorn Andersson <andersson@kernel.org>,
	Mathieu Poirier <mathieu.poirier@linaro.org>,
	Tudor Ambarus <tudor.ambarus@linaro.org>,
	Jassi Brar <jassisinghbrar@gmail.com>,
	Konrad Dybcio <konradybcio@kernel.org>,
	linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org,
	linux-kernel@vger.kernel.org, Luca Weiss <luca@lucaweiss.eu>
Subject: Re: [PATCH 1/2] rpmsg: qcom_smd: Fix fallback to qcom,ipc parse
Date: Mon, 21 Apr 2025 13:40:50 +0200	[thread overview]
Message-ID: <114814a2fc59b0fa3dd5a2863394c0f2@mainlining.org> (raw)
In-Reply-To: <viki5krjvs3vs5jf2lrhah6v5rziqju7jv5kbwz7yyvdfjwhh5@6gieypw5owfp>

On 2025-04-21 12:38, Dmitry Baryshkov wrote:
> On Mon, Apr 21, 2025 at 04:04:16AM +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.
> 
> Why? What is the rationale?
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/tree/drivers/of/base.c#n1390
mailbox: use error ret code of of_parse_phandle_with_args() this commit 
was changed the return value
from ENODEV to use retrun value of of_parse_phandle_with_args what is 
returnung with EINVAL or ENOENT.
It makes skipping fallback path to parse qcom,ipc if there is no mboxes 
property defined.
As far as I know qcom,ipc now only needed for rpm smd-edge on some SoCs 
like 8939, 8916, 8976, 8917.
arm64: dts: qcom: msm8939: revert use of APCS mbox for RPM
> 
>> 
>> Fixes: 24fdd5074b20 ("mailbox: use error ret code of 
>> of_parse_phandle_with_args()")
>> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
>> ---
>>  drivers/rpmsg/qcom_smd.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/drivers/rpmsg/qcom_smd.c b/drivers/rpmsg/qcom_smd.c
>> index 
>> 40d386809d6b78e209861c23d934e1b9fd743606..e552a9af578e48cfd854a228a4d91e4fa04bf29d 
>> 100644
>> --- a/drivers/rpmsg/qcom_smd.c
>> +++ b/drivers/rpmsg/qcom_smd.c
>> @@ -1368,7 +1368,7 @@ static int qcom_smd_parse_edge(struct device 
>> *dev,
>>  	edge->mbox_client.knows_txdone = true;
>>  	edge->mbox_chan = mbox_request_channel(&edge->mbox_client, 0);
>>  	if (IS_ERR(edge->mbox_chan)) {
>> -		if (PTR_ERR(edge->mbox_chan) != -ENODEV) {
>> +		if (PTR_ERR(edge->mbox_chan) != -ENOENT) {
>>  			ret = PTR_ERR(edge->mbox_chan);
>>  			goto put_node;
>>  		}
>> 
>> --
>> 2.49.0
>> 

  reply	other threads:[~2025-04-21 11:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-21  2:04 [PATCH 0/2] Fix fallback qcom,ipc parse Barnabás Czémán
2025-04-21  2:04 ` [PATCH 1/2] rpmsg: qcom_smd: Fix fallback to " Barnabás Czémán
2025-04-21 10:38   ` Dmitry Baryshkov
2025-04-21 11:40     ` barnabas.czeman [this message]
2025-04-24 11:16       ` Dmitry Baryshkov
2025-04-21  2:04 ` [PATCH 2/2] soc: qcom: smp2p: " Barnabás Czémán
2025-04-22  8:21 ` [PATCH 0/2] Fix fallback " Stephan Gerhold
2025-07-29 11:14   ` Nayeemahmed Badebade
2025-05-09 22:13 ` (subset) " Bjorn Andersson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=114814a2fc59b0fa3dd5a2863394c0f2@mainlining.org \
    --to=barnabas.czeman@mainlining.org \
    --cc=andersson@kernel.org \
    --cc=dmitry.baryshkov@oss.qualcomm.com \
    --cc=jassisinghbrar@gmail.com \
    --cc=konradybcio@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-remoteproc@vger.kernel.org \
    --cc=luca@lucaweiss.eu \
    --cc=mathieu.poirier@linaro.org \
    --cc=tudor.ambarus@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.