summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWill Song <jinpengsong@google.com>2024-02-08 13:37:09 -0800
committerWill Song <jinpengsong@google.com>2024-03-04 19:09:06 +0000
commit5e2cff35ba9959117fa0ba281ba8592abdfc184c (patch)
tree19d4949e9e999d50078944cccb4dadc29127eaa3
parent92f652ae1a23b59b4d45b6de78e1d55d10fe9be2 (diff)
downloadgs-5e2cff35ba9959117fa0ba281ba8592abdfc184c.tar.gz
drivers: performance: Add Google Perf Mon Module
Add module for Google Performance Monitor. Bug: 325274590 Bug: 262894231 Test: Build + Flash Change-Id: I398261f1dc9f00aad39afb9db3f385e797f12c66 Signed-off-by: Will Song <jinpengsong@google.com>
-rw-r--r--Kbuild2
-rw-r--r--Kconfig.ext2
-rw-r--r--drivers/performance/gs_perf_mon/Kbuild6
-rw-r--r--drivers/performance/gs_perf_mon/Kconfig12
-rw-r--r--vendor_kernel_boot_modules.zuma1
5 files changed, 23 insertions, 0 deletions
diff --git a/Kbuild b/Kbuild
index 1607a9db4..ee88e0da8 100644
--- a/Kbuild
+++ b/Kbuild
@@ -60,6 +60,8 @@ obj-y += drivers/clocksource/
obj-y += drivers/devfreq/google/
+obj-y += drivers/performance/gs_perf_mon/
+
obj-y += drivers/iio/
obj-y += drivers/staging/android/
diff --git a/Kconfig.ext b/Kconfig.ext
index ef8dccd23..24dcac410 100644
--- a/Kconfig.ext
+++ b/Kconfig.ext
@@ -54,6 +54,8 @@ source "$(KCONFIG_EXT_PREFIX)drivers/cpufreq/Kconfig"
source "$(KCONFIG_EXT_PREFIX)drivers/devfreq/google/Kconfig"
+source "$(KCONFIG_EXT_PREFIX)drivers/performance/gs_perf_mon/Kconfig"
+
source "$(KCONFIG_EXT_PREFIX)drivers/iio/Kconfig"
source "$(KCONFIG_EXT_PREFIX)drivers/phy/Kconfig"
diff --git a/drivers/performance/gs_perf_mon/Kbuild b/drivers/performance/gs_perf_mon/Kbuild
new file mode 100644
index 000000000..bbdd82cb5
--- /dev/null
+++ b/drivers/performance/gs_perf_mon/Kbuild
@@ -0,0 +1,6 @@
+# Google Performance Monitor
+
+ccflags-y := -DDYNAMIC_DEBUG_MODULE
+ccflags-y += -I$(srctree)/drivers/performance
+
+obj-$(CONFIG_GS_PERF_MON) += gs_perf_mon.o
diff --git a/drivers/performance/gs_perf_mon/Kconfig b/drivers/performance/gs_perf_mon/Kconfig
new file mode 100644
index 000000000..b4c4d0457
--- /dev/null
+++ b/drivers/performance/gs_perf_mon/Kconfig
@@ -0,0 +1,12 @@
+# SPDX-License-Identifier: GPL-2.0-only
+
+config GS_PERF_MON
+ tristate "Google CPU Performance Monitor"
+ default n
+ help
+ A monitoring module to provide high resolution CPU state info.
+ The monitor makes use of PMU/AMU events provided by the ARM cores
+ and hooks from CPU state change functions to supply fine
+ grained CPU information. Some example clients are memory latency
+ governors. WARNING: this monitor allocates PMU counters so it can
+ conflict with other profiling tools. \ No newline at end of file
diff --git a/vendor_kernel_boot_modules.zuma b/vendor_kernel_boot_modules.zuma
index 384b7a128..1451dfa26 100644
--- a/vendor_kernel_boot_modules.zuma
+++ b/vendor_kernel_boot_modules.zuma
@@ -77,6 +77,7 @@ governor_memlat.ko
gpu_cooling.ko
gs-chipid.ko
gs_acpm.ko
+gs_perf_mon.ko
pixel_metrics.ko
gs_thermal.ko
gsa.ko