lkml.org 
[lkml]   [2009]   [Dec]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH 07/24] HWPOISON: comment the possible set_page_dirty() race
CC: Andi Kleen <andi@firstfloor.org> 
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
---
mm/memory-failure.c | 2 ++
1 file changed, 2 insertions(+)

--- linux-mm.orig/mm/memory-failure.c 2009-11-30 11:11:25.000000000 +0800
+++ linux-mm/mm/memory-failure.c 2009-11-30 11:12:41.000000000 +0800
@@ -667,6 +667,8 @@ static int hwpoison_user_mappings(struct
/*
* Propagate the dirty bit from PTEs to struct page first, because we
* need this to decide if we should kill or just drop the page.
+ * XXX: the dirty test could be racy: set_page_dirty() may not always
+ * be called inside page lock (it's recommended but not enforced).
*/
mapping = page_mapping(p);
if (!PageDirty(p) && mapping && mapping_cap_writeback_dirty(mapping)) {



\
 
 \ /
  Last update: 2009-12-02 05:41    [W:0.816 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site