diff options
Diffstat (limited to 'include/linux/swap.h')
-rw-r--r-- | include/linux/swap.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/include/linux/swap.h b/include/linux/swap.h index 4d559325d919..a5c6da5d8df8 100644 --- a/include/linux/swap.h +++ b/include/linux/swap.h | |||
@@ -155,6 +155,15 @@ enum { | |||
155 | #define SWAP_CLUSTER_MAX 32 | 155 | #define SWAP_CLUSTER_MAX 32 |
156 | #define COMPACT_CLUSTER_MAX SWAP_CLUSTER_MAX | 156 | #define COMPACT_CLUSTER_MAX SWAP_CLUSTER_MAX |
157 | 157 | ||
158 | /* | ||
159 | * Ratio between the present memory in the zone and the "gap" that | ||
160 | * we're allowing kswapd to shrink in addition to the per-zone high | ||
161 | * wmark, even for zones that already have the high wmark satisfied, | ||
162 | * in order to provide better per-zone lru behavior. We are ok to | ||
163 | * spend not more than 1% of the memory for this zone balancing "gap". | ||
164 | */ | ||
165 | #define KSWAPD_ZONE_BALANCE_GAP_RATIO 100 | ||
166 | |||
158 | #define SWAP_MAP_MAX 0x3e /* Max duplication count, in first swap_map */ | 167 | #define SWAP_MAP_MAX 0x3e /* Max duplication count, in first swap_map */ |
159 | #define SWAP_MAP_BAD 0x3f /* Note pageblock is bad, in first swap_map */ | 168 | #define SWAP_MAP_BAD 0x3f /* Note pageblock is bad, in first swap_map */ |
160 | #define SWAP_HAS_CACHE 0x40 /* Flag page is cached, in first swap_map */ | 169 | #define SWAP_HAS_CACHE 0x40 /* Flag page is cached, in first swap_map */ |
@@ -215,6 +224,7 @@ extern void mark_page_accessed(struct page *); | |||
215 | extern void lru_add_drain(void); | 224 | extern void lru_add_drain(void); |
216 | extern int lru_add_drain_all(void); | 225 | extern int lru_add_drain_all(void); |
217 | extern void rotate_reclaimable_page(struct page *page); | 226 | extern void rotate_reclaimable_page(struct page *page); |
227 | extern void deactivate_page(struct page *page); | ||
218 | extern void swap_setup(void); | 228 | extern void swap_setup(void); |
219 | 229 | ||
220 | extern void add_page_to_unevictable_list(struct page *page); | 230 | extern void add_page_to_unevictable_list(struct page *page); |
@@ -299,8 +309,6 @@ extern void mem_cgroup_get_shmem_target(struct inode *inode, pgoff_t pgoff, | |||
299 | struct page **pagep, swp_entry_t *ent); | 309 | struct page **pagep, swp_entry_t *ent); |
300 | #endif | 310 | #endif |
301 | 311 | ||
302 | extern void swap_unplug_io_fn(struct backing_dev_info *, struct page *); | ||
303 | |||
304 | #ifdef CONFIG_SWAP | 312 | #ifdef CONFIG_SWAP |
305 | /* linux/mm/page_io.c */ | 313 | /* linux/mm/page_io.c */ |
306 | extern int swap_readpage(struct page *); | 314 | extern int swap_readpage(struct page *); |