diff options
Diffstat (limited to 'arch/alpha/kernel/osf_sys.c')
-rw-r--r-- | arch/alpha/kernel/osf_sys.c | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index dbc1760f418b..b9e37ad6fa19 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c | |||
@@ -1300,17 +1300,15 @@ static unsigned long | |||
1300 | arch_get_unmapped_area_1(unsigned long addr, unsigned long len, | 1300 | arch_get_unmapped_area_1(unsigned long addr, unsigned long len, |
1301 | unsigned long limit) | 1301 | unsigned long limit) |
1302 | { | 1302 | { |
1303 | struct vm_area_struct *vma = find_vma(current->mm, addr); | 1303 | struct vm_unmapped_area_info info; |
1304 | 1304 | ||
1305 | while (1) { | 1305 | info.flags = 0; |
1306 | /* At this point: (!vma || addr < vma->vm_end). */ | 1306 | info.length = len; |
1307 | if (limit - len < addr) | 1307 | info.low_limit = addr; |
1308 | return -ENOMEM; | 1308 | info.high_limit = limit; |
1309 | if (!vma || addr + len <= vma->vm_start) | 1309 | info.align_mask = 0; |
1310 | return addr; | 1310 | info.align_offset = 0; |
1311 | addr = vma->vm_end; | 1311 | return vm_unmapped_area(&info); |
1312 | vma = vma->vm_next; | ||
1313 | } | ||
1314 | } | 1312 | } |
1315 | 1313 | ||
1316 | unsigned long | 1314 | unsigned long |