pps: Switch to use %ptSp

Use %ptSp instead of open coded variants to print content of
struct timespec64 in human readable format.

Acked-by: Rodolfo Giometti <giometti@enneenne.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://patch.msgid.link/20251113150217.3030010-17-andriy.shevchenko@linux.intel.com
Signed-off-by: Petr Mladek <pmladek@suse.com>
This commit is contained in:
Andy Shevchenko 2025-11-13 15:32:30 +01:00 committed by Petr Mladek
parent 3bc02fe0b8
commit b1e7286eee
2 changed files with 2 additions and 4 deletions

View File

@ -80,8 +80,7 @@ static enum hrtimer_restart hrtimer_event(struct hrtimer *timer)
/* check if we are late */
if (expire_time.tv_sec != ts1.tv_sec || ts1.tv_nsec > lim) {
local_irq_restore(flags);
pr_err("we are late this time %lld.%09ld\n",
(s64)ts1.tv_sec, ts1.tv_nsec);
pr_err("we are late this time %ptSp\n", &ts1);
goto done;
}

View File

@ -166,8 +166,7 @@ void pps_event(struct pps_device *pps, struct pps_event_time *ts, int event,
/* check event type */
BUG_ON((event & (PPS_CAPTUREASSERT | PPS_CAPTURECLEAR)) == 0);
dev_dbg(&pps->dev, "PPS event at %lld.%09ld\n",
(s64)ts->ts_real.tv_sec, ts->ts_real.tv_nsec);
dev_dbg(&pps->dev, "PPS event at %ptSp\n", &ts->ts_real);
timespec_to_pps_ktime(&ts_real, ts->ts_real);