From: Denis Benato <benato.denis96@gmail.com>
To: Andy Shevchenko <andy@kernel.org>
Cc: "Jonathan Cameron" <jic23@kernel.org>,
"Alex Lanzano" <lanzano.alex@gmail.com>,
"David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
linux-iio@vger.kernel.org,
"Derek J. Clark" <derekjohn.clark@gmail.com>,
"Philip Müller" <philm@manjaro.org>,
"Justin Weiss" <justin@justinweiss.com>
Subject: Re: [PATCH 1/2] iio: bmi270: suspend and resume triggering on relevant pm operations
Date: Sat, 24 May 2025 22:25:11 +0200 [thread overview]
Message-ID: <cddc4a4f-f982-49ec-a03b-3e26038057fe@gmail.com> (raw)
In-Reply-To: <aCG3YRP66cKyzr1B@smile.fi.intel.com>
On 5/12/25 10:54, Andy Shevchenko wrote:
> On Fri, May 09, 2025 at 07:15:25PM +0200, Denis Benato wrote:
>> Prevent triggers from stop working after the device has entered sleep:
>> use iio_device_suspend_triggering and iio_device_resume_triggering helpers.
> The cover letter call it a fix, where is the Fixes tag?
I didn't know if it was okay to use that tag while to root cause is still there and it needs to be fixed for a lot more devices.
I was also attempting to make this patch very similar to accepted one: https://lore.kernel.org/all/20240807185619.7261-3-benato.denis96@gmail.com/
Is fixed tag appropriate?
>
> ...
>
>> +const struct dev_pm_ops bmi270_core_pm_ops = {
>> + RUNTIME_PM_OPS(bmi270_core_runtime_suspend,
>> + bmi270_core_runtime_resume, NULL)
> One line (it's only 85 characters and it's fine in this case).
Okay, will send a new version when I have answer to the above question.
>> +};
> ...
>
>> --- a/drivers/iio/imu/bmi270/bmi270_i2c.c
>> +++ b/drivers/iio/imu/bmi270/bmi270_i2c.c
>> @@ -52,6 +52,7 @@ static const struct of_device_id bmi270_of_match[] = {
>> static struct i2c_driver bmi270_i2c_driver = {
>> .driver = {
>> .name = "bmi270_i2c",
>> + .pm = pm_ptr(&bmi270_core_pm_ops),
> Is pm.h included?
I assumed it was not needed since the i2c_driver definition should be enough.
I will include pm.h on the next version, thanks.
>
>> .acpi_match_table = bmi270_acpi_match,
>> .of_match_table = bmi270_of_match,
>> },
>> diff --git a/drivers/iio/imu/bmi270/bmi270_spi.c b/drivers/iio/imu/bmi270/bmi270_spi.c
>> index 88a77aba5e4f..b25171413531 100644
>> --- a/drivers/iio/imu/bmi270/bmi270_spi.c
>> +++ b/drivers/iio/imu/bmi270/bmi270_spi.c
>> @@ -79,6 +79,7 @@ static const struct of_device_id bmi270_of_match[] = {
>> static struct spi_driver bmi270_spi_driver = {
>> .driver = {
>> .name = "bmi270",
>> + .pm = pm_ptr(&bmi270_core_pm_ops),
> Ditto.
>> .of_match_table = bmi270_of_match,
>> },
>> .probe = bmi270_spi_probe,
I don't know how but your answer was lost in my mail.
Sorry for the late response and thank you for your suggestions,
Denis
next prev parent reply other threads:[~2025-05-24 20:25 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-09 17:15 [PATCH 0/2] iio: fix suspend and resume triggering for bmi160 and bmi270 Denis Benato
2025-05-09 17:15 ` [PATCH 1/2] iio: bmi270: suspend and resume triggering on relevant pm operations Denis Benato
2025-05-12 8:54 ` Andy Shevchenko
2025-05-24 20:25 ` Denis Benato [this message]
2025-05-25 9:33 ` Jonathan Cameron
2025-05-09 17:15 ` [PATCH 2/2] iio: bmi160: " Denis Benato
2025-05-12 8:55 ` Andy Shevchenko
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=cddc4a4f-f982-49ec-a03b-3e26038057fe@gmail.com \
--to=benato.denis96@gmail.com \
--cc=andy@kernel.org \
--cc=derekjohn.clark@gmail.com \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=justin@justinweiss.com \
--cc=lanzano.alex@gmail.com \
--cc=linux-iio@vger.kernel.org \
--cc=nuno.sa@analog.com \
--cc=philm@manjaro.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