From: Arun Kumar Neelakantam <aneela@codeaurora.org>
To: bjorn.andersson@linaro.org, clew@codeaurora.org
Cc: Arun Kumar Neelakantam <aneela@codeaurora.org>,
Andy Gross <agross@kernel.org>,
linux-arm-msm@vger.kernel.org (open list:ARM/QUALCOMM SUPPORT),
linux-kernel@vger.kernel.org (open list)
Subject: [PATCH] soc: qcom: aoss: Reduce the AOP ACK wait time
Date: Fri, 10 Jan 2020 15:37:40 +0530 [thread overview]
Message-ID: <1578650861-2450-1-git-send-email-aneela@codeaurora.org> (raw)
AOP send ACK immediately before wait thread can start waiting.
In this case the probe call is blocked for default time 1sec and
causing bootup delay.
Reduce the default wait time to 20ms to avoid delay in IRQ miss case.
Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
---
drivers/soc/qcom/qcom_aoss.c | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/drivers/soc/qcom/qcom_aoss.c b/drivers/soc/qcom/qcom_aoss.c
index 006ac40..2cf2393 100644
--- a/drivers/soc/qcom/qcom_aoss.c
+++ b/drivers/soc/qcom/qcom_aoss.c
@@ -44,6 +44,8 @@
#define QMP_NUM_COOLING_RESOURCES 2
+#define QMP_ACK_TIMEOUT msecs_to_jiffies(10)
+
static bool qmp_cdev_max_state = 1;
struct qmp_cooling_device {
@@ -150,7 +152,8 @@ static int qmp_open(struct qmp *qmp)
qmp_kick(qmp);
- ret = wait_event_timeout(qmp->event, qmp_link_acked(qmp), HZ);
+ ret = wait_event_timeout(qmp->event, qmp_link_acked(qmp),
+ QMP_ACK_TIMEOUT);
if (!ret) {
dev_err(qmp->dev, "ucore didn't ack link\n");
goto timeout_close_link;
@@ -160,7 +163,8 @@ static int qmp_open(struct qmp *qmp)
qmp_kick(qmp);
- ret = wait_event_timeout(qmp->event, qmp_ucore_channel_up(qmp), HZ);
+ ret = wait_event_timeout(qmp->event, qmp_ucore_channel_up(qmp),
+ QMP_ACK_TIMEOUT);
if (!ret) {
dev_err(qmp->dev, "ucore didn't open channel\n");
goto timeout_close_channel;
@@ -171,7 +175,8 @@ static int qmp_open(struct qmp *qmp)
qmp_kick(qmp);
- ret = wait_event_timeout(qmp->event, qmp_mcore_channel_acked(qmp), HZ);
+ ret = wait_event_timeout(qmp->event, qmp_mcore_channel_acked(qmp),
+ QMP_ACK_TIMEOUT);
if (!ret) {
dev_err(qmp->dev, "ucore didn't ack channel\n");
goto timeout_close_channel;
--
1.9.1
reply other threads:[~2020-01-10 10:07 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1578650861-2450-1-git-send-email-aneela@codeaurora.org \
--to=aneela@codeaurora.org \
--cc=agross@kernel.org \
--cc=bjorn.andersson@linaro.org \
--cc=clew@codeaurora.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®