Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=9e86943b6c74f214ce0516d56e55636d52252e19
Commit:     9e86943b6c74f214ce0516d56e55636d52252e19
Parent:     fe58103a56f05613cb1f0ef228354d4d5f6c2b08
Author:     Christoph Lameter <[EMAIL PROTECTED]>
AuthorDate: Wed Aug 22 14:01:56 2007 -0700
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Wed Aug 22 19:52:47 2007 -0700

    SLUB: use atomic_long_read for atomic_long variables
    
    SLUB is using atomic_read() for variables declared atomic_long_t.
    Switch to atomic_long_read().
    
    Signed-off-by: Christoph Lameter <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 mm/slub.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/mm/slub.c b/mm/slub.c
index 69d02e3..0c106d7 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -3112,7 +3112,7 @@ static int list_locations(struct kmem_cache *s, char *buf,
                unsigned long flags;
                struct page *page;
 
-               if (!atomic_read(&n->nr_slabs))
+               if (!atomic_long_read(&n->nr_slabs))
                        continue;
 
                spin_lock_irqsave(&n->list_lock, flags);
@@ -3247,7 +3247,7 @@ static unsigned long slab_objects(struct kmem_cache *s,
                }
 
                if (flags & SO_FULL) {
-                       int full_slabs = atomic_read(&n->nr_slabs)
+                       int full_slabs = atomic_long_read(&n->nr_slabs)
                                        - per_cpu[node]
                                        - n->nr_partial;
 
@@ -3283,7 +3283,7 @@ static int any_slab_objects(struct kmem_cache *s)
        for_each_node(node) {
                struct kmem_cache_node *n = get_node(s, node);
 
-               if (n->nr_partial || atomic_read(&n->nr_slabs))
+               if (n->nr_partial || atomic_long_read(&n->nr_slabs))
                        return 1;
        }
        return 0;
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to