Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-21 Thread Robin Murphy
On 21/05/18 15:41, Suzuki K Poulose wrote: On 21/05/18 15:00, Robin Murphy wrote: On 21/05/18 14:42, Suzuki K Poulose wrote: On 18/05/18 16:57, Suzuki K Poulose wrote: Hi Robin, On 18/05/18 14:49, Robin Murphy wrote: On 18/05/18 11:22, Suzuki K Poulose wrote: Add support for chained event c

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-21 Thread Suzuki K Poulose
On 21/05/18 15:00, Robin Murphy wrote: On 21/05/18 14:42, Suzuki K Poulose wrote: On 18/05/18 16:57, Suzuki K Poulose wrote: Hi Robin, On 18/05/18 14:49, Robin Murphy wrote: On 18/05/18 11:22, Suzuki K Poulose wrote: Add support for chained event counters. PMUv3 allows chaining a pair of adj

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-21 Thread Robin Murphy
On 21/05/18 14:42, Suzuki K Poulose wrote: On 18/05/18 16:57, Suzuki K Poulose wrote: Hi Robin, On 18/05/18 14:49, Robin Murphy wrote: On 18/05/18 11:22, Suzuki K Poulose wrote: Add support for chained event counters. PMUv3 allows chaining a pair of adjacent PMU counters (with the lower count

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-21 Thread Suzuki K Poulose
On 18/05/18 16:57, Suzuki K Poulose wrote: Hi Robin, On 18/05/18 14:49, Robin Murphy wrote: On 18/05/18 11:22, Suzuki K Poulose wrote: Add support for chained event counters. PMUv3 allows chaining a pair of adjacent PMU counters (with the lower counter number being always "even"). The low coun

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-21 Thread Suzuki K Poulose
On 18/05/18 15:57, Robin Murphy wrote: One more thing now that I've actually looked at the Arm ARM... On 18/05/18 11:22, Suzuki K Poulose wrote: [...] +static inline void armv8pmu_write_event_type(struct perf_event *event) +{ +    struct hw_perf_event *hwc = &event->hw; +    int idx = hwc->idx;

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-18 Thread Suzuki K Poulose
Hi Robin, On 18/05/18 14:49, Robin Murphy wrote: On 18/05/18 11:22, Suzuki K Poulose wrote: Add support for chained event counters. PMUv3 allows chaining a pair of adjacent PMU counters (with the lower counter number being always "even"). The low counter is programmed to count the event of inte

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-18 Thread Robin Murphy
One more thing now that I've actually looked at the Arm ARM... On 18/05/18 11:22, Suzuki K Poulose wrote: [...] +static inline void armv8pmu_write_event_type(struct perf_event *event) +{ + struct hw_perf_event *hwc = &event->hw; + int idx = hwc->idx; + + /* +* For chain

Re: [PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-18 Thread Robin Murphy
On 18/05/18 11:22, Suzuki K Poulose wrote: Add support for chained event counters. PMUv3 allows chaining a pair of adjacent PMU counters (with the lower counter number being always "even"). The low counter is programmed to count the event of interest and the high counter(odd numbered) is programm

[PATCH 6/6] arm64: perf: Add support for chaining counters

2018-05-18 Thread Suzuki K Poulose
Add support for chained event counters. PMUv3 allows chaining a pair of adjacent PMU counters (with the lower counter number being always "even"). The low counter is programmed to count the event of interest and the high counter(odd numbered) is programmed with a special event code (0x1e - Chain).