From dc6839f036cb55a7b3863916e38e8d02716534d7 Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Fri, 15 Dec 2017 01:04:53 +0000 Subject: [PATCH] fs-elf-drop-map_fixed-usage-from-elf_map-checkpatch-fixes ERROR: Please use git commit description style 'commit <12+ chars of sha1> ("")' - ie: 'commit 0123456789ab ("commit description")' #8: (before eab09532d400 ("binfmt_elf: use ELF_ET_DYN_BASE only for PIE")) ERROR: Please use git commit description style 'commit <12+ chars of sha1> ("<title line>")' - ie: 'commit 0123456789ab ("commit description")' #15: further from the stack (eab09532d400 and later by c715b72c1ba4 ("mm: ERROR: Please use git commit description style 'commit <12+ chars of sha1> ("<title line>")' - ie: 'commit 0123456789ab ("commit description")' #17: stack consumption early during execve fully stopped by da029c11e6b1 WARNING: 'segement' may be misspelled - perhaps 'segment'? #64: FILE: arch/metag/kernel/process.c:421: + pr_info("%d (%s): Uhuuh, elf segement at %p requested but the memory is mapped already\n", ERROR: "(foo*)" should be "(foo *)" #65: FILE: arch/metag/kernel/process.c:422: + task_pid_nr(current), tsk->comm, (void*)addr); WARNING: 'segement' may be misspelled - perhaps 'segment'? #78: FILE: fs/binfmt_elf.c:381: + pr_info("%d (%s): Uhuuh, elf segement at %p requested but the memory is mapped already\n", WARNING: line over 80 characters #79: FILE: fs/binfmt_elf.c:382: + task_pid_nr(current), current->comm, (void*)addr); ERROR: "(foo*)" should be "(foo *)" #79: FILE: fs/binfmt_elf.c:382: + task_pid_nr(current), current->comm, (void*)addr); total: 5 errors, 3 warnings, 60 lines checked NOTE: For some of the reported defects, checkpatch may be able to mechanically convert to the typical style using --fix or --fix-inplace. ./patches/fs-elf-drop-map_fixed-usage-from-elf_map.patch has style problems, please review. NOTE: If any of the errors are false positives, please report them to the maintainer, see CHECKPATCH in MAINTAINERS. Please run checkpatch prior to sending patches Cc: Michal Hocko <mhocko@suse.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> --- arch/metag/kernel/process.c | 4 ++-- fs/binfmt_elf.c | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/arch/metag/kernel/process.c b/arch/metag/kernel/process.c index 867c8d0a5fb4da..c586131475a254 100644 --- a/arch/metag/kernel/process.c +++ b/arch/metag/kernel/process.c @@ -418,8 +418,8 @@ unsigned long __metag_elf_map(struct file *filep, unsigned long addr, map_addr = vm_mmap(filep, addr, size, prot, type, off); if ((type & MAP_FIXED_SAFE) && BAD_ADDR(map_addr)) - pr_info("%d (%s): Uhuuh, elf segement at %p requested but the memory is mapped already\n", - task_pid_nr(current), tsk->comm, (void*)addr); + pr_info("%d (%s): Uhuuh, elf segment at %p requested but the memory is mapped already\n", + task_pid_nr(current), tsk->comm, (void *)addr); if (!BAD_ADDR(map_addr) && tcm_tag != TCM_INVALID_TAG) { struct tcm_allocation *tcm; diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c index f133d69743403b..20cfc80648166e 100644 --- a/fs/binfmt_elf.c +++ b/fs/binfmt_elf.c @@ -378,8 +378,9 @@ static unsigned long elf_map(struct file *filep, unsigned long addr, map_addr = vm_mmap(filep, addr, size, prot, type, off); if ((type & MAP_FIXED_SAFE) && BAD_ADDR(map_addr)) - pr_info("%d (%s): Uhuuh, elf segement at %p requested but the memory is mapped already\n", - task_pid_nr(current), current->comm, (void*)addr); + pr_info("%d (%s): Uhuuh, elf segment at %p requested but the memory is mapped already\n", + task_pid_nr(current), current->comm, + (void *)addr); return(map_addr); }