diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2020-04-15 20:00:45 +0300 |
---|---|---|
committer | Petr Mladek <pmladek@suse.com> | 2020-05-20 15:54:26 +0300 |
commit | 4a60f58ee00266ebee652e991954e48d060ea950 (patch) | |
tree | 732eaaa7934a4d4946406ec56cbccc229d044f59 /drivers/firmware/raspberrypi.c | |
parent | 7daac5b2fdf88e3c3e84cf0d577f524beb0244ab (diff) | |
download | linux-4a60f58ee00266ebee652e991954e48d060ea950.tar.xz |
ARM: bcm2835: Switch to use %ptT
Use %ptT instead of open coded variant to print content of
time64_t type in human readable format.
Link: https://lore.kernel.org/r/20200415170046.33374-3-andriy.shevchenko@linux.intel.com
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Rewieved-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Petr Mladek <pmladek@suse.com>
Diffstat (limited to 'drivers/firmware/raspberrypi.c')
-rw-r--r-- | drivers/firmware/raspberrypi.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/firmware/raspberrypi.c b/drivers/firmware/raspberrypi.c index da26a584dca0..a3e85186f8e6 100644 --- a/drivers/firmware/raspberrypi.c +++ b/drivers/firmware/raspberrypi.c @@ -182,16 +182,10 @@ rpi_firmware_print_firmware_revision(struct rpi_firmware *fw) RPI_FIRMWARE_GET_FIRMWARE_REVISION, &packet, sizeof(packet)); - if (ret == 0) { - struct tm tm; - - time64_to_tm(packet, 0, &tm); + if (ret) + return; - dev_info(fw->cl.dev, - "Attached to firmware from %04ld-%02d-%02d %02d:%02d\n", - tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, - tm.tm_hour, tm.tm_min); - } + dev_info(fw->cl.dev, "Attached to firmware from %ptT\n", &packet); } static void |