]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
PM: runtime: Fix conditional guard definitions
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 20 Oct 2025 15:03:28 +0000 (17:03 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 22 Oct 2025 09:38:11 +0000 (11:38 +0200)
commitdb82b8dbf5f06d7b1abec4e1326ed8c02fa16897
treed35db69705e48aa5c6c62f1ca1d2cbf7737d58d1
parent211ddde0823f1442e4ad052a2f30f050145ccada
PM: runtime: Fix conditional guard definitions

Since pm_runtime_get_active() returns 0 on success, all of the
DEFINE_GUARD_COND() macros in pm_runtime.h need the "_RET == 0"
condition at the end of the argument list or they would not work
correctly.

Fixes: 9a0abc39450a ("PM: runtime: Add auto-cleanup macros for "resume and get" operations")
Reported-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/linux-pm/202510191529.BCyjKlLQ-lkp@intel.com/
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>
Reviewed-by: Dan Williams <dan.j.williams@intel.com>
Tested-by: Farhan Ali <alifm@linux.ibm.com>
Link: https://patch.msgid.link/5943878.DvuYhMxLoT@rafael.j.wysocki
include/linux/pm_runtime.h