Skip to content

Commit

Permalink
PM: sleep: Take advantage of %ps to simplify debug output
Browse files Browse the repository at this point in the history
initcall_debug previous and new output:

...PM: calling pci_pm_suspend+0x0/0x1b0 @ 3233, parent: pci0000:00

...PM: calling pci_pm_suspend @ 3233, parent: pci0000:00

Signed-off-by: Len Brown <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
  • Loading branch information
lenb authored and rafaeljw committed Apr 8, 2024
1 parent 3642c7e commit 5b9eda2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/base/power/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ static ktime_t initcall_debug_start(struct device *dev, void *cb)
if (!pm_print_times_enabled)
return 0;

dev_info(dev, "calling %pS @ %i, parent: %s\n", cb,
dev_info(dev, "calling %ps @ %i, parent: %s\n", cb,
task_pid_nr(current),
dev->parent ? dev_name(dev->parent) : "none");
return ktime_get();
Expand All @@ -223,7 +223,7 @@ static void initcall_debug_report(struct device *dev, ktime_t calltime,
return;

rettime = ktime_get();
dev_info(dev, "%pS returned %d after %Ld usecs\n", cb, error,
dev_info(dev, "%ps returned %d after %Ld usecs\n", cb, error,
(unsigned long long)ktime_us_delta(rettime, calltime));
}

Expand Down Expand Up @@ -1927,7 +1927,7 @@ EXPORT_SYMBOL_GPL(dpm_suspend_start);
void __suspend_report_result(const char *function, struct device *dev, void *fn, int ret)
{
if (ret)
dev_err(dev, "%s(): %pS returns %d\n", function, fn, ret);
dev_err(dev, "%s(): %ps returns %d\n", function, fn, ret);
}
EXPORT_SYMBOL_GPL(__suspend_report_result);

Expand Down

0 comments on commit 5b9eda2

Please sign in to comment.