aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-08-11 14:44:11 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-08-11 14:44:11 -0400
commitf6f993328b2abcab86a3c99d7bd9f2066ab03d36 (patch)
treeea6f3902a0fa546493731b3b52a31d98cc747a90 /include/linux
parentc7a19c795b4b0a3232c157ed29eea85077e95da6 (diff)
parent12a5b5294cb1896e9a3c9fca8ff5a7e3def4e8c6 (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull vfs updates from Al Viro: "Stuff in here: - acct.c fixes and general rework of mnt_pin mechanism. That allows to go for delayed-mntput stuff, which will permit mntput() on deep stack without worrying about stack overflows - fs shutdown will happen on shallow stack. IOW, we can do Eric's umount-on-rmdir series without introducing tons of stack overflows on new mntput() call chains it introduces. - Bruce's d_splice_alias() patches - more Miklos' rename() stuff. - a couple of regression fixes (stable fodder, in the end of branch) and a fix for API idiocy in iov_iter.c. There definitely will be another pile, maybe even two. I'd like to get Eric's series in this time, but even if we miss it, it'll go right in the beginning of for-next in the next cycle - the tricky part of prereqs is in this pile" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (40 commits) fix copy_tree() regression __generic_file_write_iter(): fix handling of sync error after DIO switch iov_iter_get_pages() to passing maximal number of pages fs: mark __d_obtain_alias static dcache: d_splice_alias should detect loops exportfs: update Exporting documentation dcache: d_find_alias needn't recheck IS_ROOT && DCACHE_DISCONNECTED dcache: remove unused d_find_alias parameter dcache: d_obtain_alias callers don't all want DISCONNECTED dcache: d_splice_alias should ignore DCACHE_DISCONNECTED dcache: d_splice_alias mustn't create directory aliases dcache: close d_move race in d_splice_alias dcache: move d_splice_alias namei: trivial fix to vfs_rename_dir comment VFS: allow ->d_manage() to declare -EISDIR in rcu_walk mode. cifs: support RENAME_NOREPLACE hostfs: support rename flags shmem: support RENAME_EXCHANGE shmem: support RENAME_NOREPLACE btrfs: add RENAME_NOREPLACE ...
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/acct.h4
-rw-r--r--include/linux/dcache.h1
-rw-r--r--include/linux/fs.h2
-rw-r--r--include/linux/fs_pin.h17
-rw-r--r--include/linux/mount.h4
-rw-r--r--include/linux/uio.h2
6 files changed, 23 insertions, 7 deletions
diff --git a/include/linux/acct.h b/include/linux/acct.h
index 4a5b7cb56079..dccc2d4fe7de 100644
--- a/include/linux/acct.h
+++ b/include/linux/acct.h
@@ -24,14 +24,10 @@ struct super_block;
24struct pacct_struct; 24struct pacct_struct;
25struct pid_namespace; 25struct pid_namespace;
26extern int acct_parm[]; /* for sysctl */ 26extern int acct_parm[]; /* for sysctl */
27extern void acct_auto_close_mnt(struct vfsmount *m);
28extern void acct_auto_close(struct super_block *sb);
29extern void acct_collect(long exitcode, int group_dead); 27extern void acct_collect(long exitcode, int group_dead);
30extern void acct_process(void); 28extern void acct_process(void);
31extern void acct_exit_ns(struct pid_namespace *); 29extern void acct_exit_ns(struct pid_namespace *);
32#else 30#else
33#define acct_auto_close_mnt(x) do { } while (0)
34#define acct_auto_close(x) do { } while (0)
35#define acct_collect(x,y) do { } while (0) 31#define acct_collect(x,y) do { } while (0)
36#define acct_process() do { } while (0) 32#define acct_process() do { } while (0)
37#define acct_exit_ns(ns) do { } while (0) 33#define acct_exit_ns(ns) do { } while (0)
diff --git a/include/linux/dcache.h b/include/linux/dcache.h
index 3c7ec327ebd2..e4ae2ad48d07 100644
--- a/include/linux/dcache.h
+++ b/include/linux/dcache.h
@@ -249,6 +249,7 @@ extern struct dentry * d_splice_alias(struct inode *, struct dentry *);
249extern struct dentry * d_add_ci(struct dentry *, struct inode *, struct qstr *); 249extern struct dentry * d_add_ci(struct dentry *, struct inode *, struct qstr *);
250extern struct dentry *d_find_any_alias(struct inode *inode); 250extern struct dentry *d_find_any_alias(struct inode *inode);
251extern struct dentry * d_obtain_alias(struct inode *); 251extern struct dentry * d_obtain_alias(struct inode *);
252extern struct dentry * d_obtain_root(struct inode *);
252extern void shrink_dcache_sb(struct super_block *); 253extern void shrink_dcache_sb(struct super_block *);
253extern void shrink_dcache_parent(struct dentry *); 254extern void shrink_dcache_parent(struct dentry *);
254extern void shrink_dcache_for_umount(struct super_block *); 255extern void shrink_dcache_for_umount(struct super_block *);
diff --git a/include/linux/fs.h b/include/linux/fs.h
index f0890e4a7c25..94187721ad41 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -1275,6 +1275,7 @@ struct super_block {
1275 1275
1276 /* AIO completions deferred from interrupt context */ 1276 /* AIO completions deferred from interrupt context */
1277 struct workqueue_struct *s_dio_done_wq; 1277 struct workqueue_struct *s_dio_done_wq;
1278 struct hlist_head s_pins;
1278 1279
1279 /* 1280 /*
1280 * Keep the lru lists last in the structure so they always sit on their 1281 * Keep the lru lists last in the structure so they always sit on their
@@ -2360,6 +2361,7 @@ extern int do_pipe_flags(int *, int);
2360 2361
2361extern int kernel_read(struct file *, loff_t, char *, unsigned long); 2362extern int kernel_read(struct file *, loff_t, char *, unsigned long);
2362extern ssize_t kernel_write(struct file *, const char *, size_t, loff_t); 2363extern ssize_t kernel_write(struct file *, const char *, size_t, loff_t);
2364extern ssize_t __kernel_write(struct file *, const char *, size_t, loff_t *);
2363extern struct file * open_exec(const char *); 2365extern struct file * open_exec(const char *);
2364 2366
2365/* fs/dcache.c -- generic fs support functions */ 2367/* fs/dcache.c -- generic fs support functions */
diff --git a/include/linux/fs_pin.h b/include/linux/fs_pin.h
new file mode 100644
index 000000000000..f66525e72ccf
--- /dev/null
+++ b/include/linux/fs_pin.h
@@ -0,0 +1,17 @@
1#include <linux/fs.h>
2
3struct fs_pin {
4 atomic_long_t count;
5 union {
6 struct {
7 struct hlist_node s_list;
8 struct hlist_node m_list;
9 };
10 struct rcu_head rcu;
11 };
12 void (*kill)(struct fs_pin *);
13};
14
15void pin_put(struct fs_pin *);
16void pin_remove(struct fs_pin *);
17void pin_insert(struct fs_pin *, struct vfsmount *);
diff --git a/include/linux/mount.h b/include/linux/mount.h
index b0c1e6574e7f..9262e4bf0cc3 100644
--- a/include/linux/mount.h
+++ b/include/linux/mount.h
@@ -69,6 +69,7 @@ struct vfsmount {
69}; 69};
70 70
71struct file; /* forward dec */ 71struct file; /* forward dec */
72struct path;
72 73
73extern int mnt_want_write(struct vfsmount *mnt); 74extern int mnt_want_write(struct vfsmount *mnt);
74extern int mnt_want_write_file(struct file *file); 75extern int mnt_want_write_file(struct file *file);
@@ -77,8 +78,7 @@ extern void mnt_drop_write(struct vfsmount *mnt);
77extern void mnt_drop_write_file(struct file *file); 78extern void mnt_drop_write_file(struct file *file);
78extern void mntput(struct vfsmount *mnt); 79extern void mntput(struct vfsmount *mnt);
79extern struct vfsmount *mntget(struct vfsmount *mnt); 80extern struct vfsmount *mntget(struct vfsmount *mnt);
80extern void mnt_pin(struct vfsmount *mnt); 81extern struct vfsmount *mnt_clone_internal(struct path *path);
81extern void mnt_unpin(struct vfsmount *mnt);
82extern int __mnt_is_readonly(struct vfsmount *mnt); 82extern int __mnt_is_readonly(struct vfsmount *mnt);
83 83
84struct file_system_type; 84struct file_system_type;
diff --git a/include/linux/uio.h b/include/linux/uio.h
index 09a7cffc224e..48d64e6ab292 100644
--- a/include/linux/uio.h
+++ b/include/linux/uio.h
@@ -84,7 +84,7 @@ unsigned long iov_iter_alignment(const struct iov_iter *i);
84void iov_iter_init(struct iov_iter *i, int direction, const struct iovec *iov, 84void iov_iter_init(struct iov_iter *i, int direction, const struct iovec *iov,
85 unsigned long nr_segs, size_t count); 85 unsigned long nr_segs, size_t count);
86ssize_t iov_iter_get_pages(struct iov_iter *i, struct page **pages, 86ssize_t iov_iter_get_pages(struct iov_iter *i, struct page **pages,
87 size_t maxsize, size_t *start); 87 unsigned maxpages, size_t *start);
88ssize_t iov_iter_get_pages_alloc(struct iov_iter *i, struct page ***pages, 88ssize_t iov_iter_get_pages_alloc(struct iov_iter *i, struct page ***pages,
89 size_t maxsize, size_t *start); 89 size_t maxsize, size_t *start);
90int iov_iter_npages(const struct iov_iter *i, int maxpages); 90int iov_iter_npages(const struct iov_iter *i, int maxpages);