cma: fix watermark checking
[deliverable/linux.git] / mm / internal.h
index 3314f79d775a5f90c84e3250d8b93b7bd6f99933..96cda4c6ac56762f69a919f7fe9332666be98930 100644 (file)
@@ -130,6 +130,8 @@ struct compact_control {
        int order;                      /* order a direct compactor needs */
        int migratetype;                /* MOVABLE, RECLAIMABLE etc */
        struct zone *zone;
+       bool *contended;                /* True if a lock was contended */
+       struct page **page;             /* Page captured of requested size */
 };
 
 unsigned long
@@ -339,7 +341,6 @@ static inline void mminit_validate_memmodel_limits(unsigned long *start_pfn,
 #define ZONE_RECLAIM_FULL      -1
 #define ZONE_RECLAIM_SOME      0
 #define ZONE_RECLAIM_SUCCESS   1
-#endif
 
 extern int hwpoison_filter(struct page *p);
 
@@ -355,3 +356,20 @@ extern unsigned long vm_mmap_pgoff(struct file *, unsigned long,
         unsigned long, unsigned long);
 
 extern void set_pageblock_order(void);
+unsigned long reclaim_clean_pages_from_list(struct zone *zone,
+                                           struct list_head *page_list);
+/* The ALLOC_WMARK bits are used as an index to zone->watermark */
+#define ALLOC_WMARK_MIN                WMARK_MIN
+#define ALLOC_WMARK_LOW                WMARK_LOW
+#define ALLOC_WMARK_HIGH       WMARK_HIGH
+#define ALLOC_NO_WATERMARKS    0x04 /* don't check watermarks at all */
+
+/* Mask to get the watermark bits */
+#define ALLOC_WMARK_MASK       (ALLOC_NO_WATERMARKS-1)
+
+#define ALLOC_HARDER           0x10 /* try to alloc harder */
+#define ALLOC_HIGH             0x20 /* __GFP_HIGH set */
+#define ALLOC_CPUSET           0x40 /* check for correct cpuset */
+#define ALLOC_CMA              0x80 /* allow allocations from CMA areas */
+
+#endif /* __MM_INTERNAL_H */
This page took 0.037396 seconds and 5 git commands to generate.