linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Akash Asthana <akashast@codeaurora.org>
To: Douglas Anderson <dianders@chromium.org>,
	Mark Brown <broonie@kernel.org>, Andy Gross <agross@kernel.org>,
	Bjorn Andersson <bjorn.andersson@linaro.org>
Cc: linux-arm-msm@vger.kernel.org,
	Rajendra Nayak <rnayak@codeaurora.org>,
	georgi.djakov@linaro.org, swboyd@chromium.org,
	mkshah@codeaurora.org, ctheegal@codeaurora.org, mka@chromium.org,
	linux-kernel@vger.kernel.org, linux-spi@vger.kernel.org
Subject: Re: [PATCH] spi: spi-geni-qcom: Set the clock properly at runtime resume
Date: Thu, 9 Jul 2020 13:00:28 +0530	[thread overview]
Message-ID: <c7956e65-d21b-8844-45d7-de06b8d3d4f0@codeaurora.org> (raw)
In-Reply-To: <20200708163922.1.I0b701fc23eca911a5bde4ae4fa7f97543d7f960e@changeid>

Hi Doug,

>   
> @@ -670,7 +674,13 @@ static int __maybe_unused spi_geni_runtime_resume(struct device *dev)
>   	if (ret)
>   		return ret;
>   
> -	return geni_se_resources_on(&mas->se);
> +	ret = geni_se_resources_on(&mas->se);
> +	if (ret)
> +		return ret;
> +
> +	dev_pm_opp_set_rate(mas->dev, mas->cur_sclk_hz);
> +
> +	return 0;
>   }

Should we fail to resume if error is returned from 'opp_set_rate'?

'spi_geni_prepare_message' use to fail for any error from 
'opp_set_rate'  before patch series "Avoid clock setting if not needed".

But now it's possible that 'prepare_message' can return success even 
when opp are not at desired state(from previous resume call).

Regards,

Akash

>   
>   static int __maybe_unused spi_geni_suspend(struct device *dev)

-- 
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,\na Linux Foundation Collaborative Project


  reply	other threads:[~2020-07-09  7:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-08 23:39 [PATCH] spi: spi-geni-qcom: Set the clock properly at runtime resume Douglas Anderson
2020-07-09  7:30 ` Akash Asthana [this message]
2020-07-09 14:35   ` Doug Anderson
2020-07-09  8:55 ` Rajendra Nayak
2020-07-09 14:44   ` Doug Anderson
2020-07-09 11:22 ` Mark Brown

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=c7956e65-d21b-8844-45d7-de06b8d3d4f0@codeaurora.org \
    --to=akashast@codeaurora.org \
    --cc=agross@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=broonie@kernel.org \
    --cc=ctheegal@codeaurora.org \
    --cc=dianders@chromium.org \
    --cc=georgi.djakov@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=mka@chromium.org \
    --cc=mkshah@codeaurora.org \
    --cc=rnayak@codeaurora.org \
    --cc=swboyd@chromium.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 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).