diff options
Diffstat (limited to 'mm/shmem.c')
-rw-r--r-- | mm/shmem.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/mm/shmem.c b/mm/shmem.c index 98631c26c200..356dd99566ec 100644 --- a/mm/shmem.c +++ b/mm/shmem.c | |||
@@ -218,7 +218,7 @@ static const struct file_operations shmem_file_operations; | |||
218 | static const struct inode_operations shmem_inode_operations; | 218 | static const struct inode_operations shmem_inode_operations; |
219 | static const struct inode_operations shmem_dir_inode_operations; | 219 | static const struct inode_operations shmem_dir_inode_operations; |
220 | static const struct inode_operations shmem_special_inode_operations; | 220 | static const struct inode_operations shmem_special_inode_operations; |
221 | static struct vm_operations_struct shmem_vm_ops; | 221 | static const struct vm_operations_struct shmem_vm_ops; |
222 | 222 | ||
223 | static struct backing_dev_info shmem_backing_dev_info __read_mostly = { | 223 | static struct backing_dev_info shmem_backing_dev_info __read_mostly = { |
224 | .ra_pages = 0, /* No readahead */ | 224 | .ra_pages = 0, /* No readahead */ |
@@ -1046,8 +1046,9 @@ static int shmem_writepage(struct page *page, struct writeback_control *wbc) | |||
1046 | * sync from ever calling shmem_writepage; but a stacking filesystem | 1046 | * sync from ever calling shmem_writepage; but a stacking filesystem |
1047 | * may use the ->writepage of its underlying filesystem, in which case | 1047 | * may use the ->writepage of its underlying filesystem, in which case |
1048 | * tmpfs should write out to swap only in response to memory pressure, | 1048 | * tmpfs should write out to swap only in response to memory pressure, |
1049 | * and not for pdflush or sync. However, in those cases, we do still | 1049 | * and not for the writeback threads or sync. However, in those cases, |
1050 | * want to check if there's a redundant swappage to be discarded. | 1050 | * we do still want to check if there's a redundant swappage to be |
1051 | * discarded. | ||
1051 | */ | 1052 | */ |
1052 | if (wbc->for_reclaim) | 1053 | if (wbc->for_reclaim) |
1053 | swap = get_swap_page(); | 1054 | swap = get_swap_page(); |
@@ -2497,7 +2498,7 @@ static const struct super_operations shmem_ops = { | |||
2497 | .put_super = shmem_put_super, | 2498 | .put_super = shmem_put_super, |
2498 | }; | 2499 | }; |
2499 | 2500 | ||
2500 | static struct vm_operations_struct shmem_vm_ops = { | 2501 | static const struct vm_operations_struct shmem_vm_ops = { |
2501 | .fault = shmem_fault, | 2502 | .fault = shmem_fault, |
2502 | #ifdef CONFIG_NUMA | 2503 | #ifdef CONFIG_NUMA |
2503 | .set_policy = shmem_set_policy, | 2504 | .set_policy = shmem_set_policy, |