lkml.org 
[lkml]   [2008]   [Apr]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectEMM: Fix rcu handling and spelling
Subject: EMM: Fix rcu handling and spelling

Fix the way rcu_dereference is done.

Signed-off-by: Christoph Lameter <clameter@sgi.com>

---
include/linux/rmap.h | 2 +-
mm/rmap.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)

Index: linux-2.6/include/linux/rmap.h
===================================================================
--- linux-2.6.orig/include/linux/rmap.h 2008-04-02 11:41:58.737866596 -0700
+++ linux-2.6/include/linux/rmap.h 2008-04-02 11:42:08.282029661 -0700
@@ -91,7 +91,7 @@ static inline void page_dup_rmap(struct
* when the VM removes references to pages.
*/
enum emm_operation {
- emm_release, /* Process existing, */
+ emm_release, /* Process exiting, */
emm_invalidate_start, /* Before the VM unmaps pages */
emm_invalidate_end, /* After the VM unmapped pages */
emm_referenced /* Check if a range was referenced */
Index: linux-2.6/mm/rmap.c
===================================================================
--- linux-2.6.orig/mm/rmap.c 2008-04-02 11:41:58.737866596 -0700
+++ linux-2.6/mm/rmap.c 2008-04-02 11:42:08.282029661 -0700
@@ -303,7 +303,7 @@ EXPORT_SYMBOL_GPL(emm_notifier_register)
int __emm_notify(struct mm_struct *mm, enum emm_operation op,
unsigned long start, unsigned long end)
{
- struct emm_notifier *e = rcu_dereference(mm)->emm_notifier;
+ struct emm_notifier *e = rcu_dereference(mm->emm_notifier);
int x;

while (e) {
@@ -317,7 +317,7 @@ int __emm_notify(struct mm_struct *mm, e
* emm_notifier contents (e) must be fetched after
* the retrival of the pointer to the notifier.
*/
- e = rcu_dereference(e)->next;
+ e = rcu_dereference(e->next);
}
return 0;
}


\
 
 \ /
  Last update: 2008-04-02 20:49    [W:0.497 / U:0.236 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site