Fix compiler warnings
Macro to generate page allocation functions

the DEFINE_ALLOCATOR() macro generates functions for allocating pools of
objects page-at-a-time.  It is currently used in kernel/timer.c for
timer allocation.