Skip to content

Commit

Permalink
x86: add RESERVE_BRK_ARRAY() helper
Browse files Browse the repository at this point in the history
Useful when converting static arrays into boottime brk allocated objects.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
  • Loading branch information
Jeremy Fitzhardinge committed Oct 22, 2010
1 parent cd07202 commit 5e941c0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions arch/x86/include/asm/setup.h
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,11 @@ void *extend_brk(size_t size, size_t align);
: : "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__

void __init i386_start_kernel(void);
Expand Down

0 comments on commit 5e941c0

Please sign in to comment.