Perf: Add legacy support for userspace tools

We used the "rs" and "rm" modifiers to access
the L2CC and busmon PMU's before v3.4.

This patch modifies the CFG to keep the backward
compat alive till all tools progress to the
new named PMU interfaces.

Change-Id: I3a36ff8fb588382d445728a69ba790189e73ec40
Signed-off-by: Ashwin Chaugule <ashwinc@codeaurora.org>
diff --git a/tools/perf/util/parse-events.l b/tools/perf/util/parse-events.l
index 1fcf1bb..28e5548 100644
--- a/tools/perf/util/parse-events.l
+++ b/tools/perf/util/parse-events.l
@@ -30,6 +30,17 @@
 	return __value(parse_events_text + 1, 16, PE_RAW);
 }
 
+static int sh_raw(void)
+{
+	return __value(parse_events_text + 2, 16, PE_SH_RAW);
+}
+
+static int fab_raw(void)
+{
+	return __value(parse_events_text + 2, 16, PE_FAB_RAW);
+}
+
+
 static int str(int token)
 {
 	parse_events_lval.str = strdup(parse_events_text);
@@ -107,6 +118,8 @@
 
 mem:			{ return PE_PREFIX_MEM; }
 r{num_raw_hex}		{ return raw(); }
+rs{num_raw_hex}		{ return sh_raw(); }
+rm{num_raw_hex}		{ return fab_raw(); }
 {num_dec}		{ return value(10); }
 {num_hex}		{ return value(16); }