sw64: perf: fix raw event count
Sunway inclusion category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I56X48 -------------------------------- To read raw event count, perf stat calls sw64_pmu_start() to start the event and then calls sw64_perf_event_set_period() to set a new period to sample over. It used to initialize hwc.prev_count and PMC with different values and this will result in error sample values. To fix this problem, initialize them to 0 consistently. Signed-off-by:He Chuyue <hechuyue@wxiat.com> Signed-off-by:
Gu Zitao <guzitao@wxiat.com>
Loading
Please sign in to comment