Re: [PATCH v2 07/17] iio: adc: ti-ads1015: Discard pm_runtime_put_autosuspend() return values

From: Jonathan Cameron

Date: Sun Oct 25 2026 - 23:28:48 EST


On Wed, 21 Oct 2026 16:57:08 -0700
Brian Norris <briannorris@xxxxxxxxxxxx> wrote:

> This driver propagates the return value of pm_runtime_put_autosuspend(),
> which is not particularly useful.
>
> Returning an error code from pm_runtime_put_autosuspend() merely means
> that it has not queued up a timer or work item to check whether or not
> the device can be suspended and there are many perfectly valid
> situations in which that can happen, like after writing "on" to the
> device's runtime PM "control" attribute in sysfs for one example.
>
> For this reason, modify this driver to simply discard the
> pm_runtime_put_autosuspend() return value. Inline
> ads1015_set_power_state() while we're at it, since its behavior is now
> the same with and without CONFIG_PM, and it is otherwise trivial.
>
> This will facilitate a planned change of the
> pm_runtime_put_autosuspend() return type to void in the future, similar
> to commit 3afd8df02433 ("PM: runtime: Change pm_runtime_put() return
> type to void").
>
> Signed-off-by: Brian Norris <briannorris@xxxxxxxxxxxx>
Fairly simple one and clearly a net gain.
Applied.