Whamcloud - gitweb
- this is a small refactoring of the inode refresh path to aid me with
authorbraam <braam>
Mon, 15 Sep 2003 02:10:37 +0000 (02:10 +0000)
committerbraam <braam>
Mon, 15 Sep 2003 02:10:37 +0000 (02:10 +0000)
  lstripe (which is mostly included in this, unfortunately).

lustre/llite/llite_lib.c

index 667d8c2..bea9c2d 100644 (file)
@@ -657,6 +657,8 @@ void ll_update_inode(struct inode *inode, struct mds_body *body,
                                 LBUG();
                         }
                 }
+                if (lli->lli_smd != lsm)
+                        obd_free_memmd(ll_i2obdexp(inode), &lsm);
         }
 
         if (body->valid & OBD_MD_FLID)
@@ -692,6 +694,9 @@ void ll_update_inode(struct inode *inode, struct mds_body *body,
                 inode->i_size = body->size;
         if (body->valid & OBD_MD_FLBLOCKS)
                 inode->i_blocks = body->blocks;
+
+        if (body->valid & OBD_MD_FLSIZE)
+                set_bit(LLI_F_HAVE_MDS_SIZE_LOCK, &lli->lli_flags);
 }
 
 void ll_read_inode2(struct inode *inode, void *opaque)