Whamcloud - gitweb
LU-3866 hsm: permission checks on HSM operations
[fs/lustre-release.git] / lustre / lod / lod_dev.c
index 5a0bdb5..2315222 100644 (file)
@@ -38,9 +38,6 @@
  * Author: Mikhail Pershin <mike.pershin@intel.com>
  */
 
-#ifndef EXPORT_SYMTAB
-# define EXPORT_SYMTAB
-#endif
 #define DEBUG_SUBSYSTEM S_MDS
 
 #include <obd_class.h>
@@ -179,7 +176,7 @@ static int lod_cleanup_desc_tgts(const struct lu_env *env,
        return rc;
 }
 
-static int lodname2mdt_index(char *lodname, int *index)
+static int lodname2mdt_index(char *lodname, long *index)
 {
        char *ptr, *tmp;
 
@@ -363,10 +360,13 @@ static int lod_process_config(const struct lu_env *env,
                        if (mdt == NULL) {
                                mdt_index = 0;
                        } else {
+                               long long_index;
                                rc = lodname2mdt_index(
-                                       lustre_cfg_string(lcfg, 0), &mdt_index);
+                                       lustre_cfg_string(lcfg, 0),
+                                       &long_index);
                                if (rc != 0)
                                        GOTO(out, rc);
+                               mdt_index = long_index;
                        }
                        rc = lod_add_device(env, lod, arg1, index, gen,
                                            mdt_index, LUSTRE_OSC_NAME, 1);