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
be13f508
Commit
be13f508
authored
Sep 18, 2002
by
Anton Blanchard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ppc64: fix handling of sigaltstack
parent
279f849b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
8 deletions
+12
-8
arch/ppc64/kernel/signal.c
arch/ppc64/kernel/signal.c
+4
-5
arch/ppc64/kernel/signal32.c
arch/ppc64/kernel/signal32.c
+8
-3
No files found.
arch/ppc64/kernel/signal.c
View file @
be13f508
...
@@ -159,11 +159,10 @@ long sys_rt_sigsuspend(sigset_t *unewset, size_t sigsetsize, int p3, int p4, int
...
@@ -159,11 +159,10 @@ long sys_rt_sigsuspend(sigset_t *unewset, size_t sigsetsize, int p3, int p4, int
}
}
}
}
long
sys_sigaltstack
(
const
stack_t
*
uss
,
stack_t
*
uoss
,
unsigned
long
r5
,
unsigned
long
r6
,
unsigned
long
r7
,
unsigned
long
r8
,
long
sys_sigaltstack
(
const
stack_t
*
uss
,
stack_t
*
uos
s
)
struct
pt_regs
*
reg
s
)
{
{
struct
pt_regs
*
regs
=
(
struct
pt_regs
*
)
&
uss
;
return
do_sigaltstack
(
uss
,
uoss
,
regs
->
gpr
[
1
]);
return
do_sigaltstack
(
uss
,
uoss
,
regs
->
gpr
[
1
]);
}
}
...
@@ -250,7 +249,7 @@ int sys_rt_sigreturn(unsigned long r3, unsigned long r4, unsigned long r5,
...
@@ -250,7 +249,7 @@ int sys_rt_sigreturn(unsigned long r3, unsigned long r4, unsigned long r5,
goto
badframe
;
goto
badframe
;
/* This function sets back the stack flags into
/* This function sets back the stack flags into
the current task structure. */
the current task structure. */
sys_sigaltstack
(
&
st
,
NULL
);
sys_sigaltstack
(
&
st
,
NULL
,
0
,
0
,
0
,
0
,
regs
);
return
regs
->
result
;
return
regs
->
result
;
...
...
arch/ppc64/kernel/signal32.c
View file @
be13f508
...
@@ -421,7 +421,6 @@ static void setup_frame32(struct pt_regs *regs, struct sigregs32 *frame,
...
@@ -421,7 +421,6 @@ static void setup_frame32(struct pt_regs *regs, struct sigregs32 *frame,
* siginfo32to64
* siginfo32to64
*/
*/
/*
/*
* This code executes after the rt signal handler in 32 bit mode has
* This code executes after the rt signal handler in 32 bit mode has
* completed and returned
* completed and returned
...
@@ -438,6 +437,7 @@ long sys32_rt_sigreturn(unsigned long r3, unsigned long r4, unsigned long r5,
...
@@ -438,6 +437,7 @@ long sys32_rt_sigreturn(unsigned long r3, unsigned long r4, unsigned long r5,
sigset_t
set
;
sigset_t
set
;
stack_t
st
;
stack_t
st
;
int
i
;
int
i
;
mm_segment_t
old_fs
;
/* Adjust the inputted reg1 to point to the first rt signal frame */
/* Adjust the inputted reg1 to point to the first rt signal frame */
rt_sf
=
(
struct
rt_sigframe_32
*
)(
regs
->
gpr
[
1
]
+
__SIGNAL_FRAMESIZE32
);
rt_sf
=
(
struct
rt_sigframe_32
*
)(
regs
->
gpr
[
1
]
+
__SIGNAL_FRAMESIZE32
);
...
@@ -509,10 +509,15 @@ long sys32_rt_sigreturn(unsigned long r3, unsigned long r4, unsigned long r5,
...
@@ -509,10 +509,15 @@ long sys32_rt_sigreturn(unsigned long r3, unsigned long r4, unsigned long r5,
regs
->
dar
=
0
;
regs
->
dar
=
0
;
regs
->
dsisr
=
0
;
regs
->
dsisr
=
0
;
regs
->
result
=
(
u64
)(
saved_regs
[
PT_RESULT
])
&
0xFFFFFFFF
;
regs
->
result
=
(
u64
)(
saved_regs
[
PT_RESULT
])
&
0xFFFFFFFF
;
if
(
copy_from_user
(
current
->
thread
.
fpr
,
&
sr
->
fp_regs
,
if
(
copy_from_user
(
current
->
thread
.
fpr
,
&
sr
->
fp_regs
,
sizeof
(
sr
->
fp_regs
)))
sizeof
(
sr
->
fp_regs
)))
goto
badframe
;
goto
badframe
;
/* This function sets back the stack flags into
the current task structure. */
old_fs
=
get_fs
();
set_fs
(
KERNEL_DS
);
do_sigaltstack
(
&
st
,
NULL
,
regs
->
gpr
[
1
]);
set_fs
(
old_fs
);
ret
=
regs
->
result
;
ret
=
regs
->
result
;
return
ret
;
return
ret
;
...
...
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