提交 66521d5a 编写于 作者: D Dominik Dingel 提交者: Linus Torvalds

mm/memory.c: remove unused code from do_wp_page()

page_mkwrite is initalized with zero and only set once, from that point
exists no way to get to the oom or oom_free_new labels.

[akpm@linux-foundation.org: cleanup]
Signed-off-by: NDominik Dingel <dingel@linux.vnet.ibm.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 816422ad
......@@ -2780,13 +2780,8 @@ static int do_wp_page(struct mm_struct *mm, struct vm_area_struct *vma,
oom_free_new:
page_cache_release(new_page);
oom:
if (old_page) {
if (page_mkwrite) {
unlock_page(old_page);
page_cache_release(old_page);
}
if (old_page)
page_cache_release(old_page);
}
return VM_FAULT_OOM;
unwritable_page:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册