From: Hua Zhong Date: Fri, 23 Jun 2006 09:03:23 +0000 (-0700) Subject: [PATCH] likely cleanup: remove unlikely in sys_mprotect() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=b344e05c585406904c70865e531e02467c4c7931;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git [PATCH] likely cleanup: remove unlikely in sys_mprotect() With likely/unlikely profiling on my not-so-busy-typical-developmentsystem there are 5k misses vs 2k hits. So I guess we should remove the unlikely. Signed-off-by: Hua Zhong Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/mprotect.c b/mm/mprotect.c index 4c14d4289b61..5faf01ad3ef8 100644 --- a/mm/mprotect.c +++ b/mm/mprotect.c @@ -205,8 +205,7 @@ sys_mprotect(unsigned long start, size_t len, unsigned long prot) /* * Does the application expect PROT_READ to imply PROT_EXEC: */ - if (unlikely((prot & PROT_READ) && - (current->personality & READ_IMPLIES_EXEC))) + if ((prot & PROT_READ) && (current->personality & READ_IMPLIES_EXEC)) prot |= PROT_EXEC; vm_flags = calc_vm_prot_bits(prot);