Merge remote-tracking branch 'ovl/rename2' into for-linus
[cascardo/linux.git] / fs / jfs / namei.c
index 10449c1..d1d7c43 100644 (file)
@@ -1078,7 +1078,8 @@ static int jfs_symlink(struct inode *dip, struct dentry *dentry,
  * FUNCTION:   rename a file or directory
  */
 static int jfs_rename(struct inode *old_dir, struct dentry *old_dentry,
-              struct inode *new_dir, struct dentry *new_dentry)
+                     struct inode *new_dir, struct dentry *new_dentry,
+                     unsigned int flags)
 {
        struct btstack btstack;
        ino_t ino;
@@ -1097,6 +1098,8 @@ static int jfs_rename(struct inode *old_dir, struct dentry *old_dentry,
        s64 new_size = 0;
        int commit_flag;
 
+       if (flags & ~RENAME_NOREPLACE)
+               return -EINVAL;
 
        jfs_info("jfs_rename: %pd %pd", old_dentry, new_dentry);