shmem.c (1f370a23f2a3101886953add4bd7f529e3bba016) shmem.c (15ad7cdcfd76450d4beebc789ec646664238184d)
1/*
2 * Resizable virtual memory filesystem for Linux.
3 *
4 * Copyright (C) 2000 Linus Torvalds.
5 * 2000 Transmeta Corp.
6 * 2000-2001 Christoph Rohland
7 * 2000-2001 SAP AG
8 * 2002 Red Hat Inc.

--- 163 unchanged lines hidden (view full) ---

172static inline void shmem_unacct_blocks(unsigned long flags, long pages)
173{
174 if (!(flags & VM_ACCOUNT))
175 vm_unacct_memory(pages * VM_ACCT(PAGE_CACHE_SIZE));
176}
177
178static struct super_operations shmem_ops;
179static const struct address_space_operations shmem_aops;
1/*
2 * Resizable virtual memory filesystem for Linux.
3 *
4 * Copyright (C) 2000 Linus Torvalds.
5 * 2000 Transmeta Corp.
6 * 2000-2001 Christoph Rohland
7 * 2000-2001 SAP AG
8 * 2002 Red Hat Inc.

--- 163 unchanged lines hidden (view full) ---

172static inline void shmem_unacct_blocks(unsigned long flags, long pages)
173{
174 if (!(flags & VM_ACCOUNT))
175 vm_unacct_memory(pages * VM_ACCT(PAGE_CACHE_SIZE));
176}
177
178static struct super_operations shmem_ops;
179static const struct address_space_operations shmem_aops;
180static struct file_operations shmem_file_operations;
180static const struct file_operations shmem_file_operations;
181static struct inode_operations shmem_inode_operations;
182static struct inode_operations shmem_dir_inode_operations;
183static struct inode_operations shmem_special_inode_operations;
184static struct vm_operations_struct shmem_vm_ops;
185
186static struct backing_dev_info shmem_backing_dev_info __read_mostly = {
187 .ra_pages = 0, /* No readahead */
188 .capabilities = BDI_CAP_NO_ACCT_DIRTY | BDI_CAP_NO_WRITEBACK,

--- 2125 unchanged lines hidden (view full) ---

2314 .set_page_dirty = __set_page_dirty_nobuffers,
2315#ifdef CONFIG_TMPFS
2316 .prepare_write = shmem_prepare_write,
2317 .commit_write = simple_commit_write,
2318#endif
2319 .migratepage = migrate_page,
2320};
2321
181static struct inode_operations shmem_inode_operations;
182static struct inode_operations shmem_dir_inode_operations;
183static struct inode_operations shmem_special_inode_operations;
184static struct vm_operations_struct shmem_vm_ops;
185
186static struct backing_dev_info shmem_backing_dev_info __read_mostly = {
187 .ra_pages = 0, /* No readahead */
188 .capabilities = BDI_CAP_NO_ACCT_DIRTY | BDI_CAP_NO_WRITEBACK,

--- 2125 unchanged lines hidden (view full) ---

2314 .set_page_dirty = __set_page_dirty_nobuffers,
2315#ifdef CONFIG_TMPFS
2316 .prepare_write = shmem_prepare_write,
2317 .commit_write = simple_commit_write,
2318#endif
2319 .migratepage = migrate_page,
2320};
2321
2322static struct file_operations shmem_file_operations = {
2322static const struct file_operations shmem_file_operations = {
2323 .mmap = shmem_mmap,
2324#ifdef CONFIG_TMPFS
2325 .llseek = generic_file_llseek,
2326 .read = shmem_file_read,
2327 .write = shmem_file_write,
2328 .fsync = simple_sync_file,
2329 .sendfile = shmem_file_sendfile,
2330#endif

--- 201 unchanged lines hidden ---
2323 .mmap = shmem_mmap,
2324#ifdef CONFIG_TMPFS
2325 .llseek = generic_file_llseek,
2326 .read = shmem_file_read,
2327 .write = shmem_file_write,
2328 .fsync = simple_sync_file,
2329 .sendfile = shmem_file_sendfile,
2330#endif

--- 201 unchanged lines hidden ---