CPA: Minor code-style cleanups to change_page_attr Remove a one liner function and expand into parent. No functional changes. Signed-off-by: Andi Kleen --- arch/x86/mm/pageattr_32.c | 7 +------ arch/x86/mm/pageattr_64.c | 7 +------ 2 files changed, 2 insertions(+), 12 deletions(-) Index: linux/arch/x86/mm/pageattr_64.c =================================================================== --- linux.orig/arch/x86/mm/pageattr_64.c +++ linux/arch/x86/mm/pageattr_64.c @@ -95,11 +95,6 @@ static void flush_kernel_map(void *arg) __flush_tlb_all(); } -static inline void flush_map(struct list_head *l) -{ - on_each_cpu(flush_kernel_map, l, 1, 1); -} - /* both protected by init_mm.mmap_sem */ static int full_flush; static LIST_HEAD(deferred_pages); @@ -278,7 +273,7 @@ void global_flush_tlb(void) list_replace_init(&deferred_pages, &free_pages); up_write(&init_mm.mmap_sem); - flush_map(&arg); + on_each_cpu(flush_kernel_map, &arg, 1, 1); list_for_each_entry_safe(pg, next, &free_pages, lru) { list_del(&pg->lru); Index: linux/arch/x86/mm/pageattr_32.c =================================================================== --- linux.orig/arch/x86/mm/pageattr_32.c +++ linux/arch/x86/mm/pageattr_32.c @@ -234,11 +234,6 @@ __change_page_attr(struct page *page, pg return 0; } -static inline void flush_map(struct list_head *l) -{ - on_each_cpu(flush_kernel_map, l, 1, 1); -} - /* * Change the page attributes of an page in the linear mapping. * @@ -282,7 +277,9 @@ void global_flush_tlb(void) list_replace_init(&flush_pages, &arg.l); list_replace_init(&df_list, &free_pages); spin_unlock_irq(&cpa_lock); - flush_map(&arg); + + on_each_cpu(flush_kernel_map, &arg, 1, 1); + list_for_each_entry_safe(pg, next, &free_pages, lru) { list_del(&pg->lru); clear_bit(PG_arch_1, &pg->flags);