mm, vmscan: move lru_lock to the node
[linux-2.6-block.git] / include / linux / mm_types.h
index ca3e517980a0a2d3d58c6566350456f828e4446f..903200f4ec41ce03c50c15bfa079d5a01f903afa 100644 (file)
@@ -60,51 +60,52 @@ struct page {
        };
 
        /* Second double word */
-       struct {
-               union {
-                       pgoff_t index;          /* Our offset within mapping. */
-                       void *freelist;         /* sl[aou]b first free object */
-                       /* page_deferred_list().prev    -- second tail page */
-               };
+       union {
+               pgoff_t index;          /* Our offset within mapping. */
+               void *freelist;         /* sl[aou]b first free object */
+               /* page_deferred_list().prev    -- second tail page */
+       };
 
-               union {
+       union {
 #if defined(CONFIG_HAVE_CMPXCHG_DOUBLE) && \
        defined(CONFIG_HAVE_ALIGNED_STRUCT_PAGE)
-                       /* Used for cmpxchg_double in slub */
-                       unsigned long counters;
+               /* Used for cmpxchg_double in slub */
+               unsigned long counters;
 #else
-                       /*
-                        * Keep _refcount separate from slub cmpxchg_double
-                        * data.  As the rest of the double word is protected by
-                        * slab_lock but _refcount is not.
-                        */
-                       unsigned counters;
+               /*
+                * Keep _refcount separate from slub cmpxchg_double data.
+                * As the rest of the double word is protected by slab_lock
+                * but _refcount is not.
+                */
+               unsigned counters;
 #endif
+               struct {
 
-                       struct {
-
-                               union {
-                                       /*
-                                        * Count of ptes mapped in mms, to show
-                                        * when page is mapped & limit reverse
-                                        * map searches.
-                                        */
-                                       atomic_t _mapcount;
-
-                                       struct { /* SLUB */
-                                               unsigned inuse:16;
-                                               unsigned objects:15;
-                                               unsigned frozen:1;
-                                       };
-                                       int units;      /* SLOB */
-                               };
+                       union {
                                /*
-                                * Usage count, *USE WRAPPER FUNCTION*
-                                * when manual accounting. See page_ref.h
+                                * Count of ptes mapped in mms, to show when
+                                * page is mapped & limit reverse map searches.
+                                *
+                                * Extra information about page type may be
+                                * stored here for pages that are never mapped,
+                                * in which case the value MUST BE <= -2.
+                                * See page-flags.h for more details.
                                 */
-                               atomic_t _refcount;
+                               atomic_t _mapcount;
+
+                               unsigned int active;            /* SLAB */
+                               struct {                        /* SLUB */
+                                       unsigned inuse:16;
+                                       unsigned objects:15;
+                                       unsigned frozen:1;
+                               };
+                               int units;                      /* SLOB */
                        };
-                       unsigned int active;    /* SLAB */
+                       /*
+                        * Usage count, *USE WRAPPER FUNCTION* when manual
+                        * accounting. See page_ref.h
+                        */
+                       atomic_t _refcount;
                };
        };
 
@@ -117,7 +118,7 @@ struct page {
         */
        union {
                struct list_head lru;   /* Pageout list, eg. active_list
-                                        * protected by zone->lru_lock !
+                                        * protected by zone_lru_lock !
                                         * Can be used as a generic list
                                         * by the page owner.
                                         */
@@ -594,6 +595,9 @@ struct vm_special_mapping {
        int (*fault)(const struct vm_special_mapping *sm,
                     struct vm_area_struct *vma,
                     struct vm_fault *vmf);
+
+       int (*mremap)(const struct vm_special_mapping *sm,
+                    struct vm_area_struct *new_vma);
 };
 
 enum tlb_flush_reason {