[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20121129134752.GB219@x4>
Date: Thu, 29 Nov 2012 14:47:52 +0100
From: Markus Trippelsdorf <markus@...ppelsdorf.de>
To: paulmck@...ux.vnet.ibm.com
Cc: linux-kernel@...r.kernel.org
Subject: kernel/rcutree.c:2850:13: warning: array subscript is above array
bounds
With gcc-4.8 I get:
CC kernel/rcutree.o
kernel/rcutree.c: In function ‘rcu_init_one’:
kernel/rcutree.c:2850:13: warning: array subscript is above array bounds [-Warray-bounds]
rsp->level[i] = rsp->level[i - 1] + rsp->levelcnt[i - 1];
^
2849 for (i = 1; i < rcu_num_lvls; i++)
2850 rsp->level[i] = rsp->level[i - 1] + rsp->levelcnt[i - 1];
At first I thought that the warning was bogus, but rcu_num_lvls isn't static
and gets modified prior to the for loop.
--
Markus
--
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