diff options
Diffstat (limited to 'fs/omfs/file.c')
-rw-r--r-- | fs/omfs/file.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/fs/omfs/file.c b/fs/omfs/file.c index 810cff346468..78c9f0c1a2f3 100644 --- a/fs/omfs/file.c +++ b/fs/omfs/file.c | |||
@@ -341,7 +341,19 @@ const struct file_operations omfs_file_operations = { | |||
341 | .splice_read = generic_file_splice_read, | 341 | .splice_read = generic_file_splice_read, |
342 | }; | 342 | }; |
343 | 343 | ||
344 | static int omfs_setattr(struct dentry *dentry, struct iattr *attr) | ||
345 | { | ||
346 | struct inode *inode = dentry->d_inode; | ||
347 | int error; | ||
348 | |||
349 | error = inode_change_ok(inode, attr); | ||
350 | if (error) | ||
351 | return error; | ||
352 | return inode_setattr(inode, attr); | ||
353 | } | ||
354 | |||
344 | const struct inode_operations omfs_file_inops = { | 355 | const struct inode_operations omfs_file_inops = { |
356 | .setattr = omfs_setattr, | ||
345 | .truncate = omfs_truncate | 357 | .truncate = omfs_truncate |
346 | }; | 358 | }; |
347 | 359 | ||