Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
138d1ce8
cloud-kernel
项目概览
openanolis
/
cloud-kernel
大约 1 年 前同步成功
通知
158
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
138d1ce8
编写于
10月 11, 2012
作者:
A
Al Viro
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
powerpc: switch to saner kernel_execve() semantics
Signed-off-by:
N
Al Viro
<
viro@zeniv.linux.org.uk
>
上级
ddffeb8c
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
4 addition
and
22 deletion
+4
-22
arch/powerpc/Kconfig
arch/powerpc/Kconfig
+1
-0
arch/powerpc/include/asm/unistd.h
arch/powerpc/include/asm/unistd.h
+0
-1
arch/powerpc/kernel/entry_32.S
arch/powerpc/kernel/entry_32.S
+0
-5
arch/powerpc/kernel/entry_64.S
arch/powerpc/kernel/entry_64.S
+0
-6
arch/powerpc/kernel/process.c
arch/powerpc/kernel/process.c
+3
-10
未找到文件。
arch/powerpc/Kconfig
浏览文件 @
138d1ce8
...
@@ -144,6 +144,7 @@ config PPC
...
@@ -144,6 +144,7 @@ config PPC
select GENERIC_KERNEL_THREAD
select GENERIC_KERNEL_THREAD
select HAVE_MOD_ARCH_SPECIFIC
select HAVE_MOD_ARCH_SPECIFIC
select MODULES_USE_ELF_RELA
select MODULES_USE_ELF_RELA
select GENERIC_KERNEL_EXECVE
config EARLY_PRINTK
config EARLY_PRINTK
bool
bool
...
...
arch/powerpc/include/asm/unistd.h
浏览文件 @
138d1ce8
...
@@ -56,7 +56,6 @@
...
@@ -56,7 +56,6 @@
#define __ARCH_WANT_COMPAT_SYS_SENDFILE
#define __ARCH_WANT_COMPAT_SYS_SENDFILE
#endif
#endif
#define __ARCH_WANT_SYS_EXECVE
#define __ARCH_WANT_SYS_EXECVE
#define __ARCH_WANT_KERNEL_EXECVE
/*
/*
* "Conditional" syscalls
* "Conditional" syscalls
...
...
arch/powerpc/kernel/entry_32.S
浏览文件 @
138d1ce8
...
@@ -444,11 +444,6 @@ ret_from_kernel_thread:
...
@@ -444,11 +444,6 @@ ret_from_kernel_thread:
PPC440EP_ERR42
PPC440EP_ERR42
blrl
blrl
li
r3
,
0
li
r3
,
0
b
do_exit
#
no
return
.
globl
__ret_from_kernel_execve
__ret_from_kernel_execve
:
addi
r1
,
r3
,-
STACK_FRAME_OVERHEAD
b
ret_from_syscall
b
ret_from_syscall
/*
Traced
system
call
support
*/
/*
Traced
system
call
support
*/
...
...
arch/powerpc/kernel/entry_64.S
浏览文件 @
138d1ce8
...
@@ -378,12 +378,6 @@ _GLOBAL(ret_from_kernel_thread)
...
@@ -378,12 +378,6 @@ _GLOBAL(ret_from_kernel_thread)
mr
r3
,
r15
mr
r3
,
r15
blrl
blrl
li
r3
,
0
li
r3
,
0
b
.
do_exit
#
no
return
_GLOBAL
(
__ret_from_kernel_execve
)
addi
r1
,
r3
,-
STACK_FRAME_OVERHEAD
li
r10
,
1
std
r10
,
SOFTE
(
r1
)
b
syscall_exit
b
syscall_exit
.
section
".toc"
,
"aw"
.
section
".toc"
,
"aw"
...
...
arch/powerpc/kernel/process.c
浏览文件 @
138d1ce8
...
@@ -746,19 +746,21 @@ int copy_thread(unsigned long clone_flags, unsigned long usp,
...
@@ -746,19 +746,21 @@ int copy_thread(unsigned long clone_flags, unsigned long usp,
sp
-=
sizeof
(
struct
pt_regs
);
sp
-=
sizeof
(
struct
pt_regs
);
childregs
=
(
struct
pt_regs
*
)
sp
;
childregs
=
(
struct
pt_regs
*
)
sp
;
if
(
!
regs
)
{
if
(
!
regs
)
{
/* for kernel thread, set `current' and stackptr in new task */
struct
thread_info
*
ti
=
(
void
*
)
task_stack_page
(
p
);
memset
(
childregs
,
0
,
sizeof
(
struct
pt_regs
));
memset
(
childregs
,
0
,
sizeof
(
struct
pt_regs
));
childregs
->
gpr
[
1
]
=
sp
+
sizeof
(
struct
pt_regs
);
childregs
->
gpr
[
1
]
=
sp
+
sizeof
(
struct
pt_regs
);
#ifdef CONFIG_PPC64
#ifdef CONFIG_PPC64
childregs
->
gpr
[
14
]
=
*
(
unsigned
long
*
)
usp
;
childregs
->
gpr
[
14
]
=
*
(
unsigned
long
*
)
usp
;
childregs
->
gpr
[
2
]
=
((
unsigned
long
*
)
usp
)[
1
],
childregs
->
gpr
[
2
]
=
((
unsigned
long
*
)
usp
)[
1
],
clear_tsk_thread_flag
(
p
,
TIF_32BIT
);
clear_tsk_thread_flag
(
p
,
TIF_32BIT
);
childregs
->
softe
=
1
;
#else
#else
childregs
->
gpr
[
14
]
=
usp
;
/* function */
childregs
->
gpr
[
14
]
=
usp
;
/* function */
childregs
->
gpr
[
2
]
=
(
unsigned
long
)
p
;
childregs
->
gpr
[
2
]
=
(
unsigned
long
)
p
;
#endif
#endif
childregs
->
gpr
[
15
]
=
arg
;
childregs
->
gpr
[
15
]
=
arg
;
p
->
thread
.
regs
=
NULL
;
/* no user register state */
p
->
thread
.
regs
=
NULL
;
/* no user register state */
ti
->
flags
|=
_TIF_RESTOREALL
;
f
=
ret_from_kernel_thread
;
f
=
ret_from_kernel_thread
;
}
else
{
}
else
{
CHECK_FULL_REGS
(
regs
);
CHECK_FULL_REGS
(
regs
);
...
@@ -1063,15 +1065,6 @@ int sys_vfork(unsigned long p1, unsigned long p2, unsigned long p3,
...
@@ -1063,15 +1065,6 @@ int sys_vfork(unsigned long p1, unsigned long p2, unsigned long p3,
regs
,
0
,
NULL
,
NULL
);
regs
,
0
,
NULL
,
NULL
);
}
}
void
__ret_from_kernel_execve
(
struct
pt_regs
*
normal
)
__noreturn
;
void
ret_from_kernel_execve
(
struct
pt_regs
*
normal
)
{
set_thread_flag
(
TIF_RESTOREALL
);
__ret_from_kernel_execve
(
normal
);
}
static
inline
int
valid_irq_stack
(
unsigned
long
sp
,
struct
task_struct
*
p
,
static
inline
int
valid_irq_stack
(
unsigned
long
sp
,
struct
task_struct
*
p
,
unsigned
long
nbytes
)
unsigned
long
nbytes
)
{
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录