mm, oom_reaper: do not mmput synchronously from the oom reaper context
[linux-2.6-block.git] / include / linux / mm_types.h
index c2d75b4fa86c05012a509dd188e2a394d2cb2170..d553855503e6a8ecf80aad21486aefa44b577770 100644 (file)
@@ -12,6 +12,7 @@
 #include <linux/cpumask.h>
 #include <linux/uprobes.h>
 #include <linux/page-flags-layout.h>
+#include <linux/workqueue.h>
 #include <asm/page.h>
 #include <asm/mmu.h>
 
@@ -73,9 +74,9 @@ struct page {
                        unsigned long counters;
 #else
                        /*
-                        * Keep _count separate from slub cmpxchg_double data.
-                        * As the rest of the double word is protected by
-                        * slab_lock but _count is not.
+                        * 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
@@ -97,7 +98,11 @@ struct page {
                                        };
                                        int units;      /* SLOB */
                                };
-                               atomic_t _count;                /* Usage count, see below. */
+                               /*
+                                * Usage count, *USE WRAPPER FUNCTION*
+                                * when manual accounting. See page_ref.h
+                                */
+                               atomic_t _refcount;
                        };
                        unsigned int active;    /* SLAB */
                };
@@ -248,7 +253,7 @@ struct page_frag_cache {
        __u32 offset;
 #endif
        /* we maintain a pagecount bias, so that we dont dirty cache line
-        * containing page->_count every time we allocate a fragment.
+        * containing page->_refcount every time we allocate a fragment.
         */
        unsigned int            pagecnt_bias;
        bool pfmemalloc;
@@ -509,6 +514,7 @@ struct mm_struct {
 #ifdef CONFIG_HUGETLB_PAGE
        atomic_long_t hugetlb_usage;
 #endif
+       struct work_struct async_put_work;
 };
 
 static inline void mm_init_cpumask(struct mm_struct *mm)