Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mm: remove blackfin MPU support

The CONFIG_MPU option was only defined on blackfin, and that architecture
is now being removed, so the respective code can be simplified.

A lot of other microcontrollers have an MPU, but I suspect that if we
want to bring that support back, we'd do it differently anyway.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>

-24
-4
kernel/module.c
··· 2181 2181 /* Finally, free the core (containing the module structure) */ 2182 2182 disable_ro_nx(&mod->core_layout); 2183 2183 module_memfree(mod->core_layout.base); 2184 - 2185 - #ifdef CONFIG_MPU 2186 - update_protections(current->mm); 2187 - #endif 2188 2184 } 2189 2185 2190 2186 void *__symbol_get(const char *symbol)
-20
mm/nommu.c
··· 663 663 } 664 664 665 665 /* 666 - * update protection on a vma 667 - */ 668 - static void protect_vma(struct vm_area_struct *vma, unsigned long flags) 669 - { 670 - #ifdef CONFIG_MPU 671 - struct mm_struct *mm = vma->vm_mm; 672 - long start = vma->vm_start & PAGE_MASK; 673 - while (start < vma->vm_end) { 674 - protect_page(mm, start, flags); 675 - start += PAGE_SIZE; 676 - } 677 - update_protections(mm); 678 - #endif 679 - } 680 - 681 - /* 682 666 * add a VMA into a process's mm_struct in the appropriate place in the list 683 667 * and tree and add to the address space's page tree also if not an anonymous 684 668 * page ··· 678 694 679 695 mm->map_count++; 680 696 vma->vm_mm = mm; 681 - 682 - protect_vma(vma, vma->vm_flags); 683 697 684 698 /* add the VMA to the mapping */ 685 699 if (vma->vm_file) { ··· 738 756 struct address_space *mapping; 739 757 struct mm_struct *mm = vma->vm_mm; 740 758 struct task_struct *curr = current; 741 - 742 - protect_vma(vma, 0); 743 759 744 760 mm->map_count--; 745 761 for (i = 0; i < VMACACHE_SIZE; i++) {