CPU frequency indexing function

Instead of writing the whole frequency which as a large number (hundreds
of kilohertz), write an index of that CPU + frequency as represented in
CpuInfo.

Indexing function is extracted to CpuFreqInfo under probes/common.

Bug: 153092449
Test: perfetto_unittests
Change-Id: Ia9e56521c4a3fa8479483c228fd7b90297b250c6
diff --git a/BUILD b/BUILD
index 922f2f0..b957e94 100644
--- a/BUILD
+++ b/BUILD
@@ -172,6 +172,7 @@
         ":src_perfetto_cmd_perfetto_atoms",
         ":src_protozero_protozero",
         ":src_traced_probes_android_log_android_log",
+        ":src_traced_probes_common_common",
         ":src_traced_probes_data_source",
         ":src_traced_probes_filesystem_filesystem",
         ":src_traced_probes_ftrace_format_parser",
@@ -1055,6 +1056,15 @@
     ],
 )
 
+# GN target: //src/traced/probes/common:common
+filegroup(
+    name = "src_traced_probes_common_common",
+    srcs = [
+        "src/traced/probes/common/cpu_freq_info.cc",
+        "src/traced/probes/common/cpu_freq_info.h",
+    ],
+)
+
 # GN target: //src/traced/probes/filesystem:filesystem
 filegroup(
     name = "src_traced_probes_filesystem_filesystem",