On Wed, Aug 01, 2007 at 12:34:21PM -0500, Hollis Blanchard wrote: > > Yup, it's a pain. Here's one idea: set a "GET_HEAP_FROM_WHEREVER" > flag, then later do
Why a flag? Don't we want to do this unconditionally? MIN_HEAP_SIZE already determines wether it's appropiate or not. > We could try doing that in all situations, except: > - this method isn't often used, so firmwares can have bugs here Our code already implements most of this (in grub_available_iterate). Why not doing it ourselves instead of reliing on potentially-broken firmware? > - if MIN_HEAP_SIZE were small enough (e.g. 2MB), it would mean we > probably would still have 4MB+ free. However, that depends on the size > of the modules. I would hate to document "oh, if you can't load your > OS, try using fewer GRUB modules." On the other hand, we already have > this problem to some extent: if our modules are too large, we will > fail to allocate any heap. So maybe this isn't a practical concern. Yep, the problem already exists. In the end, it's just a matter of which MIN_HEAP_SIZE do we pick. -- Robert Millan My spam trap is [EMAIL PROTECTED] Note: this address is only intended for spam harvesters. Writing to it will get you added to my black list. _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel