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:	Wed, 13 Mar 2013 07:09:50 +0800
From:	Feng Tang <feng.tang@...el.com>
To:	John Stultz <john.stultz@...aro.org>
Cc:	Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...e.hu>,
	"H. Peter Anvin" <hpa@...ux.intel.com>,
	Jason Gunthorpe <jgunthorpe@...idianresearch.com>,
	x86@...nel.org, Len Brown <lenb@...nel.org>,
	"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
	linux-kernel@...r.kernel.org, gong.chen@...ux.intel.com
Subject: Re: [PATCH v4 4/4] timekeeping: utilize the suspend-nonstop
 clocksource to count suspended time

On Tue, Mar 12, 2013 at 02:09:08PM -0700, John Stultz wrote:
> On 03/11/2013 08:56 PM, Feng Tang wrote:
 >  	}
> >-	/* re-base the last cycle value */
> >-	tk->clock->cycle_last = tk->clock->read(tk->clock);
> >+
> >+	if (suspendtime_found)
> >+		__timekeeping_inject_sleeptime(tk, &ts_delta);
> >+
> >+	/* Re-base the last cycle value */
> >+	clock->cycle_last = clock->read(clock);
> It seems like since we unconditionally read the clock above, this
> last line could be reworked to be:
>     clock->cycle_last = cycle_now;
> 
> Which would save re-reading the clocksource.
> 
> If you don't have any objections I'll fold that small change into
> your patch.

No objection at all. Thanks!

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