Commit 5e941c09 authored by Jeremy Fitzhardinge's avatar Jeremy Fitzhardinge

x86: add RESERVE_BRK_ARRAY() helper

Useful when converting static arrays into boottime brk allocated objects.
Signed-off-by: default avatarJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
parent cd07202c
...@@ -93,6 +93,11 @@ void *extend_brk(size_t size, size_t align); ...@@ -93,6 +93,11 @@ void *extend_brk(size_t size, size_t align);
: : "i" (sz)); \ : : "i" (sz)); \
} }
/* Helper for reserving space for arrays of things */
#define RESERVE_BRK_ARRAY(type, name, entries) \
type *name; \
RESERVE_BRK(name, sizeof(type) * entries)
#ifdef __i386__ #ifdef __i386__
void __init i386_start_kernel(void); void __init i386_start_kernel(void);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment