Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ACPI: TAD: Use PM_RUNTIME_ACQUIRE()/PM_RUNTIME_ACQUIRE_ERR()

Use new PM_RUNTIME_ACQUIRE() and PM_RUNTIME_ACQUIRE_ERR() wrapper macros
to make the code look more straightforward.

No intentional functional impact.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Dhruva Gole <d-gole@ti.com>
Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>
[ rjw: Typo fix in the changelog ]
Link: https://patch.msgid.link/2040585.PYKUYFuaPT@rafael.j.wysocki
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

+12 -12
+12 -12
drivers/acpi/acpi_tad.c
··· 90 90 args[0].buffer.pointer = (u8 *)rt; 91 91 args[0].buffer.length = sizeof(*rt); 92 92 93 - ACQUIRE(pm_runtime_active_try, pm)(dev); 94 - if (ACQUIRE_ERR(pm_runtime_active_try, &pm)) 93 + PM_RUNTIME_ACQUIRE(dev, pm); 94 + if (PM_RUNTIME_ACQUIRE_ERR(&pm)) 95 95 return -ENXIO; 96 96 97 97 status = acpi_evaluate_integer(handle, "_SRT", &arg_list, &retval); ··· 137 137 { 138 138 int ret; 139 139 140 - ACQUIRE(pm_runtime_active_try, pm)(dev); 141 - if (ACQUIRE_ERR(pm_runtime_active_try, &pm)) 140 + PM_RUNTIME_ACQUIRE(dev, pm); 141 + if (PM_RUNTIME_ACQUIRE_ERR(&pm)) 142 142 return -ENXIO; 143 143 144 144 ret = acpi_tad_evaluate_grt(dev, rt); ··· 275 275 args[0].integer.value = timer_id; 276 276 args[1].integer.value = value; 277 277 278 - ACQUIRE(pm_runtime_active_try, pm)(dev); 279 - if (ACQUIRE_ERR(pm_runtime_active_try, &pm)) 278 + PM_RUNTIME_ACQUIRE(dev, pm); 279 + if (PM_RUNTIME_ACQUIRE_ERR(&pm)) 280 280 return -ENXIO; 281 281 282 282 status = acpi_evaluate_integer(handle, method, &arg_list, &retval); ··· 322 322 323 323 args[0].integer.value = timer_id; 324 324 325 - ACQUIRE(pm_runtime_active_try, pm)(dev); 326 - if (ACQUIRE_ERR(pm_runtime_active_try, &pm)) 325 + PM_RUNTIME_ACQUIRE(dev, pm); 326 + if (PM_RUNTIME_ACQUIRE_ERR(&pm)) 327 327 return -ENXIO; 328 328 329 329 status = acpi_evaluate_integer(handle, method, &arg_list, &retval); ··· 377 377 378 378 args[0].integer.value = timer_id; 379 379 380 - ACQUIRE(pm_runtime_active_try, pm)(dev); 381 - if (ACQUIRE_ERR(pm_runtime_active_try, &pm)) 380 + PM_RUNTIME_ACQUIRE(dev, pm); 381 + if (PM_RUNTIME_ACQUIRE_ERR(&pm)) 382 382 return -ENXIO; 383 383 384 384 status = acpi_evaluate_integer(handle, "_CWS", &arg_list, &retval); ··· 417 417 418 418 args[0].integer.value = timer_id; 419 419 420 - ACQUIRE(pm_runtime_active_try, pm)(dev); 421 - if (ACQUIRE_ERR(pm_runtime_active_try, &pm)) 420 + PM_RUNTIME_ACQUIRE(dev, pm); 421 + if (PM_RUNTIME_ACQUIRE_ERR(&pm)) 422 422 return -ENXIO; 423 423 424 424 status = acpi_evaluate_integer(handle, "_GWS", &arg_list, &retval);