Whamcloud - gitweb
b=24037 Changes of 2.6.32 kernel.
[fs/lustre-release.git] / lustre / mds / handler.c
index 7fd6ec0..9b015ca 100644 (file)
@@ -46,7 +46,6 @@
 #include <lustre_mds.h>
 #include <linux/module.h>
 #include <linux/init.h>
-#include <linux/random.h>
 #include <linux/fs.h>
 #include <linux/jbd.h>
 #include <linux/smp_lock.h>
@@ -318,7 +317,7 @@ static void mds_init_ctxt(struct obd_device *obd, struct vfsmount *mnt)
         mds->mds_obt.obt_vfsmnt = mnt;
         /* why not mnt->mnt_sb instead of mnt->mnt_root->d_inode->i_sb? */
         obd->u.obt.obt_sb = mnt->mnt_root->d_inode->i_sb;
-
+        obd->u.obt.obt_magic = OBT_MAGIC;
         fsfilt_setup(obd, obd->u.obt.obt_sb);
 
         OBD_SET_CTXT_MAGIC(&obd->obd_lvfs_ctxt);
@@ -368,7 +367,7 @@ static int mds_cmd_setup(struct obd_device *obd, struct lustre_cfg *lcfg)
         mds_init_ctxt(obd, mnt);
 
         push_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
-        dentry = simple_mkdir(current->fs->pwd, mnt, "OBJECTS", 0777, 1);
+        dentry = simple_mkdir(cfs_fs_pwd(current->fs), mnt, "OBJECTS", 0777, 1);
         if (IS_ERR(dentry)) {
                 rc = PTR_ERR(dentry);
                 CERROR("cannot create OBJECTS directory: rc = %d\n", rc);
@@ -376,7 +375,7 @@ static int mds_cmd_setup(struct obd_device *obd, struct lustre_cfg *lcfg)
         }
         mds->mds_objects_dir = dentry;
 
-        dentry = lookup_one_len("__iopen__", current->fs->pwd,
+        dentry = ll_lookup_one_len("__iopen__", cfs_fs_pwd(current->fs),
                                 strlen("__iopen__"));
         if (IS_ERR(dentry)) {
                 rc = PTR_ERR(dentry);
@@ -449,7 +448,7 @@ static int mds_cmd_cleanup(struct obd_device *obd)
         }
 
         dput(mds->mds_fid_de);
-        LL_DQUOT_OFF(obd->u.obt.obt_sb);
+        ll_vfs_dq_off(obd->u.obt.obt_sb, 0);
         shrink_dcache_sb(mds->mds_obt.obt_sb);
         fsfilt_put_ops(obd->obd_fsops);