From: Jan-Benedict Glaw <jbglaw@lug-owl.de>
To: parisc-linux@lists.parisc-linux.org
Subject: [parisc-linux] [PATCH-linux-2.5] sa_handler compare with cast
Date: Thu, 8 May 2003 08:12:34 +0200 [thread overview]
Message-ID: <20030508061234.GR27494@lug-owl.de> (raw)
In-Reply-To: <3EB7766A000003EE@ocpmta7.freegates.net>
[-- Attachment #1: Type: text/plain, Size: 8028 bytes --]
On Tue, 2003-05-06 19:56:48 +0200, Joel Soete <jsoe0708@tiscali.be>
wrote in message <3EB7766A000003EE@ocpmta7.freegates.net>:
> So it will finaly become:
> diff -NaurX dontdiff linux-2.4.20-pa33/arch/parisc/kernel/signal.c linux-2.4.20-pa33-gcc33/arch/parisc/kernel/signal.c
> --- linux-2.4.20-pa33/arch/parisc/kernel/signal.c 2003-05-06 17:47:32.000000000
> +0200
> +++ linux-2.4.20-pa33-gcc33/arch/parisc/kernel/signal.c 2003-05-06 18:09:35.000000000
> +0200
[...]
This is the 2.5.x version. It's _only_ the sa_handler caste, not
including the additional compiler fixes you suggested.
Index: drivers/char/n_tty.c
===================================================================
RCS file: /var/cvs/linux-2.5/drivers/char/n_tty.c,v
retrieving revision 1.8
diff -u -r1.8 n_tty.c
--- drivers/char/n_tty.c 5 May 2003 17:06:33 -0000 1.8
+++ drivers/char/n_tty.c 8 May 2003 06:08:38 -0000
@@ -808,7 +808,8 @@
int is_ignored(int sig)
{
return (sigismember(¤t->blocked, sig) ||
- current->sighand->action[sig-1].sa.sa_handler == SIG_IGN);
+ current->sighand->action[sig-1].sa.sa_handler
+ == (void *)SIG_IGN);
}
static void n_tty_set_termios(struct tty_struct *tty, struct termios * old)
Index: fs/ncpfs/sock.c
===================================================================
RCS file: /var/cvs/linux-2.5/fs/ncpfs/sock.c,v
retrieving revision 1.6
diff -u -r1.6 sock.c
--- fs/ncpfs/sock.c 15 Feb 2003 03:48:26 -0000 1.6
+++ fs/ncpfs/sock.c 8 May 2003 06:08:39 -0000
@@ -757,9 +757,9 @@
What if we've blocked it ourselves? What about
alarms? Why, in fact, are we mucking with the
sigmask at all? -- r~ */
- if (current->sighand->action[SIGINT - 1].sa.sa_handler == SIG_DFL)
+ if (current->sighand->action[SIGINT - 1].sa.sa_handler == (void *)SIG_DFL)
mask |= sigmask(SIGINT);
- if (current->sighand->action[SIGQUIT - 1].sa.sa_handler == SIG_DFL)
+ if (current->sighand->action[SIGQUIT - 1].sa.sa_handler == (void *)SIG_DFL)
mask |= sigmask(SIGQUIT);
}
siginitsetinv(¤t->blocked, mask);
Index: fs/proc/array.c
===================================================================
RCS file: /var/cvs/linux-2.5/fs/proc/array.c,v
retrieving revision 1.15
diff -u -r1.15 array.c
--- fs/proc/array.c 5 May 2003 17:08:54 -0000 1.15
+++ fs/proc/array.c 8 May 2003 06:08:40 -0000
@@ -213,9 +213,9 @@
k = p->sighand->action;
for (i = 1; i <= _NSIG; ++i, ++k) {
- if (k->sa.sa_handler == SIG_IGN)
+ if (k->sa.sa_handler == (void *)SIG_IGN)
sigaddset(ign, i);
- else if (k->sa.sa_handler != SIG_DFL)
+ else if (k->sa.sa_handler != (void *)SIG_DFL)
sigaddset(catch, i);
}
}
Index: kernel/signal.c
===================================================================
RCS file: /var/cvs/linux-2.5/kernel/signal.c,v
retrieving revision 1.19
diff -u -r1.19 signal.c
--- kernel/signal.c 24 Apr 2003 01:38:05 -0000 1.19
+++ kernel/signal.c 8 May 2003 06:08:42 -0000
@@ -144,12 +144,12 @@
(((sig) < SIGRTMIN) && T(sig, SIG_KERNEL_STOP_MASK))
#define sig_user_defined(t, signr) \
- (((t)->sighand->action[(signr)-1].sa.sa_handler != SIG_DFL) && \
- ((t)->sighand->action[(signr)-1].sa.sa_handler != SIG_IGN))
+ (((t)->sighand->action[(signr)-1].sa.sa_handler != (void *)SIG_DFL) && \
+ ((t)->sighand->action[(signr)-1].sa.sa_handler != (void *)SIG_IGN))
#define sig_fatal(t, signr) \
(!T(signr, SIG_KERNEL_IGNORE_MASK|SIG_KERNEL_STOP_MASK) && \
- (t)->sighand->action[(signr)-1].sa.sa_handler == SIG_DFL)
+ (t)->sighand->action[(signr)-1].sa.sa_handler == (void *)SIG_DFL)
static inline int sig_ignored(struct task_struct *t, int sig)
{
@@ -171,8 +171,8 @@
/* Is it explicitly or implicitly ignored? */
handler = t->sighand->action[sig-1].sa.sa_handler;
- return handler == SIG_IGN ||
- (handler == SIG_DFL && sig_kernel_ignore(sig));
+ return handler == (void *)SIG_IGN ||
+ (handler == (void *)SIG_DFL && sig_kernel_ignore(sig));
}
/*
@@ -366,7 +366,7 @@
int i;
struct k_sigaction *ka = &t->sighand->action[0];
for (i = _NSIG ; i != 0 ; i--) {
- if (force_default || ka->sa.sa_handler != SIG_IGN)
+ if (force_default || ka->sa.sa_handler != (void *)SIG_IGN)
ka->sa.sa_handler = SIG_DFL;
ka->sa.sa_flags = 0;
sigemptyset(&ka->sa.sa_mask);
@@ -801,7 +801,7 @@
int ret;
spin_lock_irqsave(&t->sighand->siglock, flags);
- if (t->sighand->action[sig-1].sa.sa_handler == SIG_IGN)
+ if (t->sighand->action[sig-1].sa.sa_handler == (void *)SIG_IGN)
t->sighand->action[sig-1].sa.sa_handler = SIG_DFL;
sigdelset(&t->blocked, sig);
recalc_sigpending_tsk(t);
@@ -817,7 +817,7 @@
unsigned long int flags;
spin_lock_irqsave(&t->sighand->siglock, flags);
- if (t->sighand->action[sig-1].sa.sa_handler == SIG_IGN)
+ if (t->sighand->action[sig-1].sa.sa_handler == (void *)SIG_IGN)
t->sighand->action[sig-1].sa.sa_handler = SIG_DFL;
sigdelset(&t->blocked, sig);
recalc_sigpending_tsk(t);
@@ -1281,7 +1281,7 @@
psig = tsk->parent->sighand;
spin_lock_irqsave(&psig->siglock, flags);
if (sig == SIGCHLD && tsk->state != TASK_STOPPED &&
- (psig->action[SIGCHLD-1].sa.sa_handler == SIG_IGN ||
+ (psig->action[SIGCHLD-1].sa.sa_handler == (void *)SIG_IGN ||
(psig->action[SIGCHLD-1].sa.sa_flags & SA_NOCLDWAIT))) {
/*
* We are exiting and our parent doesn't care. POSIX.1
@@ -1299,7 +1299,7 @@
* it, just use SIG_IGN instead).
*/
tsk->exit_signal = -1;
- if (psig->action[SIGCHLD-1].sa.sa_handler == SIG_IGN)
+ if (psig->action[SIGCHLD-1].sa.sa_handler == (void *)SIG_IGN)
sig = 0;
}
if (sig > 0 && sig <= _NSIG)
@@ -1347,7 +1347,7 @@
sighand = parent->sighand;
spin_lock_irqsave(&sighand->siglock, flags);
- if (sighand->action[SIGCHLD-1].sa.sa_handler != SIG_IGN &&
+ if (sighand->action[SIGCHLD-1].sa.sa_handler != (void *)SIG_IGN &&
!(sighand->action[SIGCHLD-1].sa.sa_flags & SA_NOCLDSTOP))
__group_send_sig_info(SIGCHLD, &info, parent);
/*
@@ -1581,9 +1581,9 @@
}
ka = ¤t->sighand->action[signr-1];
- if (ka->sa.sa_handler == SIG_IGN) /* Do nothing. */
+ if (ka->sa.sa_handler == (void *)SIG_IGN) /* Do nothing. */
continue;
- if (ka->sa.sa_handler != SIG_DFL) /* Run the handler. */
+ if (ka->sa.sa_handler != (void *)SIG_DFL) /* Run the handler. */
return signr;
/*
@@ -2034,8 +2034,8 @@
* (for example, SIGCHLD), shall cause the pending signal to
* be discarded, whether or not it is blocked"
*/
- if (act->sa.sa_handler == SIG_IGN ||
- (act->sa.sa_handler == SIG_DFL &&
+ if (act->sa.sa_handler == (void *)SIG_IGN ||
+ (act->sa.sa_handler == (void *)SIG_DFL &&
sig_kernel_ignore(sig))) {
/*
* This is a fairly rare case, so we only take the
Index: net/sunrpc/clnt.c
===================================================================
RCS file: /var/cvs/linux-2.5/net/sunrpc/clnt.c,v
retrieving revision 1.12
diff -u -r1.12 clnt.c
--- net/sunrpc/clnt.c 8 Apr 2003 15:21:04 -0000 1.12
+++ net/sunrpc/clnt.c 8 May 2003 06:08:44 -0000
@@ -255,9 +255,9 @@
/* Turn off various signals */
if (clnt->cl_intr) {
struct k_sigaction *action = current->sighand->action;
- if (action[SIGINT-1].sa.sa_handler == SIG_DFL)
+ if (action[SIGINT-1].sa.sa_handler == (void *)SIG_DFL)
sigallow |= sigmask(SIGINT);
- if (action[SIGQUIT-1].sa.sa_handler == SIG_DFL)
+ if (action[SIGQUIT-1].sa.sa_handler == (void *)SIG_DFL)
sigallow |= sigmask(SIGQUIT);
}
spin_lock_irqsave(¤t->sighand->siglock, irqflags);
MfG, JBG
--
Jan-Benedict Glaw jbglaw@lug-owl.de . +49-172-7608481
"Eine Freie Meinung in einem Freien Kopf | Gegen Zensur | Gegen Krieg
fuer einen Freien Staat voll Freier Bürger" | im Internet! | im Irak!
ret = do_actions((curr | FREE_SPEECH) & ~(IRAQ_WAR_2 | DRM | TCPA));
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2003-05-08 6:12 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-05-05 20:02 [parisc-linux] Oops on 2.4.20-pa33 Jan-Benedict Glaw
2003-05-05 20:05 ` Randolph Chung
2003-05-05 21:05 ` [parisc-linux] [PATCH-2.4] DIVA serial build error (was: Oops on 2.4.20-pa33) Jan-Benedict Glaw
2003-05-06 15:20 ` Jan-Benedict Glaw
2003-05-07 16:27 ` Paul Bame
2003-05-06 6:04 ` [parisc-linux] Oops on 2.4.20-pa33 Joel Soete
2003-05-06 14:04 ` Randolph Chung
2003-05-06 15:04 ` Joel Soete
2003-05-06 15:08 ` Randolph Chung
2003-05-06 16:34 ` Joel Soete
2003-05-06 16:42 ` John David Anglin
2003-05-06 17:56 ` Joel Soete
2003-05-07 15:48 ` Jan-Benedict Glaw
2003-05-07 16:09 ` Joel Soete
2003-05-07 17:17 ` Randolph Chung
2003-05-07 17:51 ` Jan-Benedict Glaw
2003-05-09 2:37 ` Andrew Shugg
2003-05-09 22:04 ` Jan-Benedict Glaw
2003-05-08 5:52 ` Joel Soete
2003-05-08 6:12 ` Jan-Benedict Glaw [this message]
2003-05-10 20:31 ` [parisc-linux] Yet another '__canonicalize_funcptr_for_compare' pb Joel Soete
2003-05-10 20:25 ` Jan-Benedict Glaw
2003-05-10 21:08 ` Grant Grundler
2003-05-10 21:32 ` John David Anglin
2003-05-10 21:33 ` Joel Soete
2003-05-10 21:38 ` [parisc-linux] Yet another '__canonicalize_funcptr_for_compare' John David Anglin
2003-05-10 21:21 ` [parisc-linux] Re: Yet another '__canonicalize_funcptr_for_compare' pb John David Anglin
2003-05-05 20:10 ` [parisc-linux] Oops on 2.4.20-pa33 John David Anglin
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=20030508061234.GR27494@lug-owl.de \
--to=jbglaw@lug-owl.de \
--cc=parisc-linux@lists.parisc-linux.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