Whamcloud - gitweb
- check that fs is version-capable and avoid VBR if not
authortappro <tappro>
Wed, 26 Nov 2008 08:05:10 +0000 (08:05 +0000)
committertappro <tappro>
Wed, 26 Nov 2008 08:05:10 +0000 (08:05 +0000)
  b:17717
  i:adilger,alex

lustre/obdclass/target.c

index e3b3df6..c723a99 100644 (file)
@@ -175,3 +175,12 @@ void target_trans_table_update(struct obd_export *exp, __u64 transno)
         spin_unlock(&obt->obt_trans_table_lock);
 }
 EXPORT_SYMBOL(target_trans_table_update);
+
+int target_fs_version_capable(struct obd_device *obd)
+{
+        struct inode * inode = obd->u.obt.obt_rcvd_filp->f_dentry->d_inode;
+        /** check inode has version */
+        return (fsfilt_get_version(obd, inode) != -EOPNOTSUPP);
+}
+EXPORT_SYMBOL(target_fs_version_capable);
+