]> git.karo-electronics.de Git - karo-tx-linux.git/commit
GFS2: Use gfs2_dinode_out() in the inode create path
authorSteven Whitehouse <swhiteho@redhat.com>
Fri, 1 Mar 2013 09:29:12 +0000 (09:29 +0000)
committerSteven Whitehouse <swhiteho@redhat.com>
Mon, 4 Mar 2013 09:30:47 +0000 (09:30 +0000)
commit5978cbb3f36dbaf5a124b0c5d9c74dda41a5fe3e
treef34b06837099836dce157a5fb827111c3f45b9ce
parent55e8c61661329498d15ed2af99ec349f661a6adc
GFS2: Use gfs2_dinode_out() in the inode create path

Over the previous two patches relating to inode creation, the
content of init_dinode() has been looking more and more like
gfs2_dinode_out(). This is not an accident! This patch replaces
the parts of init_dinode() which are duplicated in gfs2_dinode_out()
with a call to that function.

Mostly that is straightforward, but there is one issue which needed
to be resolved relating to the link count. The link count has to be
set to zero in a certain error handling code path, which lands up
calling iput(). This is now done specifically in that code path
allowing the link count to be set earlier and written into the
on disk inode by gfs2_dinode_put() in the normal way.

Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/inode.c