]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
x86, perf: Fix few cosmetic dabs for P4 pmu (comments and constantify)
authorCyrill Gorcunov <gorcunov@gmail.com>
Thu, 18 Mar 2010 21:12:56 +0000 (00:12 +0300)
committerIngo Molnar <mingo@elte.hu>
Thu, 18 Mar 2010 21:17:46 +0000 (22:17 +0100)
- A few ESCR have escaped fixing at previous attempt.
- p4_escr_map is read only, make it const.

Nothing serious.

Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: Lin Ming <ming.m.lin@intel.com>
LKML-Reference: <20100318211256.GH5062@lenovo>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/include/asm/perf_event_p4.h
arch/x86/kernel/cpu/perf_event_p4.c

index 871249cf4d2bc603c7bac99315892ced31a5340a..2a1a57f7153986b2fcc7a66f72e23008cea93080 100644 (file)
@@ -401,13 +401,13 @@ static inline u32 p4_default_escr_conf(int cpu, int exclude_os, int exclude_usr)
 #define P4_RETIRED_MISPRED_BRANCH_TYPE P4_EVENT_PACK(0x05, 0x02)
        /*
         * MSR_P4_TBPU_ESCR0:   4, 5
-        * MSR_P4_TBPU_ESCR0:   6, 7
+        * MSR_P4_TBPU_ESCR1:   6, 7
         */
 
 #define P4_RETIRED_BRANCH_TYPE         P4_EVENT_PACK(0x04, 0x02)
        /*
         * MSR_P4_TBPU_ESCR0:   4, 5
-        * MSR_P4_TBPU_ESCR0:   6, 7
+        * MSR_P4_TBPU_ESCR1:   6, 7
         */
 
 #define P4_RESOURCE_STALL              P4_EVENT_PACK(0x01, 0x01)
index b7bf9911198c2c59c73036ff1a63c6a36cb6a554..b8a811ab7609b9c1e542d74ce11d0b98560f13eb 100644 (file)
@@ -545,7 +545,7 @@ static void p4_pmu_swap_config_ts(struct hw_perf_event *hwc, int cpu)
 }
 
 /* ESCRs are not sequential in memory so we need a map */
-static unsigned int p4_escr_map[ARCH_P4_TOTAL_ESCR] = {
+static const unsigned int p4_escr_map[ARCH_P4_TOTAL_ESCR] = {
        MSR_P4_ALF_ESCR0,       /*  0 */
        MSR_P4_ALF_ESCR1,       /*  1 */
        MSR_P4_BPU_ESCR0,       /*  2 */