diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-10 14:26:52 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-10 14:26:52 -0400 |
commit | 5f248c9c251c60af3403902b26e08de43964ea0b (patch) | |
tree | 6d3328e72a7e4015a64017eb30be18095c6a3c64 /fs/fuse | |
parent | f6cec0ae58c17522a7bc4e2f39dae19f199ab534 (diff) | |
parent | dca332528bc69e05f67161e1ed59929633d5e63d (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6: (96 commits)
no need for list_for_each_entry_safe()/resetting with superblock list
Fix sget() race with failing mount
vfs: don't hold s_umount over close_bdev_exclusive() call
sysv: do not mark superblock dirty on remount
sysv: do not mark superblock dirty on mount
btrfs: remove junk sb_dirt change
BFS: clean up the superblock usage
AFFS: wait for sb synchronization when needed
AFFS: clean up dirty flag usage
cifs: truncate fallout
mbcache: fix shrinker function return value
mbcache: Remove unused features
add f_flags to struct statfs(64)
pass a struct path to vfs_statfs
update VFS documentation for method changes.
All filesystems that need invalidate_inode_buffers() are doing that explicitly
convert remaining ->clear_inode() to ->evict_inode()
Make ->drop_inode() just return whether inode needs to be dropped
fs/inode.c:clear_inode() is gone
fs/inode.c:evict() doesn't care about delete vs. non-delete paths now
...
Fix up trivial conflicts in fs/nilfs2/super.c
Diffstat (limited to 'fs/fuse')
-rw-r--r-- | fs/fuse/dir.c | 17 | ||||
-rw-r--r-- | fs/fuse/inode.c | 6 |
2 files changed, 11 insertions, 12 deletions
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c index 431be0795b6b..c9627c95482d 100644 --- a/fs/fuse/dir.c +++ b/fs/fuse/dir.c | |||
@@ -1270,21 +1270,18 @@ static int fuse_do_setattr(struct dentry *entry, struct iattr *attr, | |||
1270 | if (!fuse_allow_task(fc, current)) | 1270 | if (!fuse_allow_task(fc, current)) |
1271 | return -EACCES; | 1271 | return -EACCES; |
1272 | 1272 | ||
1273 | if (fc->flags & FUSE_DEFAULT_PERMISSIONS) { | 1273 | if (!(fc->flags & FUSE_DEFAULT_PERMISSIONS)) |
1274 | err = inode_change_ok(inode, attr); | 1274 | attr->ia_valid |= ATTR_FORCE; |
1275 | if (err) | 1275 | |
1276 | return err; | 1276 | err = inode_change_ok(inode, attr); |
1277 | } | 1277 | if (err) |
1278 | return err; | ||
1278 | 1279 | ||
1279 | if ((attr->ia_valid & ATTR_OPEN) && fc->atomic_o_trunc) | 1280 | if ((attr->ia_valid & ATTR_OPEN) && fc->atomic_o_trunc) |
1280 | return 0; | 1281 | return 0; |
1281 | 1282 | ||
1282 | if (attr->ia_valid & ATTR_SIZE) { | 1283 | if (attr->ia_valid & ATTR_SIZE) |
1283 | err = inode_newsize_ok(inode, attr->ia_size); | ||
1284 | if (err) | ||
1285 | return err; | ||
1286 | is_truncate = true; | 1284 | is_truncate = true; |
1287 | } | ||
1288 | 1285 | ||
1289 | req = fuse_get_req(fc); | 1286 | req = fuse_get_req(fc); |
1290 | if (IS_ERR(req)) | 1287 | if (IS_ERR(req)) |
diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index ec14d19ce501..da9e6e11374c 100644 --- a/fs/fuse/inode.c +++ b/fs/fuse/inode.c | |||
@@ -122,8 +122,10 @@ void fuse_send_forget(struct fuse_conn *fc, struct fuse_req *req, | |||
122 | fuse_request_send_noreply(fc, req); | 122 | fuse_request_send_noreply(fc, req); |
123 | } | 123 | } |
124 | 124 | ||
125 | static void fuse_clear_inode(struct inode *inode) | 125 | static void fuse_evict_inode(struct inode *inode) |
126 | { | 126 | { |
127 | truncate_inode_pages(&inode->i_data, 0); | ||
128 | end_writeback(inode); | ||
127 | if (inode->i_sb->s_flags & MS_ACTIVE) { | 129 | if (inode->i_sb->s_flags & MS_ACTIVE) { |
128 | struct fuse_conn *fc = get_fuse_conn(inode); | 130 | struct fuse_conn *fc = get_fuse_conn(inode); |
129 | struct fuse_inode *fi = get_fuse_inode(inode); | 131 | struct fuse_inode *fi = get_fuse_inode(inode); |
@@ -736,7 +738,7 @@ static const struct export_operations fuse_export_operations = { | |||
736 | static const struct super_operations fuse_super_operations = { | 738 | static const struct super_operations fuse_super_operations = { |
737 | .alloc_inode = fuse_alloc_inode, | 739 | .alloc_inode = fuse_alloc_inode, |
738 | .destroy_inode = fuse_destroy_inode, | 740 | .destroy_inode = fuse_destroy_inode, |
739 | .clear_inode = fuse_clear_inode, | 741 | .evict_inode = fuse_evict_inode, |
740 | .drop_inode = generic_delete_inode, | 742 | .drop_inode = generic_delete_inode, |
741 | .remount_fs = fuse_remount_fs, | 743 | .remount_fs = fuse_remount_fs, |
742 | .put_super = fuse_put_super, | 744 | .put_super = fuse_put_super, |