lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 22 Nov 2011 15:59:01 -0800
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Wang Sheng-Hui <shhuiw@...il.com>
Cc:	yinghai@...nel.org, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] cleanup: convert the int cnt to unsigned long in
 mm/memblock.c

On Wed, 09 Nov 2011 13:18:53 +0800
Wang Sheng-Hui <shhuiw@...il.com> wrote:

> @@ -111,7 +112,7 @@ static phys_addr_t __init_memblock memblock_find_region(phys_addr_t start, phys_
>  static phys_addr_t __init_memblock memblock_find_base(phys_addr_t size,
>  			phys_addr_t align, phys_addr_t start, phys_addr_t end)
>  {
> -	long i;
> +	unsigned long i;
>  
>  	BUG_ON(0 == size);

This change to memblock_find_base() can cause this loop:

	for (i = memblock.memory.cnt - 1; i >= 0; i--) {

to become infinite under some circumstances.

I stopped reading at that point.  Changes like this require much care.

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ