From: "Paolo 'Blaisorblade' Giarrusso" <blaisorblade@yahoo.it>
To: Linus Torvalds <torvalds@osdl.org>
Cc: Jeff Dike <jdike@addtoit.com>,
Paolo Blaisorblade Giarrusso <blaisorblade@yahoo.it>,
LKML <linux-kernel@vger.kernel.org>,
user-mode-linux-devel@lists.sourceforge.net
Subject: [uml-devel] [patch 6/7] uml: avoid already done dirtying
Date: Sat, 10 Sep 2005 19:44:58 +0200 [thread overview]
Message-ID: <20050910174629.706033000@zion.home.lan> (raw)
In-Reply-To: 20050910174452.907256000@zion.home.lan
[-- Attachment #1: uml-avoid-already-done-dirtying --]
[-- Type: text/plain, Size: 1448 bytes --]
The PTE returned from handle_mm_fault is already marked as dirty and accessed
if needed.
Also, since this is not set with set_pte() (which sets NEWPAGE and NEWPROT as
needed), this wouldn't work anyway.
This version has been updated and fixed, thanks to some feedback from Jeff Dike.
Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
---
arch/um/kernel/trap_kern.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/arch/um/kernel/trap_kern.c b/arch/um/kernel/trap_kern.c
--- a/arch/um/kernel/trap_kern.c
+++ b/arch/um/kernel/trap_kern.c
@@ -85,8 +85,7 @@ survive:
pte = pte_offset_kernel(pmd, address);
} while(!pte_present(*pte));
err = 0;
- *pte = pte_mkyoung(*pte);
- if(pte_write(*pte)) *pte = pte_mkdirty(*pte);
+ WARN_ON(!pte_young(*pte) || (is_write && !pte_dirty(*pte)));
flush_tlb_page(vma, address);
out:
up_read(&mm->mmap_sem);
--
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel
next prev parent reply other threads:[~2005-09-10 18:04 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-09-10 17:44 [uml-devel] [patch 0/7] Uml merge for 2.6.14 Paolo 'Blaisorblade' Giarrusso
2005-09-10 17:44 ` [uml-devel] [patch 1/7] Uml: more cleaning Paolo 'Blaisorblade' Giarrusso
2005-09-10 17:44 ` [uml-devel] [patch 2/7] i386 / uml: add dwarf sections to static link script Paolo 'Blaisorblade' Giarrusso
2005-09-10 18:38 ` [uml-devel] " Sam Ravnborg
2005-09-10 17:44 ` [uml-devel] [patch 3/7] x86_64 linker script cleanups for debug sections Paolo 'Blaisorblade' Giarrusso
2005-09-10 17:44 ` [uml-devel] [patch 4/7] uml: inline mk_pte and various friends Paolo 'Blaisorblade' Giarrusso
2005-09-10 17:44 ` [uml-devel] [patch 5/7] uml: fix fault handler on write Paolo 'Blaisorblade' Giarrusso
2005-09-10 17:44 ` Paolo 'Blaisorblade' Giarrusso [this message]
2005-09-10 17:44 ` [uml-devel] [patch 7/7] uml: retry host close() on EINTR Paolo 'Blaisorblade' Giarrusso
2005-09-10 19:00 ` [uml-devel] " Linus Torvalds
2005-09-11 7:28 ` Paolo Ornati
2005-09-11 11:49 ` Linus Torvalds
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050910174629.706033000@zion.home.lan \
--to=blaisorblade@yahoo.it \
--cc=jdike@addtoit.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.org \
--cc=user-mode-linux-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox