Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Linux-御风守护者
linux
提交
4bf42d42
L
linux
项目概览
Linux-御风守护者
/
linux
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
L
linux
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
4bf42d42
编写于
7月 08, 2006
作者:
R
Ralf Baechle
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[MIPS] SMTC: Reformat to Linux style.
Signed-off-by:
N
Ralf Baechle
<
ralf@linux-mips.org
>
上级
783b09dc
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
29 addition
and
29 deletion
+29
-29
arch/mips/kernel/smtc.c
arch/mips/kernel/smtc.c
+29
-29
未找到文件。
arch/mips/kernel/smtc.c
浏览文件 @
4bf42d42
...
...
@@ -127,7 +127,7 @@ static int __init stlb_disable(char *s)
static
int
__init
asidmask_set
(
char
*
str
)
{
get_option
(
&
str
,
&
asidmask
);
switch
(
asidmask
)
{
switch
(
asidmask
)
{
case
0x1
:
case
0x3
:
case
0x7
:
...
...
@@ -249,7 +249,7 @@ void smtc_configure_tlb(void)
/*
* Only count if the MMU Type indicated is TLB
*/
if
(((
read_vpe_c0_config
()
&
MIPS_CONF_MT
)
>>
7
)
==
1
)
{
if
(((
read_vpe_c0_config
()
&
MIPS_CONF_MT
)
>>
7
)
==
1
)
{
config1val
=
read_vpe_c0_config1
();
tlbsiz
+=
((
config1val
>>
25
)
&
0x3f
)
+
1
;
}
...
...
@@ -500,7 +500,7 @@ void mipsmt_prepare_cpus(void)
/* Set up coprocessor affinity CPU mask(s) */
for
(
tc
=
0
;
tc
<
ntc
;
tc
++
)
{
if
(
cpu_data
[
tc
].
options
&
MIPS_CPU_FPU
)
if
(
cpu_data
[
tc
].
options
&
MIPS_CPU_FPU
)
cpu_set
(
tc
,
mt_fpu_cpumask
);
}
...
...
@@ -582,8 +582,8 @@ void smtc_init_secondary(void)
* SMTC init code assigns TCs consdecutively and in ascending order
* to across available VPEs.
*/
if
(((
read_c0_tcbind
()
&
TCBIND_CURTC
)
!=
0
)
&&
((
read_c0_tcbind
()
&
TCBIND_CURVPE
)
if
(((
read_c0_tcbind
()
&
TCBIND_CURTC
)
!=
0
)
&&
((
read_c0_tcbind
()
&
TCBIND_CURVPE
)
!=
cpu_data
[
smp_processor_id
()
-
1
].
vpe_id
)){
write_c0_compare
(
read_c0_count
()
+
mips_hpt_frequency
/
HZ
);
}
...
...
@@ -757,8 +757,8 @@ void smtc_send_ipi(int cpu, int type, unsigned int action)
write_tc_c0_tchalt
(
0
);
UNLOCK_CORE_PRA
();
/* Try to reduce redundant timer interrupt messages */
if
(
type
==
SMTC_CLOCK_TICK
)
{
if
(
atomic_postincrement
(
&
ipi_timer_latch
[
cpu
])
!=
0
)
{
if
(
type
==
SMTC_CLOCK_TICK
)
{
if
(
atomic_postincrement
(
&
ipi_timer_latch
[
cpu
])
!=
0
)
{
smtc_ipi_nq
(
&
freeIPIq
,
pipi
);
return
;
}
...
...
@@ -797,7 +797,7 @@ void post_direct_ipi(int cpu, struct smtc_ipi *pipi)
* CU bit of Status is indicator that TC was
* already running on a kernel stack...
*/
if
(
tcstatus
&
ST0_CU0
)
{
if
(
tcstatus
&
ST0_CU0
)
{
/* Note that this "- 1" is pointer arithmetic */
kstack
=
((
struct
pt_regs
*
)
read_tc_gpr_sp
())
-
1
;
}
else
{
...
...
@@ -840,31 +840,31 @@ void ipi_decode(struct pt_regs *regs, struct smtc_ipi *pipi)
smtc_ipi_nq
(
&
freeIPIq
,
pipi
);
switch
(
type_copy
)
{
case
SMTC_CLOCK_TICK
:
/* Invoke Clock "Interrupt" */
ipi_timer_latch
[
dest_copy
]
=
0
;
case
SMTC_CLOCK_TICK
:
/* Invoke Clock "Interrupt" */
ipi_timer_latch
[
dest_copy
]
=
0
;
#ifdef SMTC_IDLE_HOOK_DEBUG
clock_hang_reported
[
dest_copy
]
=
0
;
clock_hang_reported
[
dest_copy
]
=
0
;
#endif
/* SMTC_IDLE_HOOK_DEBUG */
local_timer_interrupt
(
0
,
NULL
,
regs
);
local_timer_interrupt
(
0
,
NULL
,
regs
);
break
;
case
LINUX_SMP_IPI
:
switch
((
int
)
arg_copy
)
{
case
SMP_RESCHEDULE_YOURSELF
:
ipi_resched_interrupt
(
regs
);
break
;
case
LINUX_SMP_IPI
:
switch
((
int
)
arg_copy
)
{
case
SMP_RESCHEDULE_YOURSELF
:
ipi_resched_interrupt
(
regs
);
break
;
case
SMP_CALL_FUNCTION
:
ipi_call_interrupt
(
regs
);
break
;
default:
printk
(
"Impossible SMTC IPI Argument 0x%x
\n
"
,
(
int
)
arg_copy
);
break
;
}
case
SMP_CALL_FUNCTION
:
ipi_call_interrupt
(
regs
);
break
;
default:
printk
(
"Impossible SMTC IPI Type 0x%x
\n
"
,
type_copy
);
printk
(
"Impossible SMTC IPI Argument 0x%x
\n
"
,
(
int
)
arg_copy
);
break
;
}
break
;
default:
printk
(
"Impossible SMTC IPI Type 0x%x
\n
"
,
type_copy
);
break
;
}
}
...
...
@@ -879,7 +879,7 @@ void deferred_smtc_ipi(struct pt_regs *regs)
* Test is not atomic, but much faster than a dequeue,
* and the vast majority of invocations will have a null queue.
*/
if
(
IPIQ
[
q
].
head
!=
NULL
)
{
if
(
IPIQ
[
q
].
head
!=
NULL
)
{
while
((
pipi
=
smtc_ipi_dq
(
&
IPIQ
[
q
]))
!=
NULL
)
{
/* ipi_decode() should be called with interrupts off */
local_irq_save
(
flags
);
...
...
@@ -1254,7 +1254,7 @@ void smtc_flush_tlb_asid(unsigned long asid)
tlb_read
();
ehb
();
ehi
=
read_c0_entryhi
();
if
((
ehi
&
ASID_MASK
)
==
asid
)
{
if
((
ehi
&
ASID_MASK
)
==
asid
)
{
/*
* Invalidate only entries with specified ASID,
* makiing sure all entries differ.
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录