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, 25 Mar 2009 14:35:00 -0700
From:	Corey Ashford <cjashfor@...ux.vnet.ibm.com>
To:	mingo@...hat.com, hpa@...or.com, paulus@...ba.org,
	linux-kernel@...r.kernel.org, a.p.zijlstra@...llo.nl,
	akpm@...ux-foundation.org, tglx@...utronix.de, mingo@...e.hu
CC:	linux-tip-commits@...r.kernel.org
Subject: Re: [tip:perfcounters/core] perf_counter: record time running and
 time enabled for each counter


Paul Mackerras wrote:
> Commit-ID:  03ced439c94d692363307eeb3abe0bbfa2d08a01
> Gitweb:     http://git.kernel.org/tip/03ced439c94d692363307eeb3abe0bbfa2d08a01
> Author:     Paul Mackerras <paulus@...ba.org>
> AuthorDate: Wed, 25 Mar 2009 22:46:58 +1100
> Committer:  Ingo Molnar <mingo@...e.hu>
> CommitDate: Wed, 25 Mar 2009 13:24:00 +0100
> 
> perf_counter: record time running and time enabled for each counter
[snip]
> These values can be supplied to userspace on a read from the counter.
> Userspace requests that they be supplied after the counter value by
> setting the PERF_FORMAT_TOTAL_TIME_ENABLED and/or
> PERF_FORMAT_TOTAL_TIME_RUNNING bits in the hw_event.read_format field
> when creating the counter.  (There is no way to change the read format
> after the counter is created, though it would be possible to add some
> way to do that.)

This change looks good to me, except:

How do I know which value comes first after the counter value if I have 
both PERF_FORMAT_TOTAL_TIME_ENABLED and PERF_FORMAT_TOTAL_TIME_RUNNING 
set?  Are they in the order of their enum values?  The order should be 
described somewhere.  Is there anything to keep a kernel code change 
from inadvertantly reversing the position of two values at some point in 
the future?

Regards,

- Corey

Corey Ashford
Software Engineer
IBM Linux Technology Center, Linux Toolchain
Beaverton, OR
503-578-3507
cjashfor@...ibm.com

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