From: akpm@osdl.org
To: torvalds@osdl.org
Cc: linux-kernel@vger.kernel.org, akpm@osdl.org, paulus@samba.org
Subject: [patch 025/198] ppc32: fix bogosity in process-freezing code
Date: Tue, 12 Apr 2005 03:30:55 -0700 [thread overview]
Message-ID: <200504121031.j3CAV2uF005214@shell0.pdx.osdl.net> (raw)
From: Paul Mackerras <paulus@samba.org>
The code that went into arch/ppc/kernel/signal.c recently to handle process
freezing seems to contain a dubious assumption: that a process that calls
do_signal when PF_FREEZE is set will have entered the kernel because of a
system call. This patch removes that assumption.
Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---
25-akpm/arch/ppc/kernel/signal.c | 4 +---
1 files changed, 1 insertion(+), 3 deletions(-)
diff -puN arch/ppc/kernel/signal.c~ppc32-fix-bogosity-in-process-freezing-code arch/ppc/kernel/signal.c
--- 25/arch/ppc/kernel/signal.c~ppc32-fix-bogosity-in-process-freezing-code 2005-04-12 03:21:09.526688624 -0700
+++ 25-akpm/arch/ppc/kernel/signal.c 2005-04-12 03:21:09.529688168 -0700
@@ -708,7 +708,6 @@ int do_signal(sigset_t *oldset, struct p
if (current->flags & PF_FREEZE) {
refrigerator(PF_FREEZE);
signr = 0;
- ret = regs->gpr[3];
if (!signal_pending(current))
goto no_signal;
}
@@ -719,7 +718,7 @@ int do_signal(sigset_t *oldset, struct p
newsp = frame = 0;
signr = get_signal_to_deliver(&info, &ka, regs, NULL);
-
+ no_signal:
if (TRAP(regs) == 0x0C00 /* System Call! */
&& regs->ccr & 0x10000000 /* error signalled */
&& ((ret = regs->gpr[3]) == ERESTARTSYS
@@ -735,7 +734,6 @@ int do_signal(sigset_t *oldset, struct p
regs->gpr[3] = EINTR;
/* note that the cr0.SO bit is already set */
} else {
-no_signal:
regs->nip -= 4; /* Back up & retry system call */
regs->result = 0;
regs->trap = 0;
_
reply other threads:[~2005-04-12 10:33 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200504121031.j3CAV2uF005214@shell0.pdx.osdl.net \
--to=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulus@samba.org \
--cc=torvalds@osdl.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®