87
87
sb->s_op = &v9fs_super_ops;
88
88
sb->s_bdi = &v9ses->bdi;
90
sb->s_bdi->ra_pages = (VM_MAX_READAHEAD * 1024)/PAGE_CACHE_SIZE;
90
sb->s_flags = flags | MS_ACTIVE | MS_SYNCHRONOUS | MS_DIRSYNC |
92
sb->s_flags = flags | MS_ACTIVE | MS_DIRSYNC | MS_NOATIME;
94
sb->s_flags |= MS_SYNCHRONOUS;
93
96
#ifdef CONFIG_9P_FS_POSIX_ACL
94
if ((v9ses->flags & V9FS_ACCESS_MASK) == V9FS_ACCESS_CLIENT)
97
if ((v9ses->flags & V9FS_ACL_MASK) == V9FS_POSIX_ACL)
95
98
sb->s_flags |= MS_POSIXACL;
282
static int v9fs_drop_inode(struct inode *inode)
284
struct v9fs_session_info *v9ses;
285
v9ses = v9fs_inode2v9ses(inode);
287
return generic_drop_inode(inode);
289
* in case of non cached mode always drop the
290
* the inode because we want the inode attribute
291
* to always match that on the server.
296
static int v9fs_write_inode(struct inode *inode,
297
struct writeback_control *wbc)
300
struct p9_wstat wstat;
301
struct v9fs_inode *v9inode;
303
* send an fsync request to server irrespective of
306
P9_DPRINTK(P9_DEBUG_VFS, "%s: inode %p\n", __func__, inode);
307
v9inode = V9FS_I(inode);
308
if (!v9inode->writeback_fid)
310
v9fs_blank_wstat(&wstat);
312
ret = p9_client_wstat(v9inode->writeback_fid, &wstat);
314
__mark_inode_dirty(inode, I_DIRTY_DATASYNC);
320
static int v9fs_write_inode_dotl(struct inode *inode,
321
struct writeback_control *wbc)
324
struct v9fs_inode *v9inode;
326
* send an fsync request to server irrespective of
329
P9_DPRINTK(P9_DEBUG_VFS, "%s: inode %p\n", __func__, inode);
330
v9inode = V9FS_I(inode);
331
if (!v9inode->writeback_fid)
333
ret = p9_client_fsync(v9inode->writeback_fid, 0);
335
__mark_inode_dirty(inode, I_DIRTY_DATASYNC);
279
341
static const struct super_operations v9fs_super_ops = {
280
#ifdef CONFIG_9P_FSCACHE
281
342
.alloc_inode = v9fs_alloc_inode,
282
343
.destroy_inode = v9fs_destroy_inode,
284
344
.statfs = simple_statfs,
285
345
.evict_inode = v9fs_evict_inode,
286
346
.show_options = generic_show_options,
287
347
.umount_begin = v9fs_umount_begin,
348
.write_inode = v9fs_write_inode,
290
351
static const struct super_operations v9fs_super_ops_dotl = {
291
#ifdef CONFIG_9P_FSCACHE
292
352
.alloc_inode = v9fs_alloc_inode,
293
353
.destroy_inode = v9fs_destroy_inode,
295
354
.statfs = v9fs_statfs,
355
.drop_inode = v9fs_drop_inode,
296
356
.evict_inode = v9fs_evict_inode,
297
357
.show_options = generic_show_options,
298
358
.umount_begin = v9fs_umount_begin,
359
.write_inode = v9fs_write_inode_dotl,
301
362
struct file_system_type v9fs_fs_type = {