Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci-2.6.23
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci-2.6.23
Commits
714cfe78
Commit
714cfe78
authored
Oct 23, 2006
by
Ralf Baechle
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[MIPS] Oprofile: kernel support for the R10000.
Signed-off-by:
Ralf Baechle
<
ralf@linux-mips.org
>
parent
2472d0b5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
5 deletions
+31
-5
arch/mips/oprofile/Makefile
arch/mips/oprofile/Makefile
+1
-0
arch/mips/oprofile/common.c
arch/mips/oprofile/common.c
+3
-0
arch/mips/oprofile/op_model_mipsxx.c
arch/mips/oprofile/op_model_mipsxx.c
+27
-5
No files found.
arch/mips/oprofile/Makefile
View file @
714cfe78
...
...
@@ -12,5 +12,6 @@ oprofile-y := $(DRIVER_OBJS) common.o
oprofile-$(CONFIG_CPU_MIPS32)
+=
op_model_mipsxx.o
oprofile-$(CONFIG_CPU_MIPS64)
+=
op_model_mipsxx.o
oprofile-$(CONFIG_CPU_R10000)
+=
op_model_mipsxx.o
oprofile-$(CONFIG_CPU_SB1)
+=
op_model_mipsxx.o
oprofile-$(CONFIG_CPU_RM9000)
+=
op_model_rm9000.o
arch/mips/oprofile/common.c
View file @
714cfe78
...
...
@@ -83,6 +83,9 @@ int __init oprofile_arch_init(struct oprofile_operations *ops)
case
CPU_74K
:
case
CPU_SB1
:
case
CPU_SB1A
:
case
CPU_R10000
:
case
CPU_R12000
:
case
CPU_R14000
:
lmodel
=
&
op_model_mipsxx_ops
;
break
;
...
...
arch/mips/oprofile/op_model_mipsxx.c
View file @
714cfe78
...
...
@@ -18,7 +18,7 @@
#define M_PERFCTL_SUPERVISOR (1UL << 2)
#define M_PERFCTL_USER (1UL << 3)
#define M_PERFCTL_INTERRUPT_ENABLE (1UL << 4)
#define M_PERFCTL_EVENT(event) ((
event
) << 5)
#define M_PERFCTL_EVENT(event) ((
(event) & 0x3f
) << 5)
#define M_PERFCTL_VPEID(vpe) ((vpe) << 16)
#define M_PERFCTL_MT_EN(filter) ((filter) << 20)
#define M_TC_EN_ALL M_PERFCTL_MT_EN(0)
...
...
@@ -218,13 +218,23 @@ static inline int __n_counters(void)
static
inline
int
n_counters
(
void
)
{
int
counters
=
__n_counters
();
int
counters
;
switch
(
current_cpu_data
.
cputype
)
{
case
CPU_R10000
:
counters
=
2
;
case
CPU_R12000
:
case
CPU_R14000
:
counters
=
4
;
default:
counters
=
__n_counters
();
}
#ifdef CONFIG_MIPS_MT_SMP
if
(
current_cpu_data
.
cputype
==
CPU_34K
)
return
counters
>>
1
;
counters
>>
1
;
#endif
return
counters
;
}
...
...
@@ -284,6 +294,18 @@ static int __init mipsxx_init(void)
op_model_mipsxx_ops
.
cpu_type
=
"mips/5K"
;
break
;
case
CPU_R10000
:
if
((
current_cpu_data
.
processor_id
&
0xff
)
==
0x20
)
op_model_mipsxx_ops
.
cpu_type
=
"mips/r10000-v2.x"
;
else
op_model_mipsxx_ops
.
cpu_type
=
"mips/r10000"
;
break
;
case
CPU_R12000
:
case
CPU_R14000
:
op_model_mipsxx_ops
.
cpu_type
=
"mips/r12000"
;
break
;
case
CPU_SB1
:
case
CPU_SB1A
:
op_model_mipsxx_ops
.
cpu_type
=
"mips/sb1"
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment