Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
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
Commits
6f52707e
Commit
6f52707e
authored
Aug 06, 2008
by
Paul Mundt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sh: smp: Hook up a timer IPI stub.
Signed-off-by:
Paul Mundt
<
lethal@linux-sh.org
>
parent
c7936b9a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
6 deletions
+31
-6
arch/sh/include/asm/smp.h
arch/sh/include/asm/smp.h
+13
-6
arch/sh/kernel/smp.c
arch/sh/kernel/smp.c
+18
-0
No files found.
arch/sh/include/asm/smp.h
View file @
6f52707e
...
...
@@ -21,19 +21,26 @@ extern int __cpu_number_map[NR_CPUS];
extern
int
__cpu_logical_map
[
NR_CPUS
];
#define cpu_logical_map(cpu) __cpu_logical_map[cpu]
#define SMP_MSG_FUNCTION 0
#define SMP_MSG_RESCHEDULE 1
#define SMP_MSG_FUNCTION_SINGLE 2
#define SMP_MSG_NR 3
enum
{
SMP_MSG_FUNCTION
,
SMP_MSG_RESCHEDULE
,
SMP_MSG_FUNCTION_SINGLE
,
SMP_MSG_TIMER
,
SMP_MSG_NR
,
/* must be last */
};
void
smp_message_recv
(
unsigned
int
msg
);
void
smp_timer_broadcast
(
cpumask_t
mask
);
void
plat_smp_setup
(
void
);
void
plat_prepare_cpus
(
unsigned
int
max_cpus
);
int
plat_smp_processor_id
(
void
);
void
plat_start_cpu
(
unsigned
int
cpu
,
unsigned
long
entry_point
);
void
plat_send_ipi
(
unsigned
int
cpu
,
unsigned
int
message
);
extern
void
arch_send_call_function_single_ipi
(
int
cpu
);
extern
void
arch_send_call_function_ipi
(
cpumask_t
mask
);
void
arch_send_call_function_single_ipi
(
int
cpu
);
void
arch_send_call_function_ipi
(
cpumask_t
mask
);
#else
...
...
arch/sh/kernel/smp.c
View file @
6f52707e
...
...
@@ -184,6 +184,21 @@ void arch_send_call_function_single_ipi(int cpu)
plat_send_ipi
(
cpu
,
SMP_MSG_FUNCTION_SINGLE
);
}
void
smp_timer_broadcast
(
cpumask_t
mask
)
{
int
cpu
;
for_each_cpu_mask
(
cpu
,
mask
)
plat_send_ipi
(
cpu
,
SMP_MSG_TIMER
);
}
static
void
ipi_timer
(
void
)
{
irq_enter
();
/* XXX ... */
irq_exit
();
}
void
smp_message_recv
(
unsigned
int
msg
)
{
switch
(
msg
)
{
...
...
@@ -195,6 +210,9 @@ void smp_message_recv(unsigned int msg)
case
SMP_MSG_FUNCTION_SINGLE
:
generic_smp_call_function_single_interrupt
();
break
;
case
SMP_MSG_TIMER
:
ipi_timer
();
break
;
default:
printk
(
KERN_WARNING
"SMP %d: %s(): unknown IPI %d
\n
"
,
smp_processor_id
(),
__func__
,
msg
);
...
...
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