patch-2.3.36 linux/mm/memory.c
Next file: linux/net/bridge/br.c
Previous file: linux/mm/highmem.c
Back to the patch index
Back to the overall index
- Lines: 44
- Date:
Wed Dec 29 11:42:07 1999
- Orig file:
v2.3.35/linux/mm/memory.c
- Orig date:
Tue Dec 14 01:27:24 1999
diff -u --recursive --new-file v2.3.35/linux/mm/memory.c linux/mm/memory.c
@@ -712,43 +712,6 @@
}
/*
- * This routine is used to map in a page into an address space: needed by
- * execve() for the initial stack and environment pages.
- */
-struct page * put_dirty_page(struct task_struct * tsk, struct page *page,
- unsigned long address)
-{
- pgd_t * pgd;
- pmd_t * pmd;
- pte_t * pte;
-
- if (page_count(page) != 1)
- printk("mem_map disagrees with %p at %08lx\n", page, address);
- pgd = pgd_offset(tsk->mm, address);
- pmd = pmd_alloc(pgd, address);
- if (!pmd) {
- __free_page(page);
- oom(tsk);
- return 0;
- }
- pte = pte_alloc(pmd, address);
- if (!pte) {
- __free_page(page);
- oom(tsk);
- return 0;
- }
- if (!pte_none(*pte)) {
- pte_ERROR(*pte);
- __free_page(page);
- return 0;
- }
- flush_page_to_ram(page);
- set_pte(pte, pte_mkwrite(mk_pte(page, PAGE_COPY)));
-/* no need for flush_tlb */
- return page;
-}
-
-/*
* This routine handles present pages, when users try to write
* to a shared page. It is done by copying the page to a new address
* and decrementing the shared-page counter for the old page.
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)