From: Rajat Jain <rajatja@google.com>
To: Jarkko Nikula <jarkko.nikula@linux.intel.com>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Mika Westerberg <mika.westerberg@linux.intel.com>,
Wolfram Sang <wsa@kernel.org>,
linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-pm@vger.kernel.org, dtor@google.com
Cc: Rajat Jain <rajatja@google.com>,
rajatxjain@gmail.com, dbasehore@chromium.org
Subject: [PATCH 2/3] i2c: enable async suspend/resume for i2c adapters
Date: Thu, 21 Oct 2021 19:28:58 -0700 [thread overview]
Message-ID: <20211022022859.1888836-3-rajatja@google.com> (raw)
In-Reply-To: <20211022022859.1888836-1-rajatja@google.com>
Enable async suspend/resume of i2c adapters. It enormously helps with
reducing the resume time of systems (as much as 20%-40%) where I2C devices
can take significant time (100s of ms) to resume.
Signed-off-by: Rajat Jain <rajatja@google.com>
---
drivers/i2c/i2c-core-base.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/i2c/i2c-core-base.c b/drivers/i2c/i2c-core-base.c
index 54964fbe3f03..8d4f2be54e17 100644
--- a/drivers/i2c/i2c-core-base.c
+++ b/drivers/i2c/i2c-core-base.c
@@ -1576,6 +1576,7 @@ static int i2c_register_adapter(struct i2c_adapter *adap)
if (res)
goto out_reg;
+ device_enable_async_suspend(&adap->dev);
pm_runtime_no_callbacks(&adap->dev);
pm_suspend_ignore_children(&adap->dev, true);
pm_runtime_enable(&adap->dev);
--
2.33.0.1079.g6e70778dc9-goog
next prev parent reply other threads:[~2021-10-22 2:29 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-22 2:28 [PATCH 0/3] i2c: Enable async resume for i2c devices Rajat Jain
2021-10-22 2:28 ` [PATCH 1/3] i2c: designware: Enable async suspend / resume of designware devices Rajat Jain
2021-10-22 11:37 ` Jarkko Nikula
2021-10-22 16:53 ` Dmitry Torokhov
2021-10-22 2:28 ` Rajat Jain [this message]
2021-10-22 2:28 ` [PATCH 3/3] i2c: enable async suspend/resume on i2c client devices Rajat Jain
2021-10-22 11:50 ` [PATCH 0/3] i2c: Enable async resume for i2c devices Jarkko Nikula
2021-10-25 21:35 [PATCH v2 0/3] i2c: Enable asynchronous suspend/resume Rajat Jain
2021-10-25 21:35 ` [PATCH 2/3] i2c: enable async suspend/resume for i2c adapters Rajat Jain
2021-11-29 16:51 ` Wolfram Sang
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=20211022022859.1888836-3-rajatja@google.com \
--to=rajatja@google.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=dbasehore@chromium.org \
--cc=dtor@google.com \
--cc=jarkko.nikula@linux.intel.com \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=mika.westerberg@linux.intel.com \
--cc=rajatxjain@gmail.com \
--cc=wsa@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;
as well as URLs for NNTP newsgroup(s).