Skip to content

Commit e8f01a8

Browse files
kirylIngo Molnar
authored andcommitted
x86/mm: Rename tasksize_32bit/64bit to task_size_32bit/64bit()
Rename these helpers to be consistent with spelling of TASK_SIZE and related constants. Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Andy Lutomirski <luto@amacapital.net> Cc: Dave Hansen <dave.hansen@intel.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-arch@vger.kernel.org Cc: linux-mm@kvack.org Link: http://lkml.kernel.org/r/20170716225954.74185-5-kirill.shutemov@linux.intel.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
1 parent daaa42f commit e8f01a8

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

arch/x86/include/asm/elf.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -304,8 +304,8 @@ static inline int mmap_is_ia32(void)
304304
test_thread_flag(TIF_ADDR32));
305305
}
306306

307-
extern unsigned long tasksize_32bit(void);
308-
extern unsigned long tasksize_64bit(void);
307+
extern unsigned long task_size_32bit(void);
308+
extern unsigned long task_size_64bit(void);
309309
extern unsigned long get_mmap_base(int is_legacy);
310310

311311
#ifdef CONFIG_X86_32

arch/x86/kernel/sys_x86_64.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ static void find_start_end(unsigned long flags, unsigned long *begin,
120120
}
121121

122122
*begin = get_mmap_base(1);
123-
*end = in_compat_syscall() ? tasksize_32bit() : tasksize_64bit();
123+
*end = in_compat_syscall() ? task_size_32bit() : task_size_64bit();
124124
}
125125

126126
unsigned long

arch/x86/mm/hugetlbpage.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ static unsigned long hugetlb_get_unmapped_area_bottomup(struct file *file,
8686
info.length = len;
8787
info.low_limit = get_mmap_base(1);
8888
info.high_limit = in_compat_syscall() ?
89-
tasksize_32bit() : tasksize_64bit();
89+
task_size_32bit() : task_size_64bit();
9090
info.align_mask = PAGE_MASK & ~huge_page_mask(h);
9191
info.align_offset = 0;
9292
return vm_unmapped_area(&info);

arch/x86/mm/mmap.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,12 @@ struct va_alignment __read_mostly va_align = {
3737
.flags = -1,
3838
};
3939

40-
unsigned long tasksize_32bit(void)
40+
unsigned long task_size_32bit(void)
4141
{
4242
return IA32_PAGE_OFFSET;
4343
}
4444

45-
unsigned long tasksize_64bit(void)
45+
unsigned long task_size_64bit(void)
4646
{
4747
return TASK_SIZE_MAX;
4848
}
@@ -52,7 +52,7 @@ static unsigned long stack_maxrandom_size(unsigned long task_size)
5252
unsigned long max = 0;
5353
if ((current->flags & PF_RANDOMIZE) &&
5454
!(current->personality & ADDR_NO_RANDOMIZE)) {
55-
max = (-1UL) & __STACK_RND_MASK(task_size == tasksize_32bit());
55+
max = (-1UL) & __STACK_RND_MASK(task_size == task_size_32bit());
5656
max <<= PAGE_SHIFT;
5757
}
5858

@@ -142,7 +142,7 @@ void arch_pick_mmap_layout(struct mm_struct *mm)
142142
mm->get_unmapped_area = arch_get_unmapped_area_topdown;
143143

144144
arch_pick_mmap_base(&mm->mmap_base, &mm->mmap_legacy_base,
145-
arch_rnd(mmap64_rnd_bits), tasksize_64bit());
145+
arch_rnd(mmap64_rnd_bits), task_size_64bit());
146146

147147
#ifdef CONFIG_HAVE_ARCH_COMPAT_MMAP_BASES
148148
/*
@@ -152,7 +152,7 @@ void arch_pick_mmap_layout(struct mm_struct *mm)
152152
* mmap_base, the compat syscall uses mmap_compat_base.
153153
*/
154154
arch_pick_mmap_base(&mm->mmap_compat_base, &mm->mmap_compat_legacy_base,
155-
arch_rnd(mmap32_rnd_bits), tasksize_32bit());
155+
arch_rnd(mmap32_rnd_bits), task_size_32bit());
156156
#endif
157157
}
158158

0 commit comments

Comments
 (0)