From: Srinivasa Rao Mandadapu <quic_srivasam@quicinc.com>
To: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>,
"Srinivas Kandagatla" <srinivas.kandagatla@linaro.org>,
<agross@kernel.org>, <bjorn.andersson@linaro.org>,
<lgirdwood@gmail.com>, <broonie@kernel.org>, <robh+dt@kernel.org>,
<quic_plai@quicinc.com>, <bgoswami@codeaurora.org>,
<perex@perex.cz>, <tiwai@suse.com>, <rohitkr@codeaurora.org>,
<linux-arm-msm@vger.kernel.org>, <alsa-devel@alsa-project.org>,
<devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<swboyd@chromium.org>, <judyhsiao@chromium.org>,
<yung-chuan.liao@linux.intel.com>, <sanyog.r.kale@intel.com>
Cc: Venkata Prasad Potturu <quic_potturu@quicinc.com>
Subject: Re: [PATCH v2] soundwire: qcom: remove redundant wait for completion
Date: Sat, 26 Feb 2022 18:17:58 +0530 [thread overview]
Message-ID: <764e7a03-048b-750e-49ef-106863775738@quicinc.com> (raw)
In-Reply-To: <06650d56-eed3-73ad-d6b4-6b56a5a70669@linux.intel.com>
On 2/25/2022 9:13 PM, Pierre-Louis Bossart wrote:
Thanks for your time Bossart!!!
>
> On 2/25/22 08:45, Srinivas Kandagatla wrote:
>>
>> On 25/02/2022 14:44, Srinivasa Rao Mandadapu wrote:
>>> Remove wait_for_completion_timeout from soundwire probe as it seems
>>> unnecessary and device enumeration is anyway not happening here,
>>> hence this api is blocking till it completes max wait time.
>>> Also, as device enumeration event is dependent on wcd938x probe to be
>>> completed, its of no use waiting here.
>>> Waiting here increasing the boot time almost 4 seconds and impacting
>>> other modules like touch screen.
>>>
>>> Fixes: 06dd96738d618 ("soundwire: qcom: wait for enumeration to be
>>> complete in probe")
>>>
>>> Signed-off-by: Srinivasa Rao Mandadapu <quic_srivasam@quicinc.com>
>>> Co-developed-by: Venkata Prasad Potturu <quic_potturu@quicinc.com>
>>> Signed-off-by: Venkata Prasad Potturu <quic_potturu@quicinc.com>
>> LGTM,
>>
>> Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
> I don't get the idea, sorry.
>
> If you look at the code, these are the cases where this 'struct
> completion' is used
>
> struct completion enumeration;
> complete(&ctrl->enumeration);
> /* Enable Auto enumeration */
> init_completion(&ctrl->enumeration);
> wait_for_completion_timeout(&ctrl->enumeration,
>
>
> so if you remove the wait_for_completeion, then you might just as well
> remove the whole thing and revert 06dd96738d618
>
> what am I missing?
Okay. Sent new patch with reverting commit 06dd96738d618
>
>
>>> ---
>>> drivers/soundwire/qcom.c | 2 --
>>> 1 file changed, 2 deletions(-)
>>>
>>> diff --git a/drivers/soundwire/qcom.c b/drivers/soundwire/qcom.c
>>> index 5481341..9a32a24 100644
>>> --- a/drivers/soundwire/qcom.c
>>> +++ b/drivers/soundwire/qcom.c
>>> @@ -1309,8 +1309,6 @@ static int qcom_swrm_probe(struct
>>> platform_device *pdev)
>>> }
>>> qcom_swrm_init(ctrl);
>>> - wait_for_completion_timeout(&ctrl->enumeration,
>>> - msecs_to_jiffies(TIMEOUT_MS));
>>> ret = qcom_swrm_register_dais(ctrl);
>>> if (ret)
>>> goto err_master_add;
prev parent reply other threads:[~2022-02-26 12:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-25 14:44 Srinivasa Rao Mandadapu
2022-02-25 14:45 ` Srinivas Kandagatla
2022-02-25 15:43 ` Pierre-Louis Bossart
2022-02-25 18:03 ` Srinivas Kandagatla
2022-02-26 12:49 ` Srinivasa Rao Mandadapu
2022-02-26 12:47 ` Srinivasa Rao Mandadapu [this message]
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=764e7a03-048b-750e-49ef-106863775738@quicinc.com \
--to=quic_srivasam@quicinc.com \
--cc=agross@kernel.org \
--cc=alsa-devel@alsa-project.org \
--cc=bgoswami@codeaurora.org \
--cc=bjorn.andersson@linaro.org \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=judyhsiao@chromium.org \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--cc=pierre-louis.bossart@linux.intel.com \
--cc=quic_plai@quicinc.com \
--cc=quic_potturu@quicinc.com \
--cc=robh+dt@kernel.org \
--cc=rohitkr@codeaurora.org \
--cc=sanyog.r.kale@intel.com \
--cc=srinivas.kandagatla@linaro.org \
--cc=swboyd@chromium.org \
--cc=tiwai@suse.com \
--cc=yung-chuan.liao@linux.intel.com \
/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
all inboxes | Powered by JetHome®