Whamcloud - gitweb
Branch HEAD
[fs/lustre-release.git] / lustre / llite / llite_fid.c
index 85ad4f3..4630575 100644 (file)
@@ -43,10 +43,19 @@ ino_t ll_fid_build_ino(struct ll_sb_info *sbi,
         ino_t ino;
         ENTRY;
 
         ino_t ino;
         ENTRY;
 
+        if (fid_is_igif(fid)) {
+                ino = lu_igif_ino(fid);
+                RETURN(ino);
+        }
+
         /*
          * Very stupid and having many downsides inode allocation algorithm
          * based on fid.
          */
         ino = fid_flatten(fid);
         /*
          * Very stupid and having many downsides inode allocation algorithm
          * based on fid.
          */
         ino = fid_flatten(fid);
-        RETURN(ino & 0x7fffffff);
+
+        if (unlikely(ino == 0))
+                /* the first result ino is 0xFFC001, so this is rarely used */
+                ino = 0xffbcde; 
+        RETURN(ino);
 }
 }