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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1273622616.21352.59.camel@pasglop>
Date:	Wed, 12 May 2010 10:03:36 +1000
From:	Benjamin Herrenschmidt <benh@...nel.crashing.org>
To:	Yinghai <yinghai.lu@...cle.com>
Cc:	Ingo Molnar <mingo@...e.hu>, Thomas Gleixner <tglx@...utronix.de>,
	"H. Peter Anvin" <hpa@...or.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	David Miller <davem@...emloft.net>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Johannes Weiner <hannes@...xchg.org>,
	linux-kernel@...r.kernel.org, linux-arch@...r.kernel.org
Subject: Re: [PATCH 07/22] lmb: Add lmb_to_bootmem()

On Sun, 2010-05-09 at 21:31 -0700, Yinghai wrote:
> > This is clumsy. Doesn't work with NUMA either. Also,
> 
> it works NUMA. for x86 we managed to call that one time from
> 2.6.34-rc1. (still called early_res_to_bootmem().
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=1842f90cc98625d4d9bf8f8b927f17705ceb4e9c
> 
> > reserve_bootmem_generic() only exists on x86 afaik.
> 
> previous patch add weak version 
> [PATCH 06/22] bootmem, x86: Add weak version of
> reserve_bootmem_generic

It might work on x86, it won't work on sparc as far as I understand. In
any case, I don't think that should be in lmb.c, that's boilerplate crap
that eventually will go away.

One thing you don't seem to get is that several archs already have some
code to move from lmb to bootmem.

The right approach when making something "generic" like that is not to
make up another one deep into x86 gunkyness and make -that- generic
ignoring the existing implementations.

Instead, make sure that the existing implementations are in sync, and
then move -that- to a generic place, eventually adding (in a separate
patch) the changes needed by x86 if any.

Cheers,
Ben.


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