|
@@ -105,7 +105,7 @@ out:
|
|
|
static void find_start_end(unsigned long addr, unsigned long flags,
|
|
|
unsigned long *begin, unsigned long *end)
|
|
|
{
|
|
|
- if (!in_compat_syscall() && (flags & MAP_32BIT)) {
|
|
|
+ if (!in_32bit_syscall() && (flags & MAP_32BIT)) {
|
|
|
/* This is usually used needed to map code in small
|
|
|
model, so it needs to be in the first 31bit. Limit
|
|
|
it to that. This means we need to move the
|
|
@@ -122,7 +122,7 @@ static void find_start_end(unsigned long addr, unsigned long flags,
|
|
|
}
|
|
|
|
|
|
*begin = get_mmap_base(1);
|
|
|
- if (in_compat_syscall())
|
|
|
+ if (in_32bit_syscall())
|
|
|
*end = task_size_32bit();
|
|
|
else
|
|
|
*end = task_size_64bit(addr > DEFAULT_MAP_WINDOW);
|
|
@@ -193,7 +193,7 @@ arch_get_unmapped_area_topdown(struct file *filp, const unsigned long addr0,
|
|
|
return addr;
|
|
|
|
|
|
/* for MAP_32BIT mappings we force the legacy mmap base */
|
|
|
- if (!in_compat_syscall() && (flags & MAP_32BIT))
|
|
|
+ if (!in_32bit_syscall() && (flags & MAP_32BIT))
|
|
|
goto bottomup;
|
|
|
|
|
|
/* requesting a specific address */
|
|
@@ -217,9 +217,10 @@ get_unmapped_area:
|
|
|
* If hint address is above DEFAULT_MAP_WINDOW, look for unmapped area
|
|
|
* in the full address space.
|
|
|
*
|
|
|
- * !in_compat_syscall() check to avoid high addresses for x32.
|
|
|
+ * !in_32bit_syscall() check to avoid high addresses for x32
|
|
|
+ * (and make it no op on native i386).
|
|
|
*/
|
|
|
- if (addr > DEFAULT_MAP_WINDOW && !in_compat_syscall())
|
|
|
+ if (addr > DEFAULT_MAP_WINDOW && !in_32bit_syscall())
|
|
|
info.high_limit += TASK_SIZE_MAX - DEFAULT_MAP_WINDOW;
|
|
|
|
|
|
info.align_mask = 0;
|