mirror of
https://git.openafs.org/openafs.git
synced 2025-01-31 13:38:01 +00:00
STABLE12-more-redhate-beta-fun-20030131
apparently having recalc_sigpending stay the same was just as hard as continuing to export the same level of functionality, so we get neither. (cherry picked from commit 9a07ae91c39ded5541302d91aae81e5d137e4d06)
This commit is contained in:
parent
864f275da9
commit
10223b0d21
@ -31,7 +31,34 @@
|
||||
#endif
|
||||
|
||||
#ifdef RECALC_SIGPENDING_TAKES_VOID
|
||||
#define PENDING(p,b) has_pending_signals(&(p)->signal, (b))
|
||||
/* Principal of maximum uselessness says we need to provide this */
|
||||
static inline int _has_pending_signals(sigset_t *signal, sigset_t *blocked)
|
||||
{
|
||||
unsigned long ready;
|
||||
long i;
|
||||
|
||||
switch (_NSIG_WORDS) {
|
||||
default:
|
||||
for (i = _NSIG_WORDS, ready = 0; --i >= 0 ;)
|
||||
ready |= signal->sig[i] &~ blocked->sig[i];
|
||||
break;
|
||||
|
||||
case 4: ready = signal->sig[3] &~ blocked->sig[3];
|
||||
ready |= signal->sig[2] &~ blocked->sig[2];
|
||||
ready |= signal->sig[1] &~ blocked->sig[1];
|
||||
ready |= signal->sig[0] &~ blocked->sig[0];
|
||||
break;
|
||||
|
||||
case 2: ready = signal->sig[1] &~ blocked->sig[1];
|
||||
ready |= signal->sig[0] &~ blocked->sig[0];
|
||||
break;
|
||||
|
||||
case 1: ready = signal->sig[0] &~ blocked->sig[0];
|
||||
}
|
||||
return ready != 0;
|
||||
}
|
||||
|
||||
#define PENDING(p,b) _has_pending_signals(&(p)->signal, (b))
|
||||
static inline void _recalc_sigpending_tsk(struct task_struct *t)
|
||||
{
|
||||
t->sigpending = PENDING(&t->pending, &t->blocked) ||
|
||||
|
Loading…
x
Reference in New Issue
Block a user