aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/lib/alloc.c
blob: e58c80590ebcd274edbacd1dccf2f63578595b24 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <linux/types.h>
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/bootmem.h>

#include <asm/system.h>

void * __init_refok alloc_maybe_bootmem(size_t size, gfp_t mask)
{
	if (mem_init_done)
		return kmalloc(size, mask);
	else
		return alloc_bootmem(size);
}