powerpc/perf: Add blacklisted events for Power9 DD2.2
authorMadhavan Srinivasan <maddy@linux.vnet.ibm.com>
Sun, 4 Mar 2018 11:56:28 +0000 (17:26 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 27 Mar 2018 08:25:11 +0000 (19:25 +1100)
These events either do not count, or do not count correctly, so to
prevent user confusion block counting them at all.

Signed-off-by: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
[mpe: Change log]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/perf/power9-events-list.h
arch/powerpc/perf/power9-pmu.c

index 9d7a16a943a8aed68dfc69bb46646cb26b3a3dd4..7de344b7d9cc262472db1c3b3d068ad37e5d556d 100644 (file)
@@ -82,3 +82,18 @@ EVENT(PM_RADIX_PWC_L3_HIT,                   0x3f056)
 EVENT(PM_RUN_CYC_SMT2_MODE,                    0x3006c)
 EVENT(PM_TM_TX_PASS_RUN_INST,                  0x4e014)
 EVENT(PM_DISP_HELD_SYNC_HOLD,                  0x4003c)
+EVENT(PM_DTLB_MISS_16G,                                0x1c058)
+EVENT(PM_DERAT_MISS_2M,                                0x1c05a)
+EVENT(PM_DTLB_MISS_2M,                         0x1c05c)
+EVENT(PM_MRK_DTLB_MISS_1G,                     0x1d15c)
+EVENT(PM_DTLB_MISS_4K,                         0x2c056)
+EVENT(PM_DERAT_MISS_1G,                                0x2c05a)
+EVENT(PM_MRK_DERAT_MISS_2M,                    0x2d152)
+EVENT(PM_MRK_DTLB_MISS_4K,                     0x2d156)
+EVENT(PM_MRK_DTLB_MISS_16G,                    0x2d15e)
+EVENT(PM_DTLB_MISS_64K,                                0x3c056)
+EVENT(PM_MRK_DERAT_MISS_1G,                    0x3d152)
+EVENT(PM_MRK_DTLB_MISS_64K,                    0x3d156)
+EVENT(PM_DTLB_MISS_16M,                                0x4c056)
+EVENT(PM_DTLB_MISS_1G,                         0x4c05a)
+EVENT(PM_MRK_DTLB_MISS_16M,                    0x4c15e)
index 3847607c16f077ae413163ba71f7b38ada8255bc..2ca0b33b4efb27fac48b1ba0dc6851afcf312efc 100644 (file)
@@ -121,6 +121,25 @@ int p9_dd21_bl_ev[] = {
        PM_DISP_HELD_SYNC_HOLD,
 };
 
+int p9_dd22_bl_ev[] = {
+       PM_DTLB_MISS_16G,
+       PM_DERAT_MISS_2M,
+       PM_DTLB_MISS_2M,
+       PM_MRK_DTLB_MISS_1G,
+       PM_DTLB_MISS_4K,
+       PM_DERAT_MISS_1G,
+       PM_MRK_DERAT_MISS_2M,
+       PM_MRK_DTLB_MISS_4K,
+       PM_MRK_DTLB_MISS_16G,
+       PM_DTLB_MISS_64K,
+       PM_MRK_DERAT_MISS_1G,
+       PM_MRK_DTLB_MISS_64K,
+       PM_DISP_HELD_SYNC_HOLD,
+       PM_DTLB_MISS_16M,
+       PM_DTLB_MISS_1G,
+       PM_MRK_DTLB_MISS_16M,
+};
+
 /* Table of alternatives, sorted by column 0 */
 static const unsigned int power9_event_alternatives[][MAX_ALT] = {
        { PM_INST_DISP,                 PM_INST_DISP_ALT },
@@ -475,6 +494,9 @@ static int __init init_power9_pmu(void)
                if ((PVR_CFG(pvr) == 2) && (PVR_MIN(pvr) == 1)) {
                        power9_pmu.blacklist_ev = p9_dd21_bl_ev;
                        power9_pmu.n_blacklist_ev = ARRAY_SIZE(p9_dd21_bl_ev);
+               } else if ((PVR_CFG(pvr) == 2) && (PVR_MIN(pvr) == 2)) {
+                       power9_pmu.blacklist_ev = p9_dd22_bl_ev;
+                       power9_pmu.n_blacklist_ev = ARRAY_SIZE(p9_dd22_bl_ev);
                }
        }