[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <a4446f21ba9198bff546fee0c90f80159d2e82a3.1416167046.git.joe@perches.com>
Date: Sun, 16 Nov 2014 12:09:12 -0800
From: Joe Perches <joe@...ches.com>
To: Ionut Alexa <ionut.m.alexa@...il.com>, linux-kernel@...r.kernel.org
Cc: Al Viro <viro@...IV.linux.org.uk>,
Andrew Morton <akpm@...ux-foundation.org>
Subject: [UNNECESSARY PATCH 05/16] signal: Move case statements to separate lines and for loop neatening
Use the normal style for case statements and for loops
Make the initialization and for loop test more expected style too.
Add a break to the last case.
Signed-off-by: Joe Perches <joe@...ches.com>
---
kernel/signal.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/kernel/signal.c b/kernel/signal.c
index 0efde2d..49562b2 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -110,21 +110,26 @@ static inline int has_pending_signals(sigset_t *signal, sigset_t *blocked)
switch (_NSIG_WORDS) {
default:
- for (i = _NSIG_WORDS, ready = 0; --i >= 0 ;)
+ ready = 0;
+ for (i = _NSIG_WORDS; i >= 0; i--)
ready |= signal->sig[i] & ~blocked->sig[i];
break;
- case 4: ready = signal->sig[3] & ~blocked->sig[3];
+ 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];
+ 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];
+ case 1:
+ ready = signal->sig[0] & ~blocked->sig[0];
+ break;
}
return ready != 0;
}
--
2.1.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists