aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm64/include/asm/topology.h
diff options
context:
space:
mode:
authorIonela Voinescu <ionela.voinescu@arm.com>2020-11-06 12:53:32 +0000
committerCatalin Marinas <catalin.marinas@arm.com>2020-11-13 20:05:10 +0000
commit4b9cf23c179a27659a95c094ace658bb92f146e5 (patch)
tree6f58d2c1e5ec88249d376f6af9e0accb39512183 /arch/arm64/include/asm/topology.h
parentLinux 5.10-rc3 (diff)
downloadlinux-dev-4b9cf23c179a27659a95c094ace658bb92f146e5.tar.xz
linux-dev-4b9cf23c179a27659a95c094ace658bb92f146e5.zip
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>
Diffstat (limited to 'arch/arm64/include/asm/topology.h')
-rw-r--r--arch/arm64/include/asm/topology.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm64/include/asm/topology.h b/arch/arm64/include/asm/topology.h
index 11a465243f66..3b8dca4eb08d 100644
--- a/arch/arm64/include/asm/topology.h
+++ b/arch/arm64/include/asm/topology.h
@@ -16,12 +16,14 @@ int pcibus_to_node(struct pci_bus *bus);
#include <linux/arch_topology.h>
+void update_freq_counters_refs(void);
+void topology_scale_freq_tick(void);
+
#ifdef CONFIG_ARM64_AMU_EXTN
/*
* Replace task scheduler's default counter-based
* frequency-invariance scale factor setting.
*/
-void topology_scale_freq_tick(void);
#define arch_scale_freq_tick topology_scale_freq_tick
#endif /* CONFIG_ARM64_AMU_EXTN */