PM: runtime: Replace pm_runtime_callbacks_present()
The name of pm_runtime_callbacks_present() is confusing, because it suggests that the device has PM-runtime callbacks if 'true' is returned by that function, but in fact that may not be the case, so replace it with pm_runtime_has_no_callbacks() which is not ambiguous. No functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>
This commit is contained in:
@ -666,7 +666,7 @@ int dpm_sysfs_add(struct device *dev)
|
||||
if (rc)
|
||||
return rc;
|
||||
|
||||
if (pm_runtime_callbacks_present(dev)) {
|
||||
if (!pm_runtime_has_no_callbacks(dev)) {
|
||||
rc = sysfs_merge_group(&dev->kobj, &pm_runtime_attr_group);
|
||||
if (rc)
|
||||
goto err_out;
|
||||
@ -709,7 +709,7 @@ int dpm_sysfs_change_owner(struct device *dev, kuid_t kuid, kgid_t kgid)
|
||||
if (rc)
|
||||
return rc;
|
||||
|
||||
if (pm_runtime_callbacks_present(dev)) {
|
||||
if (!pm_runtime_has_no_callbacks(dev)) {
|
||||
rc = sysfs_group_change_owner(
|
||||
&dev->kobj, &pm_runtime_attr_group, kuid, kgid);
|
||||
if (rc)
|
||||
|
Reference in New Issue
Block a user