]> err.no Git - linux-2.6/commitdiff
mm/hugetlb.c: fix duplicate variable
authorAdrian Bunk <bunk@kernel.org>
Thu, 24 Jul 2008 04:27:03 +0000 (21:27 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 24 Jul 2008 17:47:14 +0000 (10:47 -0700)
It's confusing that set_max_huge_pages() contained two different
variables named "ret", and although the code works correctly this should
be fixed.

The inner of the two variables can simply be removed.

Spotted by sparse.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Cc: "KOSAKI Motohiro" <kosaki.motohiro@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/hugetlb.c

index ab171274ef217817291667bee226b45bebe259e3..2c5c9ee4220de4e9bb06addd6137ac0ce243d273 100644 (file)
@@ -603,7 +603,6 @@ static unsigned long set_max_huge_pages(unsigned long count)
        }
 
        while (count > persistent_huge_pages) {
-               int ret;
                /*
                 * If this allocation races such that we no longer need the
                 * page, free_huge_page will handle it by freeing the page