Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
b774cc5c
Commit
b774cc5c
authored
Dec 23, 2012
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
score: switch to generic sigaltstack
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
0aa0203f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
25 deletions
+3
-25
arch/score/Kconfig
arch/score/Kconfig
+1
-0
arch/score/include/asm/syscalls.h
arch/score/include/asm/syscalls.h
+0
-1
arch/score/kernel/entry.S
arch/score/kernel/entry.S
+0
-5
arch/score/kernel/signal.c
arch/score/kernel/signal.c
+2
-19
No files found.
arch/score/Kconfig
View file @
b774cc5c
...
...
@@ -14,6 +14,7 @@ config SCORE
select HAVE_MOD_ARCH_SPECIFIC
select MODULES_USE_ELF_REL
select CLONE_BACKWARDS
select GENERIC_SIGALTSTACK
choice
prompt "System type"
...
...
arch/score/include/asm/syscalls.h
View file @
b774cc5c
#ifndef _ASM_SCORE_SYSCALLS_H
#define _ASM_SCORE_SYSCALLS_H
asmlinkage
long
score_sigaltstack
(
struct
pt_regs
*
regs
);
asmlinkage
long
score_rt_sigreturn
(
struct
pt_regs
*
regs
);
#include <asm-generic/syscalls.h>
...
...
arch/score/kernel/entry.S
View file @
b774cc5c
...
...
@@ -491,8 +491,3 @@ ENTRY(sys_rt_sigreturn)
mv
r4
,
r0
la
r8
,
score_rt_sigreturn
br
r8
ENTRY
(
sys_sigaltstack
)
mv
r4
,
r0
la
r8
,
score_sigaltstack
br
r8
arch/score/kernel/signal.c
View file @
b774cc5c
...
...
@@ -133,16 +133,6 @@ static void __user *get_sigframe(struct k_sigaction *ka,
return
(
void
__user
*
)((
sp
-
frame_size
)
&
~
7
);
}
asmlinkage
long
score_sigaltstack
(
struct
pt_regs
*
regs
)
{
const
stack_t
__user
*
uss
=
(
const
stack_t
__user
*
)
regs
->
regs
[
4
];
stack_t
__user
*
uoss
=
(
stack_t
__user
*
)
regs
->
regs
[
5
];
unsigned
long
usp
=
regs
->
regs
[
0
];
return
do_sigaltstack
(
uss
,
uoss
,
usp
);
}
asmlinkage
long
score_rt_sigreturn
(
struct
pt_regs
*
regs
)
{
...
...
@@ -167,9 +157,7 @@ score_rt_sigreturn(struct pt_regs *regs)
else
if
(
sig
)
force_sig
(
sig
,
current
);
/* It is more difficult to avoid calling this function than to
call it and ignore errors. */
if
(
do_sigaltstack
(
&
frame
->
rs_uc
.
uc_stack
,
NULL
,
regs
->
regs
[
0
])
==
-
EFAULT
)
if
(
restore_altstack
(
&
frame
->
rs_uc
.
uc_stack
))
goto
badframe
;
regs
->
is_syscall
=
0
;
...
...
@@ -209,12 +197,7 @@ static int setup_rt_frame(struct k_sigaction *ka, struct pt_regs *regs,
err
|=
copy_siginfo_to_user
(
&
frame
->
rs_info
,
info
);
err
|=
__put_user
(
0
,
&
frame
->
rs_uc
.
uc_flags
);
err
|=
__put_user
(
NULL
,
&
frame
->
rs_uc
.
uc_link
);
err
|=
__put_user
((
void
__user
*
)
current
->
sas_ss_sp
,
&
frame
->
rs_uc
.
uc_stack
.
ss_sp
);
err
|=
__put_user
(
sas_ss_flags
(
regs
->
regs
[
0
]),
&
frame
->
rs_uc
.
uc_stack
.
ss_flags
);
err
|=
__put_user
(
current
->
sas_ss_size
,
&
frame
->
rs_uc
.
uc_stack
.
ss_size
);
err
|=
__save_altstack
(
&
frame
->
rs_uc
.
uc_stack
,
regs
->
regs
[
0
]);
err
|=
setup_sigcontext
(
regs
,
&
frame
->
rs_uc
.
uc_mcontext
);
err
|=
__copy_to_user
(
&
frame
->
rs_uc
.
uc_sigmask
,
set
,
sizeof
(
*
set
));
...
...
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