diff options
author | Yinghai Lu <yinghai@kernel.org> | 2013-01-24 12:20:15 -0800 |
---|---|---|
committer | H. Peter Anvin <hpa@linux.intel.com> | 2013-01-29 19:32:59 -0800 |
commit | 38fa4175e60d98fb1c9815fb14f8057576dade73 (patch) | |
tree | 37472101af7cc4ed35b11b414a0ea8f9ac1d81db /mm | |
parent | 8b78c21d72d9dbcb7230e97423a2cd8d8402c20c (diff) | |
download | linux-3.10-38fa4175e60d98fb1c9815fb14f8057576dade73.tar.gz linux-3.10-38fa4175e60d98fb1c9815fb14f8057576dade73.tar.bz2 linux-3.10-38fa4175e60d98fb1c9815fb14f8057576dade73.zip |
mm: Add alloc_bootmem_low_pages_nopanic()
We don't need to panic in some case, like for swiotlb preallocating.
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
Link: http://lkml.kernel.org/r/1359058816-7615-35-git-send-email-yinghai@kernel.org
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/bootmem.c | 8 | ||||
-rw-r--r-- | mm/nobootmem.c | 8 |
2 files changed, 16 insertions, 0 deletions
diff --git a/mm/bootmem.c b/mm/bootmem.c index b93376c39b6..2b0bcb019ec 100644 --- a/mm/bootmem.c +++ b/mm/bootmem.c @@ -833,6 +833,14 @@ void * __init __alloc_bootmem_low(unsigned long size, unsigned long align, return ___alloc_bootmem(size, align, goal, ARCH_LOW_ADDRESS_LIMIT); } +void * __init __alloc_bootmem_low_nopanic(unsigned long size, + unsigned long align, + unsigned long goal) +{ + return ___alloc_bootmem_nopanic(size, align, goal, + ARCH_LOW_ADDRESS_LIMIT); +} + /** * __alloc_bootmem_low_node - allocate low boot memory from a specific node * @pgdat: node to allocate from diff --git a/mm/nobootmem.c b/mm/nobootmem.c index 03d152a76ac..5e07d36e381 100644 --- a/mm/nobootmem.c +++ b/mm/nobootmem.c @@ -391,6 +391,14 @@ void * __init __alloc_bootmem_low(unsigned long size, unsigned long align, return ___alloc_bootmem(size, align, goal, ARCH_LOW_ADDRESS_LIMIT); } +void * __init __alloc_bootmem_low_nopanic(unsigned long size, + unsigned long align, + unsigned long goal) +{ + return ___alloc_bootmem_nopanic(size, align, goal, + ARCH_LOW_ADDRESS_LIMIT); +} + /** * __alloc_bootmem_low_node - allocate low boot memory from a specific node * @pgdat: node to allocate from |