summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/file.c
diff options
context:
space:
mode:
authorSven Wegener <sven.wegener@stealer.net>2008-07-30 16:54:26 -0400
committerChris Mason <chris.mason@oracle.com>2008-09-25 11:04:05 -0400
commit0ee0fda06b943d7ef65f3cec50ab9d427a2baf97 (patch)
tree342ac5337dc72cf18b683f7f79b497db98a6062e /fs/btrfs/file.c
parentbcc63abbf3e9bf948a1b0129b3e6120ec7d7f698 (diff)
downloadop-kernel-dev-0ee0fda06b943d7ef65f3cec50ab9d427a2baf97.zip
op-kernel-dev-0ee0fda06b943d7ef65f3cec50ab9d427a2baf97.tar.gz
Btrfs: Add compatibility for kernels >= 2.6.27-rc1
Add a couple of #if's to follow API changes. Signed-off-by: Sven Wegener <sven.wegener@stealer.net> Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/file.c')
-rw-r--r--fs/btrfs/file.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c
index 412ab4a..388ac39 100644
--- a/fs/btrfs/file.c
+++ b/fs/btrfs/file.c
@@ -886,7 +886,11 @@ static ssize_t btrfs_file_write(struct file *file, const char __user *buf,
#ifdef REMOVE_SUID_PATH
err = remove_suid(&file->f_path);
#else
+# if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,26)
+ err = file_remove_suid(file);
+# else
err = remove_suid(fdentry(file));
+# endif
#endif
if (err)
goto out_nolock;
OpenPOWER on IntegriCloud