Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
3fe26fa3
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
160
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看板
提交
3fe26fa3
编写于
11月 12, 2012
作者:
A
Al Viro
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
x86: get rid of pt_regs argument in sigreturn variants
Signed-off-by:
N
Al Viro
<
viro@zeniv.linux.org.uk
>
上级
b3af11af
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
23 addition
and
55 deletion
+23
-55
arch/x86/ia32/ia32_signal.c
arch/x86/ia32/ia32_signal.c
+4
-2
arch/x86/ia32/ia32entry.S
arch/x86/ia32/ia32entry.S
+5
-6
arch/x86/include/asm/sys_ia32.h
arch/x86/include/asm/sys_ia32.h
+2
-2
arch/x86/include/asm/syscalls.h
arch/x86/include/asm/syscalls.h
+2
-2
arch/x86/kernel/entry_32.S
arch/x86/kernel/entry_32.S
+0
-23
arch/x86/kernel/entry_64.S
arch/x86/kernel/entry_64.S
+0
-2
arch/x86/kernel/signal.c
arch/x86/kernel/signal.c
+6
-3
arch/x86/syscalls/syscall_32.tbl
arch/x86/syscalls/syscall_32.tbl
+2
-2
arch/x86/um/signal.c
arch/x86/um/signal.c
+2
-13
未找到文件。
arch/x86/ia32/ia32_signal.c
浏览文件 @
3fe26fa3
...
...
@@ -215,8 +215,9 @@ static int ia32_restore_sigcontext(struct pt_regs *regs,
return
err
;
}
asmlinkage
long
sys32_sigreturn
(
struct
pt_regs
*
regs
)
asmlinkage
long
sys32_sigreturn
(
void
)
{
struct
pt_regs
*
regs
=
current_pt_regs
();
struct
sigframe_ia32
__user
*
frame
=
(
struct
sigframe_ia32
__user
*
)(
regs
->
sp
-
8
);
sigset_t
set
;
unsigned
int
ax
;
...
...
@@ -241,8 +242,9 @@ asmlinkage long sys32_sigreturn(struct pt_regs *regs)
return
0
;
}
asmlinkage
long
sys32_rt_sigreturn
(
struct
pt_regs
*
regs
)
asmlinkage
long
sys32_rt_sigreturn
(
void
)
{
struct
pt_regs
*
regs
=
current_pt_regs
();
struct
rt_sigframe_ia32
__user
*
frame
;
sigset_t
set
;
unsigned
int
ax
;
...
...
arch/x86/ia32/ia32entry.S
浏览文件 @
3fe26fa3
...
...
@@ -456,17 +456,16 @@ ia32_badsys:
ALIGN
GLOBAL
(\
label
)
leaq
\
func
(%
rip
),%
rax
leaq
-
ARGOFFSET
+
8
(%
rsp
),
\
arg
/*
8
for
return
address
*/
jmp
ia32_ptregs_common
.
endm
CFI_STARTPROC32
PTREGSCALL
stub32_rt_sigreturn
,
sys32_rt_sigreturn
,
%
rdi
PTREGSCALL
stub32_sigreturn
,
sys32_sigreturn
,
%
rdi
PTREGSCALL
stub32_execve
,
compat_sys_execve
,
%
rcx
PTREGSCALL
stub32_fork
,
sys_fork
,
%
rdi
PTREGSCALL
stub32_vfork
,
sys_vfork
,
%
rdi
PTREGSCALL
stub32_rt_sigreturn
,
sys32_rt_sigreturn
PTREGSCALL
stub32_sigreturn
,
sys32_sigreturn
PTREGSCALL
stub32_execve
,
compat_sys_execve
PTREGSCALL
stub32_fork
,
sys_fork
PTREGSCALL
stub32_vfork
,
sys_vfork
ALIGN
GLOBAL
(
stub32_clone
)
...
...
arch/x86/include/asm/sys_ia32.h
浏览文件 @
3fe26fa3
...
...
@@ -69,8 +69,8 @@ asmlinkage long sys32_fallocate(int, int, unsigned,
/* ia32/ia32_signal.c */
asmlinkage
long
sys32_sigsuspend
(
int
,
int
,
old_sigset_t
);
asmlinkage
long
sys32_sigreturn
(
struct
pt_regs
*
);
asmlinkage
long
sys32_rt_sigreturn
(
struct
pt_regs
*
);
asmlinkage
long
sys32_sigreturn
(
void
);
asmlinkage
long
sys32_rt_sigreturn
(
void
);
/* ia32/ipc32.c */
asmlinkage
long
sys32_ipc
(
u32
,
int
,
int
,
int
,
compat_uptr_t
,
u32
);
...
...
arch/x86/include/asm/syscalls.h
浏览文件 @
3fe26fa3
...
...
@@ -24,7 +24,7 @@ asmlinkage long sys_iopl(unsigned int);
asmlinkage
int
sys_modify_ldt
(
int
,
void
__user
*
,
unsigned
long
);
/* kernel/signal.c */
long
sys_rt_sigreturn
(
struct
pt_regs
*
);
long
sys_rt_sigreturn
(
void
);
/* kernel/tls.c */
asmlinkage
int
sys_set_thread_area
(
struct
user_desc
__user
*
);
...
...
@@ -37,7 +37,7 @@ asmlinkage int sys_get_thread_area(struct user_desc __user *);
asmlinkage
int
sys_sigsuspend
(
int
,
int
,
old_sigset_t
);
asmlinkage
int
sys_sigaction
(
int
,
const
struct
old_sigaction
__user
*
,
struct
old_sigaction
__user
*
);
unsigned
long
sys_sigreturn
(
struct
pt_regs
*
);
unsigned
long
sys_sigreturn
(
void
);
/* kernel/vm86_32.c */
int
sys_vm86old
(
struct
vm86_struct
__user
*
,
struct
pt_regs
*
);
...
...
arch/x86/kernel/entry_32.S
浏览文件 @
3fe26fa3
...
...
@@ -702,12 +702,6 @@ END(syscall_badsys)
/*
*
System
calls
that
need
a
pt_regs
pointer
.
*/
#define PTREGSCALL0(name) \
ENTRY
(
ptregs_
##
name
)
; \
leal
4
(%
esp
),%
eax
; \
jmp
sys_
##
name
; \
ENDPROC
(
ptregs_
##
name
)
#define PTREGSCALL1(name) \
ENTRY
(
ptregs_
##
name
)
; \
leal
4
(%
esp
),%
edx
; \
...
...
@@ -723,23 +717,6 @@ ENTRY(ptregs_##name) ; \
jmp
sys_
##
name
; \
ENDPROC
(
ptregs_
##
name
)
#define PTREGSCALL3(name) \
ENTRY
(
ptregs_
##
name
)
; \
CFI_STARTPROC
; \
leal
4
(%
esp
),%
eax
; \
pushl_cfi
%
eax
; \
movl
PT_EDX
(%
eax
),%
ecx
; \
movl
PT_ECX
(%
eax
),%
edx
; \
movl
PT_EBX
(%
eax
),%
eax
; \
call
sys_
##
name
; \
addl
$
4
,%
esp
; \
CFI_ADJUST_CFA_OFFSET
-
4
; \
ret
; \
CFI_ENDPROC
; \
ENDPROC
(
ptregs_
##
name
)
PTREGSCALL0
(
sigreturn
)
PTREGSCALL0
(
rt_sigreturn
)
PTREGSCALL2
(
vm86
)
PTREGSCALL1
(
vm86old
)
...
...
arch/x86/kernel/entry_64.S
浏览文件 @
3fe26fa3
...
...
@@ -896,7 +896,6 @@ ENTRY(stub_rt_sigreturn)
addq
$
8
,
%
rsp
PARTIAL_FRAME
0
SAVE_REST
movq
%
rsp
,%
rdi
FIXUP_TOP_OF_STACK
%
r11
call
sys_rt_sigreturn
movq
%
rax
,
RAX
(%
rsp
)
#
fixme
,
this
could
be
done
at
the
higher
layer
...
...
@@ -911,7 +910,6 @@ ENTRY(stub_x32_rt_sigreturn)
addq
$
8
,
%
rsp
PARTIAL_FRAME
0
SAVE_REST
movq
%
rsp
,%
rdi
FIXUP_TOP_OF_STACK
%
r11
call
sys32_x32_rt_sigreturn
movq
%
rax
,
RAX
(%
rsp
)
#
fixme
,
this
could
be
done
at
the
higher
layer
...
...
arch/x86/kernel/signal.c
浏览文件 @
3fe26fa3
...
...
@@ -597,8 +597,9 @@ sys_sigaction(int sig, const struct old_sigaction __user *act,
* Do a signal return; undo the signal stack.
*/
#ifdef CONFIG_X86_32
unsigned
long
sys_sigreturn
(
struct
pt_regs
*
regs
)
unsigned
long
sys_sigreturn
(
void
)
{
struct
pt_regs
*
regs
=
current_pt_regs
();
struct
sigframe
__user
*
frame
;
unsigned
long
ax
;
sigset_t
set
;
...
...
@@ -625,8 +626,9 @@ unsigned long sys_sigreturn(struct pt_regs *regs)
}
#endif
/* CONFIG_X86_32 */
long
sys_rt_sigreturn
(
struct
pt_regs
*
regs
)
long
sys_rt_sigreturn
(
void
)
{
struct
pt_regs
*
regs
=
current_pt_regs
();
struct
rt_sigframe
__user
*
frame
;
unsigned
long
ax
;
sigset_t
set
;
...
...
@@ -843,8 +845,9 @@ void signal_fault(struct pt_regs *regs, void __user *frame, char *where)
}
#ifdef CONFIG_X86_X32_ABI
asmlinkage
long
sys32_x32_rt_sigreturn
(
struct
pt_regs
*
regs
)
asmlinkage
long
sys32_x32_rt_sigreturn
(
void
)
{
struct
pt_regs
*
regs
=
current_pt_regs
();
struct
rt_sigframe_x32
__user
*
frame
;
sigset_t
set
;
unsigned
long
ax
;
...
...
arch/x86/syscalls/syscall_32.tbl
浏览文件 @
3fe26fa3
...
...
@@ -125,7 +125,7 @@
116 i386 sysinfo sys_sysinfo compat_sys_sysinfo
117 i386 ipc sys_ipc sys32_ipc
118 i386 fsync sys_fsync
119 i386 sigreturn
ptregs_sigreturn
stub32_sigreturn
119 i386 sigreturn
sys_sigreturn
stub32_sigreturn
120 i386 clone sys_clone stub32_clone
121 i386 setdomainname sys_setdomainname
122 i386 uname sys_newuname
...
...
@@ -179,7 +179,7 @@
170 i386 setresgid sys_setresgid16
171 i386 getresgid sys_getresgid16
172 i386 prctl sys_prctl
173 i386 rt_sigreturn
ptreg
s_rt_sigreturn stub32_rt_sigreturn
173 i386 rt_sigreturn
sy
s_rt_sigreturn stub32_rt_sigreturn
174 i386 rt_sigaction sys_rt_sigaction sys32_rt_sigaction
175 i386 rt_sigprocmask sys_rt_sigprocmask
176 i386 rt_sigpending sys_rt_sigpending sys32_rt_sigpending
...
...
arch/x86/um/signal.c
浏览文件 @
3fe26fa3
...
...
@@ -464,7 +464,7 @@ int setup_signal_stack_si(unsigned long stack_top, int sig,
return
0
;
}
long
sys_sigreturn
(
struct
pt_regs
*
regs
)
long
sys_sigreturn
(
void
)
{
unsigned
long
sp
=
PT_REGS_SP
(
&
current
->
thread
.
regs
);
struct
sigframe
__user
*
frame
=
(
struct
sigframe
__user
*
)(
sp
-
8
);
...
...
@@ -577,7 +577,7 @@ int setup_signal_stack_si(unsigned long stack_top, int sig,
}
#endif
long
sys_rt_sigreturn
(
struct
pt_regs
*
regs
)
long
sys_rt_sigreturn
(
void
)
{
unsigned
long
sp
=
PT_REGS_SP
(
&
current
->
thread
.
regs
);
struct
rt_sigframe
__user
*
frame
=
...
...
@@ -601,14 +601,3 @@ long sys_rt_sigreturn(struct pt_regs *regs)
force_sig
(
SIGSEGV
,
current
);
return
0
;
}
#ifdef CONFIG_X86_32
long
ptregs_sigreturn
(
void
)
{
return
sys_sigreturn
(
NULL
);
}
long
ptregs_rt_sigreturn
(
void
)
{
return
sys_rt_sigreturn
(
NULL
);
}
#endif
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录