]> git.baikalelectronics.ru Git - kernel.git/commit
sh: off by one BUG_ON() in setup_bootmem_node()
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 10 Dec 2014 23:41:31 +0000 (15:41 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 11 Dec 2014 01:41:02 +0000 (17:41 -0800)
commitf5d0ddd67b9e5d7565972f7b3e2885a98384b615
tree58fca4bbb311699da22f7e96ba38ffe1bb13c2ae
parenta89c1c3fffdbaf075901ce11ee7fab2d60496221
sh: off by one BUG_ON() in setup_bootmem_node()

This off by one bug is harmless but it upsets the static checkers and the
code is obvious so it doesn't hurt to fix it.  The Smatch warning is:

    arch/sh/mm/numa.c:47 setup_bootmem_node()
    error: buffer overflow 'node_data' 1024 <= 1024

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Acked-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/sh/mm/numa.c