[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250704100914.000042db@huawei.com>
Date: Fri, 4 Jul 2025 10:09:14 +0100
From: Jonathan Cameron <Jonathan.Cameron@...wei.com>
To: Sakari Ailus <sakari.ailus@...ux.intel.com>
CC: Linus Walleij <linus.walleij@...aro.org>, Jonathan Cameron
<jic23@...nel.org>, David Lechner <dlechner@...libre.com>, Nuno
Sá <nuno.sa@...log.com>, Andy Shevchenko
<andy@...nel.org>, Eugen Hristev <eugen.hristev@...aro.org>, Nicolas Ferre
<nicolas.ferre@...rochip.com>, Alexandre Belloni
<alexandre.belloni@...tlin.com>, Claudiu Beznea <claudiu.beznea@...on.dev>,
Cai Huoqing <cai.huoqing@...ux.dev>, Haibo Chen <haibo.chen@....com>, "Shawn
Guo" <shawnguo@...nel.org>, Sascha Hauer <s.hauer@...gutronix.de>,
Pengutronix Kernel Team <kernel@...gutronix.de>, Fabio Estevam
<festevam@...il.com>, Marek Vasut <marek.vasut@...il.com>, "Geert
Uytterhoeven" <geert+renesas@...der.be>, Magnus Damm <magnus.damm@...il.com>,
Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>, Maxime Coquelin
<mcoquelin.stm32@...il.com>, Alexandre Torgue <alexandre.torgue@...s.st.com>,
Chen-Yu Tsai <wens@...e.org>, "Jernej Skrabec" <jernej.skrabec@...il.com>,
Samuel Holland <samuel@...lland.org>, Francesco Dolcini
<francesco@...cini.it>, João Paulo
Gonçalves <jpaulo.silvagoncalves@...il.com>, "Jiri Slaby
(SUSE)" <jirislaby@...nel.org>, Fabrice Gasnier
<fabrice.gasnier@...s.st.com>, "Rob Herring (Arm)" <robh@...nel.org>, Uwe
Kleine-König <u.kleine-koenig@...libre.com>, "Mike
Looijmans" <mike.looijmans@...ic.nl>, Olivier Moysan
<olivier.moysan@...s.st.com>, Christophe JAILLET
<christophe.jaillet@...adoo.fr>, Julien Stephan <jstephan@...libre.com>,
<linux-arm-kernel@...ts.infradead.org>, <linux-iio@...r.kernel.org>,
<linux-kernel@...r.kernel.org>, <imx@...ts.linux.dev>,
<linux-renesas-soc@...r.kernel.org>,
<linux-stm32@...md-mailman.stormreply.com>, <linux-sunxi@...ts.linux.dev>
Subject: Re: [PATCH 28/80] iio: adc: Remove redundant
pm_runtime_mark_last_busy() calls
On Fri, 4 Jul 2025 10:54:19 +0300
Sakari Ailus <sakari.ailus@...ux.intel.com> wrote:
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
>
> Signed-off-by: Sakari Ailus <sakari.ailus@...ux.intel.com>
> ---
> The cover letter of the set can be found here
> <URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.
>
> In brief, this patch depends on PM runtime patches adding marking the last
> busy timestamp in autosuspend related functions. The patches are here, on
> rc2:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
> pm-runtime-6.17-rc1
>
> drivers/iio/adc/ab8500-gpadc.c | 1 -
> drivers/iio/adc/at91-sama5d2_adc.c | 10 ----------
> drivers/iio/adc/imx8qxp-adc.c | 2 --
> drivers/iio/adc/imx93_adc.c | 1 -
> drivers/iio/adc/rcar-gyroadc.c | 1 -
> drivers/iio/adc/rzg2l_adc.c | 3 ---
> drivers/iio/adc/stm32-adc-core.c | 1 -
> drivers/iio/adc/stm32-adc.c | 7 -------
> drivers/iio/adc/sun4i-gpadc-iio.c | 2 --
> drivers/iio/adc/ti-ads1015.c | 1 -
> drivers/iio/adc/ti-ads1100.c | 1 -
> drivers/iio/adc/ti-ads1119.c | 2 --
> 12 files changed, 32 deletions(-)
>
> diff --git a/drivers/iio/adc/ab8500-gpadc.c b/drivers/iio/adc/ab8500-gpadc.c
> index f3b057f92310..8eaa1dd6a89b 100644
> --- a/drivers/iio/adc/ab8500-gpadc.c
> +++ b/drivers/iio/adc/ab8500-gpadc.c
> @@ -607,7 +607,6 @@ static int ab8500_gpadc_read(struct ab8500_gpadc *gpadc,
> }
>
> /* This eventually drops the regulator */
> - pm_runtime_mark_last_busy(gpadc->dev);
> pm_runtime_put_autosuspend(gpadc->dev);
>
> return (high_data << 8) | low_data;
> diff --git a/drivers/iio/adc/at91-sama5d2_adc.c b/drivers/iio/adc/at91-sama5d2_adc.c
> index c3450246730e..67846fefe21a 100644
> --- a/drivers/iio/adc/at91-sama5d2_adc.c
> +++ b/drivers/iio/adc/at91-sama5d2_adc.c
> @@ -896,7 +896,6 @@ static int at91_adc_config_emr(struct at91_adc_state *st,
> emr |= osr | AT91_SAMA5D2_TRACKX(trackx);
> at91_adc_writel(st, EMR, emr);
>
> - pm_runtime_mark_last_busy(st->dev);
> pm_runtime_put_autosuspend(st->dev);
>
> st->oversampling_ratio = oversampling_ratio;
> @@ -971,7 +970,6 @@ static int at91_adc_configure_touch(struct at91_adc_state *st, bool state)
> AT91_SAMA5D2_IER_PEN | AT91_SAMA5D2_IER_NOPEN);
> at91_adc_writel(st, TSMR, 0);
>
> - pm_runtime_mark_last_busy(st->dev);
> pm_runtime_put_autosuspend(st->dev);
> return 0;
> }
> @@ -1143,7 +1141,6 @@ static int at91_adc_configure_trigger(struct iio_trigger *trig, bool state)
> at91_adc_configure_trigger_registers(st, state);
>
> if (!state) {
> - pm_runtime_mark_last_busy(st->dev);
Getting familiar. I'll not comment on other cases but {} should go here.
> pm_runtime_put_autosuspend(st->dev);
> }
Please fix all those up and post a v2 series for IIO.
I'd guess similar are present in other subsystems though so may well
need a v2 as well with the excess brackets dropped.
Jonathan
Powered by blists - more mailing lists