]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
rcu/rcutorture: Replace 0 with false
authorJules Irenge <jbi.octave@gmail.com>
Mon, 1 Jun 2020 18:45:48 +0000 (19:45 +0100)
committerPaul E. McKenney <paulmck@kernel.org>
Mon, 29 Jun 2020 19:01:44 +0000 (12:01 -0700)
Coccinelle reports a warning

WARNING: Assignment of 0/1 to bool variable

The root cause is that the variable lastphase is a bool, but is
initialised with integer 0.  This commit therefore replaces the 0 with
a false.

Signed-off-by: Jules Irenge <jbi.octave@gmail.com>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
kernel/rcu/rcutorture.c

index 59112077a6da0c79e49f717c470cb93c0d205168..37455a12898e68da8a5a8f7cbf47bf269183595b 100644 (file)
@@ -2185,7 +2185,7 @@ static void rcu_torture_barrier1cb(void *rcu_void)
 static int rcu_torture_barrier_cbs(void *arg)
 {
        long myid = (long)arg;
-       bool lastphase = 0;
+       bool lastphase = false;
        bool newphase;
        struct rcu_head rcu;