Commit 39b07265 authored by Anton Altaparmakov's avatar Anton Altaparmakov

NTFS: Add ifdef NTFS_RW arround ntfs_truncate and ntfs_setattr.

parent c10104ad
......@@ -64,8 +64,10 @@ struct file_operations ntfs_file_ops = {
};
struct inode_operations ntfs_file_inode_ops = {
#ifdef NTFS_RW
.truncate = ntfs_truncate,
.setattr = ntfs_setattr,
#endif
};
struct file_operations ntfs_empty_file_ops = {};
......
......@@ -1928,6 +1928,8 @@ int ntfs_show_options(struct seq_file *sf, struct vfsmount *mnt)
return 0;
}
#ifdef NTFS_RW
/**
* ntfs_truncate - called when the i_size of an ntfs inode is changed
* @vi: inode for which the i_size was changed
......@@ -2017,3 +2019,5 @@ int ntfs_setattr(struct dentry *dentry, struct iattr *attr)
return err;
}
#endif
......@@ -245,9 +245,13 @@ extern void ntfs_put_inode(struct inode *vi);
extern int ntfs_show_options(struct seq_file *sf, struct vfsmount *mnt);
#ifdef NTFS_RW
extern void ntfs_truncate(struct inode *vi);
extern int ntfs_setattr(struct dentry *dentry, struct iattr *attr);
#endif
#endif /* _LINUX_NTFS_FS_INODE_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment