BACKPORT: arm64: wrap and generalise counter read functions
In preparation for other uses of Activity Monitors (AMU) cycle counters, place counter read functionality in generic functions that can reused: read_corecnt() and read_constcnt(). As a result, implement update_freq_counters_refs() to replace init_cpu_freq_invariance_counters() and both initialise and update the per-cpu reference variables. Signed-off-by:Ionela Voinescu <ionela.voinescu@arm.com> Reviewed-by:
Sudeep Holla <sudeep.holla@arm.com> Cc: Will Deacon <will@kernel.org> Link: https://lore.kernel.org/r/20201106125334.21570-2-ionela.voinescu@arm.com Signed-off-by:
Catalin Marinas <catalin.marinas@arm.com> (cherry picked from commit 4b9cf23c) Conflicts: arch/arm64/kernel/cpufeature.c BUG=b:249685960 TEST=Build Change-Id: I3f3d02bce23d1990148b33f16ce9977c5ed5db65 Signed-off-by:
Masami Hiramatsu <mhiramat@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/3939325 Reviewed-by:
Suleiman Souhlal <suleiman@chromium.org>
Loading
Please sign in to comment