[PATCH 2/6] ARM: perf-events: use numeric ID to identify PMU

Jamie Iles jamie.iles at picochip.com
Wed Mar 10 06:03:37 EST 2010


On Wed, Mar 10, 2010 at 10:41:26AM +0000, Will Deacon wrote:
> The ARM perf-events framework provides support for a number of different
> PMUs using struct arm_pmu. The char *name field of this struct can be
> used to identify the PMU, but this is cumbersome if used outside of perf.
> 
> This patch replaces the name string for a PMU with an enum, which holds
> a unique ID for the PMU being represented. This ID can be used to index
> an array of names within perf, so no functionality is lost. The presence
> of the ID field, allows other kernel subsystems [currently oprofile] to
> use their own mappings for the PMU name.
> 
> Cc: Jamie Iles <jamie.iles at picochip.com>
> Cc: Jean Pihet <jpihet at mvista.com>
> Signed-off-by: Will Deacon <will.deacon at arm.com>
Hi Will,

Looks good to me.

Acked-by: Jamie Iles <jamie.iles at picochip.com>

Jamie



More information about the linux-arm-kernel mailing list