All of lore.kernel.org
 help / color / mirror / Atom feed
* patch for kern/efi/mm.c (big memmap)
@ 2006-09-28 11:48 tgingold
  2006-09-28 13:00 ` Marco Gerards
  2006-09-28 14:01 ` Johan Rydberg
  0 siblings, 2 replies; 8+ messages in thread
From: tgingold @ 2006-09-28 11:48 UTC (permalink / raw)
  To: grub-devel

[-- Attachment #1: Type: text/plain, Size: 105 bytes --]



Hi,

some systems have a really big memmap.
This patch remove the memmap size limit.

Tristan.

[-- Attachment #2: mm.diffs --]
[-- Type: application/octet-stream, Size: 1057 bytes --]

33,36d32
< /* The size of a memory map obtained from the firmware. This must be
<    a multiplier of 4KB.  */
< #define MEMORY_MAP_SIZE	0x1000
< 
348a345,346
>   grub_efi_uintn_t memory_map_size;
>   int res;
359,360c357,363
<   memory_map = grub_efi_allocate_pages (0,
< 					2 * BYTES_TO_PAGES (MEMORY_MAP_SIZE));
---
>   memory_map_size = 0;
>   res = grub_efi_get_memory_map (&memory_map_size, NULL, 0, &desc_size, 0);
>   if (res != 0)
>     grub_fatal ("cannot get memory map size");
> 
>   memory_map = grub_efi_allocate_pages
>     (0, 2 * BYTES_TO_PAGES (memory_map_size + 0x1000));
364c367
<   filtered_memory_map = NEXT_MEMORY_DESCRIPTOR (memory_map, MEMORY_MAP_SIZE);
---
>   filtered_memory_map = NEXT_MEMORY_DESCRIPTOR (memory_map, memory_map_size);
367c370
<   map_size = MEMORY_MAP_SIZE;
---
>   map_size = memory_map_size;
376c379
<   
---
> 
396c399
<   map_size = MEMORY_MAP_SIZE;
---
>   map_size = memory_map_size;
409c412
< 		       2 * BYTES_TO_PAGES (MEMORY_MAP_SIZE));
---
> 		       2 * BYTES_TO_PAGES (memory_map_size + 0x1000));

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2006-09-28 14:09 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-28 11:48 patch for kern/efi/mm.c (big memmap) tgingold
2006-09-28 13:00 ` Marco Gerards
2006-09-28 13:04   ` tgingold
2006-09-28 13:41     ` Marco Gerards
2006-09-28 14:01 ` Johan Rydberg
2006-09-28 13:52   ` Marco Gerards
2006-09-28 14:24     ` Johan Rydberg
2006-09-28 14:16       ` Marco Gerards

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.