if (ret)
return ret;
- dev_dbg(dev, "Set mcp795: %04d-%02d-%02d(%d) %02d:%02d:%02d\n",
- tim->tm_year + 1900, tim->tm_mon, tim->tm_mday,
- tim->tm_wday, tim->tm_hour, tim->tm_min, tim->tm_sec);
+ dev_dbg(dev, "Set mcp795: %ptR\n", tim);
return 0;
}
tim->tm_mon = bcd2bin(data[5] & 0x1F) - 1;
tim->tm_year = bcd2bin(data[6]) + 100; /* Assume we are in 20xx */
- dev_dbg(dev, "Read from mcp795: %04d-%02d-%02d(%d) %02d:%02d:%02d\n",
- tim->tm_year + 1900, tim->tm_mon, tim->tm_mday,
- tim->tm_wday, tim->tm_hour, tim->tm_min, tim->tm_sec);
+ dev_dbg(dev, "Read from mcp795: %ptR\n", tim);
return 0;
}
return ret;
dev_dbg(dev, "Alarm IRQ armed\n");
}
- dev_dbg(dev, "Set alarm: %02d-%02d(%d) %02d:%02d:%02d\n",
- alm->time.tm_mon, alm->time.tm_mday, alm->time.tm_wday,
- alm->time.tm_hour, alm->time.tm_min, alm->time.tm_sec);
+ dev_dbg(dev, "Set alarm: %ptRdr(%d) %ptRt\n",
+ &alm->time, alm->time.tm_wday, &alm->time);
return 0;
}
alm->time.tm_isdst = -1;
alm->time.tm_yday = -1;
- dev_dbg(dev, "Read alarm: %02d-%02d(%d) %02d:%02d:%02d\n",
- alm->time.tm_mon, alm->time.tm_mday, alm->time.tm_wday,
- alm->time.tm_hour, alm->time.tm_min, alm->time.tm_sec);
+ dev_dbg(dev, "Read alarm: %ptRdr(%d) %ptRt\n",
+ &alm->time, alm->time.tm_wday, &alm->time);
return 0;
}