diff options
author | Joel Becker <joel.becker@oracle.com> | 2010-03-26 10:09:15 +0800 |
---|---|---|
committer | Tao Ma <tao.ma@oracle.com> | 2010-03-26 10:09:15 +0800 |
commit | 2b6cb576aa80611f1f6a3c88708d1e68a8d97985 (patch) | |
tree | a984f09104970133379e4d370b9f01e7f85c6f9b /fs/ocfs2/namei.c | |
parent | ba2066351b630f0205ebf725f5c81a2a07a77cd7 (diff) | |
download | blackbird-op-linux-2b6cb576aa80611f1f6a3c88708d1e68a8d97985.tar.gz blackbird-op-linux-2b6cb576aa80611f1f6a3c88708d1e68a8d97985.zip |
ocfs2: Set suballoc_loc on allocated metadata.
Get the suballoc_loc from ocfs2_claim_new_inode() or
ocfs2_claim_metadata(). Store it on the appropriate field of the block
we just allocated.
Signed-off-by: Joel Becker <joel.becker@oracle.com>
Diffstat (limited to 'fs/ocfs2/namei.c')
-rw-r--r-- | fs/ocfs2/namei.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/ocfs2/namei.c b/fs/ocfs2/namei.c index e5434a04b88a..bfe4571a4fa1 100644 --- a/fs/ocfs2/namei.c +++ b/fs/ocfs2/namei.c @@ -472,14 +472,15 @@ static int ocfs2_mknod_locked(struct ocfs2_super *osb, int status = 0; struct ocfs2_dinode *fe = NULL; struct ocfs2_extent_list *fel; - u64 fe_blkno = 0; + u64 suballoc_loc, fe_blkno = 0; u16 suballoc_bit; u16 feat; *new_fe_bh = NULL; status = ocfs2_claim_new_inode(handle, dir, parent_fe_bh, - inode_ac, &suballoc_bit, &fe_blkno); + inode_ac, &suballoc_loc, + &suballoc_bit, &fe_blkno); if (status < 0) { mlog_errno(status); goto leave; @@ -516,6 +517,7 @@ static int ocfs2_mknod_locked(struct ocfs2_super *osb, fe->i_generation = cpu_to_le32(inode->i_generation); fe->i_fs_generation = cpu_to_le32(osb->fs_generation); fe->i_blkno = cpu_to_le64(fe_blkno); + fe->i_suballoc_loc = cpu_to_le64(suballoc_loc); fe->i_suballoc_bit = cpu_to_le16(suballoc_bit); fe->i_suballoc_slot = cpu_to_le16(inode_ac->ac_alloc_slot); fe->i_uid = cpu_to_le32(inode->i_uid); |