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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Mon, 6 Aug 2012 10:42:58 -0400 (EDT)
From:	Alan Stern <stern@...land.harvard.edu>
To:	"Rafael J. Wysocki" <rjw@...k.pl>,
	Thomas Gleixner <tglx@...utronix.de>
cc:	Todd Poynor <toddpoynor@...gle.com>,
	Linux-pm mailing list <linux-pm@...r.kernel.org>,
	Kernel development list <linux-kernel@...r.kernel.org>,
	<arve@...roid.com>
Subject: Re: [PATCH v2] PM / Sleep: Print name of wakeup source that aborts
 suspend

On Mon, 6 Aug 2012, Rafael J. Wysocki wrote:

> On Monday, August 06, 2012, Alan Stern wrote:
> > On Sun, 5 Aug 2012, Rafael J. Wysocki wrote:
> > 
> > > > v2
> > > > use ktime_to_ns() instead of comparisons on .tv64 field
> > 
> > What is the reason for this?  It apparently adds complexity and code 
> > (on non-64-bit systems) to no purpose.
> 
> I don't think accessing the internals of ktime_t is appropriate,
> even though avoiding that may result in some computational cost.

I asked this question because I recently added some code that does the
very same thing, using the .tv64 field instead of doing any
conversions.

Thomas, is there any general advice on how to compare two ktime_t
values?  Is it acceptable for general code to use the .tv64 field for
this?  The comments in ktime.h say that the encoding was chosen partly
for this very reason.

Alan Stern

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ