devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Andersson <andersson@kernel.org>
To: Stephan Gerhold <stephan@gerhold.net>
Cc: Andy Gross <agross@kernel.org>,
	Konrad Dybcio <konrad.dybcio@linaro.org>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Mark Brown <broonie@kernel.org>,
	Jiasheng Jiang <jiasheng@iscas.ac.cn>,
	Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
	Banajit Goswami <bgoswami@quicinc.com>,
	linux-arm-msm@vger.kernel.org, alsa-devel@alsa-project.org,
	devicetree@vger.kernel.org,
	~postmarketos/upstreaming@lists.sr.ht
Subject: Re: [PATCH 2/2] soc: qcom: apr: Make qcom,protection-domain optional again
Date: Thu, 29 Dec 2022 11:53:53 -0600	[thread overview]
Message-ID: <20221229175353.msas6w2eaunv4gt4@builder.lan> (raw)
In-Reply-To: <20221229151648.19839-3-stephan@gerhold.net>

On Thu, Dec 29, 2022 at 04:16:48PM +0100, Stephan Gerhold wrote:
> APR should not fail if the service device tree node does not have
> the qcom,protection-domain property, since this functionality does
> not exist on older platforms such as MSM8916 and MSM8996.
> 

Forgot that when I reviewed 6d7860f5750d, but you're right. Sorry about
that.

Reviewed-by: Bjorn Andersson <andersson@kernel.org>

Regards,
Bjorn

> Ignore -EINVAL (returned when the property does not exist) to fix
> a regression on 6.2-rc1 that prevents audio from working:
> 
>   qcom,apr remoteproc0:smd-edge.apr_audio_svc.-1.-1:
>     Failed to read second value of qcom,protection-domain
>   qcom,apr remoteproc0:smd-edge.apr_audio_svc.-1.-1:
>     Failed to add apr 3 svc
> 
> Fixes: 6d7860f5750d ("soc: qcom: apr: Add check for idr_alloc and of_property_read_string_index")
> Signed-off-by: Stephan Gerhold <stephan@gerhold.net>
> ---
>  drivers/soc/qcom/apr.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/soc/qcom/apr.c b/drivers/soc/qcom/apr.c
> index cd44f17dad3d..d51abb462ae5 100644
> --- a/drivers/soc/qcom/apr.c
> +++ b/drivers/soc/qcom/apr.c
> @@ -461,9 +461,10 @@ static int apr_add_device(struct device *dev, struct device_node *np,
>  		goto out;
>  	}
>  
> +	/* Protection domain is optional, it does not exist on older platforms */
>  	ret = of_property_read_string_index(np, "qcom,protection-domain",
>  					    1, &adev->service_path);
> -	if (ret < 0) {
> +	if (ret < 0 && ret != -EINVAL) {
>  		dev_err(dev, "Failed to read second value of qcom,protection-domain\n");
>  		goto out;
>  	}
> -- 
> 2.39.0
> 

  reply	other threads:[~2022-12-29 17:54 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-29 15:16 [PATCH 0/2] Fix APR audio regression on 6.2-rc1 Stephan Gerhold
2022-12-29 15:16 ` [PATCH 1/2] dt-bindings: soc: qcom: apr: Make qcom,protection-domain optional again Stephan Gerhold
2022-12-29 18:29   ` Bjorn Andersson
2022-12-30  8:08   ` Krzysztof Kozlowski
2022-12-29 15:16 ` [PATCH 2/2] " Stephan Gerhold
2022-12-29 17:53   ` Bjorn Andersson [this message]
2023-01-06 20:24 ` [PATCH 0/2] Fix APR audio regression on 6.2-rc1 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=20221229175353.msas6w2eaunv4gt4@builder.lan \
    --to=andersson@kernel.org \
    --cc=agross@kernel.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=bgoswami@quicinc.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jiasheng@iscas.ac.cn \
    --cc=konrad.dybcio@linaro.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=srinivas.kandagatla@linaro.org \
    --cc=stephan@gerhold.net \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).