mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-26 19:00:25 +00:00
xfs: don't clear the "dinode core" in xfs_inode_alloc
The xfs_icdinode structure just contains a random mix of inode field, which are all read from the on-disk inode and mostly not looked at before reading the inode or initializing a new inode cluster. The only exceptions are the forkoff and blocks field, which are used in sanity checks for freshly allocated inodes. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Darrick J. Wong <djwong@kernel.org> Signed-off-by: Darrick J. Wong <djwong@kernel.org>
This commit is contained in:
parent
9b3beb028f
commit
7e2a8af528
1 changed files with 2 additions and 1 deletions
|
@ -63,8 +63,9 @@ xfs_inode_alloc(
|
|||
memset(&ip->i_df, 0, sizeof(ip->i_df));
|
||||
ip->i_flags = 0;
|
||||
ip->i_delayed_blks = 0;
|
||||
memset(&ip->i_d, 0, sizeof(ip->i_d));
|
||||
ip->i_d.di_flags2 = mp->m_ino_geo.new_diflags2;
|
||||
ip->i_d.di_nblocks = 0;
|
||||
ip->i_d.di_forkoff = 0;
|
||||
ip->i_sick = 0;
|
||||
ip->i_checked = 0;
|
||||
INIT_WORK(&ip->i_ioend_work, xfs_end_io);
|
||||
|
|
Loading…
Reference in a new issue