Thread (6 messages) 6 messages, 4 authors, 1d ago

Re: [PATCH 1/1] PM: runtime: change stub pm_runtime_get_if_active() return 1 when !CONFIG_PM

flat view

From: Sakari Ailus <sakari.ailus@linux.intel.com>
Date: 2026-10-30 08:57:56
Also in: dri-devel, imx, intel-gfx, intel-xe, linux-arm-kernel, linux-arm-msm, linux-hwmon, linux-iommu, linux-media, linux-pm, linux-staging, linux-usb

Hi Frank,

Thanks for the patch.

On Thu, Oct 29, 2026 at 12:30:37PM -0400, Frank.Li@oss.nxp.com wrote:
From: Frank Li <Frank.Li@nxp.com>

When CONFIG_PM is not enabled, all devices runtime PM state should be
treated as active.

__pm_runtime_resume() returns 1 (called by pm_runtime_get()).
pm_runtime_get_if_active() is the try-and-get version of pm_runtime_get().
stub pm_runtime_active() also returns true. So pm_runtime_get_if_active()
should return the same value as the stub pm_runtime_get(), which is 1.
Shouldn't the same change be done to pm_runtime_get_if_in_use()? It's
otherwise the same, except that it requires also the use count to be
non-zero.

-- 
Regards,

Sakari Ailus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help