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:	Sat, 13 Nov 2010 13:07:00 +0000
From:	Russell King - ARM Linux <linux@....linux.org.uk>
To:	Mika Westerberg <mika.westerberg@....fi>
Cc:	linux-arm-kernel@...ts.infradead.org, akpm@...ux-foundation.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 4/4] ARM: memblock: convert reserve_crashkernel() to
	use memblock

On Tue, Nov 09, 2010 at 11:06:13AM +0200, Mika Westerberg wrote:
>  static void __init reserve_crashkernel(void)
>  {
>  	unsigned long long crash_size, crash_base;
> -	unsigned long long total_mem;
>  	int ret;
>  
> -	total_mem = get_total_mem();
> -	ret = parse_crashkernel(boot_command_line, total_mem,
> +	/* this is necessary because of memblock_phys_mem_size() */
> +	memblock_analyze();

I think you need to check with the memblock people whether its legal to
call memblock_analyze() multiple times.  What do other arches do for
this?

Secondly, when paging_init() returns, bootmem has been initialized, and
memory taken from bootmem to feed the zone allocators.  This memory is
not registered back into memblock.  Allocations from memblock after
paging_init() has returned will lead to overlaps with bootmem, and
therefore corruption.

So, this code is better off left as-is, rather than trying to convert it
to what mistakenly appears "the latest thing".
--
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