lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 12 Jun 2011 14:12:09 +0200
From:	"Rafael J. Wysocki" <rjw@...k.pl>
To:	"Justin P. Mattock" <justinmattock@...il.com>
Cc:	linux-pm@...ts.linux-foundation.org, linux-kernel@...r.kernel.org,
	Len Brown <lenb@...nel.org>
Subject: Re: [PATCH]drivers:base:power:trace.c Add "UTC" Coordinated Universal Time to the printk.

Hi,

On Thursday, June 09, 2011, Justin P. Mattock wrote:
> From: "Justin P. Mattock" <justinmattock@...il.com>
> 
> sounds stupid, but taking a glance at the time, and seeing the wrong time, or what seemed 
> wrong in dmesg, caused me to go into total check the time clock panic mode.. So the patch below adds:
> "UTC" Coordinated Universal Time abreviation to the printk so people like me dont flip out over the time!
> 
> before:
> [    0.114915] Time:  1:47:03  Date: 06/09/11
> 
> after:
> [    0.114728] Time:  5:46:02 UTC Date: 06/09/11
> 
> Signed-off-by: Justin P. Mattock <justinmattock@...il.com>

I suspect the goal is to mark messages printed by the PM trace code so that
they can be easily distinguished from messages from other sources to avoid
confusion.  Why do you think it's a good idea to use the "UTC" string for
this purpose?  The time printed in those messages need not be UTC.

It would be better to simply print "RTC time: ..., date: ..." IMO.

Thanks,
Rafael


> ---
>  drivers/base/power/trace.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/base/power/trace.c b/drivers/base/power/trace.c
> index c80e138..009f459 100644
> --- a/drivers/base/power/trace.c
> +++ b/drivers/base/power/trace.c
> @@ -112,7 +112,7 @@ static unsigned int read_magic_time(void)
>  	unsigned int val;
>  
>  	get_rtc_time(&time);
> -	pr_info("Time: %2d:%02d:%02d  Date: %02d/%02d/%02d\n",
> +	pr_info("Time: %2d:%02d:%02d UTC Date: %02d/%02d/%02d\n",
>  		time.tm_hour, time.tm_min, time.tm_sec,
>  		time.tm_mon + 1, time.tm_mday, time.tm_year % 100);
>  	val = time.tm_year;				/* 100 years */
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists