diff options
author | Stephen Rothwell <sfr@canb.auug.org.au> | 2005-09-19 09:21:15 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-09-21 05:21:08 -0400 |
commit | 654810ec899ea5f2fc2138fca1793b603d481ff4 (patch) | |
tree | 7b5e4d411d275a22606b81e0725ebc06acb7bff6 /include | |
parent | a3e48c10cca3287a845435dd8ca58ecbde72d847 (diff) |
[PATCH] powerpc: merge oprofile headers
Merge include/asm-ppc64/oprofile_ipml.h and arch/ppc/oprofile/op_impl.h
into include/asm-powerpc/oprofile_ipml.h
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-powerpc/oprofile_impl.h (renamed from include/asm-ppc64/oprofile_impl.h) | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/include/asm-ppc64/oprofile_impl.h b/include/asm-powerpc/oprofile_impl.h index 50420e715f05..8013cd273ced 100644 --- a/include/asm-ppc64/oprofile_impl.h +++ b/include/asm-powerpc/oprofile_impl.h | |||
@@ -9,31 +9,39 @@ | |||
9 | * 2 of the License, or (at your option) any later version. | 9 | * 2 of the License, or (at your option) any later version. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #ifndef OP_IMPL_H | 12 | #ifndef _ASM_POWERPC_OPROFILE_IMPL_H |
13 | #define OP_IMPL_H 1 | 13 | #define _ASM_POWERPC_OPROFILE_IMPL_H |
14 | 14 | ||
15 | #define OP_MAX_COUNTER 8 | 15 | #define OP_MAX_COUNTER 8 |
16 | 16 | ||
17 | /* Per-counter configuration as set via oprofilefs. */ | 17 | /* Per-counter configuration as set via oprofilefs. */ |
18 | struct op_counter_config { | 18 | struct op_counter_config { |
19 | #ifdef __powerpc64__ | ||
19 | unsigned long valid; | 20 | unsigned long valid; |
21 | #endif | ||
20 | unsigned long enabled; | 22 | unsigned long enabled; |
21 | unsigned long event; | 23 | unsigned long event; |
22 | unsigned long count; | 24 | unsigned long count; |
23 | unsigned long kernel; | 25 | unsigned long kernel; |
26 | #ifdef __powerpc64__ | ||
24 | /* We dont support per counter user/kernel selection */ | 27 | /* We dont support per counter user/kernel selection */ |
28 | #endif | ||
25 | unsigned long user; | 29 | unsigned long user; |
26 | unsigned long unit_mask; | 30 | unsigned long unit_mask; |
27 | }; | 31 | }; |
28 | 32 | ||
29 | /* System-wide configuration as set via oprofilefs. */ | 33 | /* System-wide configuration as set via oprofilefs. */ |
30 | struct op_system_config { | 34 | struct op_system_config { |
35 | #ifdef __powerpc64__ | ||
31 | unsigned long mmcr0; | 36 | unsigned long mmcr0; |
32 | unsigned long mmcr1; | 37 | unsigned long mmcr1; |
33 | unsigned long mmcra; | 38 | unsigned long mmcra; |
39 | #endif | ||
34 | unsigned long enable_kernel; | 40 | unsigned long enable_kernel; |
35 | unsigned long enable_user; | 41 | unsigned long enable_user; |
42 | #ifdef __powerpc64__ | ||
36 | unsigned long backtrace_spinlocks; | 43 | unsigned long backtrace_spinlocks; |
44 | #endif | ||
37 | }; | 45 | }; |
38 | 46 | ||
39 | /* Per-arch configuration */ | 47 | /* Per-arch configuration */ |
@@ -41,7 +49,9 @@ struct op_powerpc_model { | |||
41 | void (*reg_setup) (struct op_counter_config *, | 49 | void (*reg_setup) (struct op_counter_config *, |
42 | struct op_system_config *, | 50 | struct op_system_config *, |
43 | int num_counters); | 51 | int num_counters); |
52 | #ifdef __powerpc64__ | ||
44 | void (*cpu_setup) (void *); | 53 | void (*cpu_setup) (void *); |
54 | #endif | ||
45 | void (*start) (struct op_counter_config *); | 55 | void (*start) (struct op_counter_config *); |
46 | void (*stop) (void); | 56 | void (*stop) (void); |
47 | void (*handle_interrupt) (struct pt_regs *, | 57 | void (*handle_interrupt) (struct pt_regs *, |
@@ -49,6 +59,7 @@ struct op_powerpc_model { | |||
49 | int num_counters; | 59 | int num_counters; |
50 | }; | 60 | }; |
51 | 61 | ||
62 | #ifdef __powerpc64__ | ||
52 | extern struct op_powerpc_model op_model_rs64; | 63 | extern struct op_powerpc_model op_model_rs64; |
53 | extern struct op_powerpc_model op_model_power4; | 64 | extern struct op_powerpc_model op_model_power4; |
54 | 65 | ||
@@ -107,5 +118,6 @@ static inline void ctr_write(unsigned int i, unsigned int val) | |||
107 | break; | 118 | break; |
108 | } | 119 | } |
109 | } | 120 | } |
121 | #endif /* __powerpc64__ */ | ||
110 | 122 | ||
111 | #endif | 123 | #endif /* _ASM_POWERPC_OPROFILE_IMPL_H */ |