diff options
Diffstat (limited to 'fs/xfs/xfs_inode.c')
-rw-r--r-- | fs/xfs/xfs_inode.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/fs/xfs/xfs_inode.c b/fs/xfs/xfs_inode.c index efbe1accb6ca..7f7be5f98f52 100644 --- a/fs/xfs/xfs_inode.c +++ b/fs/xfs/xfs_inode.c | |||
@@ -1638,6 +1638,10 @@ xfs_iunlink( | |||
1638 | dip->di_next_unlinked = agi->agi_unlinked[bucket_index]; | 1638 | dip->di_next_unlinked = agi->agi_unlinked[bucket_index]; |
1639 | offset = ip->i_imap.im_boffset + | 1639 | offset = ip->i_imap.im_boffset + |
1640 | offsetof(xfs_dinode_t, di_next_unlinked); | 1640 | offsetof(xfs_dinode_t, di_next_unlinked); |
1641 | |||
1642 | /* need to recalc the inode CRC if appropriate */ | ||
1643 | xfs_dinode_calc_crc(mp, dip); | ||
1644 | |||
1641 | xfs_trans_inode_buf(tp, ibp); | 1645 | xfs_trans_inode_buf(tp, ibp); |
1642 | xfs_trans_log_buf(tp, ibp, offset, | 1646 | xfs_trans_log_buf(tp, ibp, offset, |
1643 | (offset + sizeof(xfs_agino_t) - 1)); | 1647 | (offset + sizeof(xfs_agino_t) - 1)); |
@@ -1723,6 +1727,10 @@ xfs_iunlink_remove( | |||
1723 | dip->di_next_unlinked = cpu_to_be32(NULLAGINO); | 1727 | dip->di_next_unlinked = cpu_to_be32(NULLAGINO); |
1724 | offset = ip->i_imap.im_boffset + | 1728 | offset = ip->i_imap.im_boffset + |
1725 | offsetof(xfs_dinode_t, di_next_unlinked); | 1729 | offsetof(xfs_dinode_t, di_next_unlinked); |
1730 | |||
1731 | /* need to recalc the inode CRC if appropriate */ | ||
1732 | xfs_dinode_calc_crc(mp, dip); | ||
1733 | |||
1726 | xfs_trans_inode_buf(tp, ibp); | 1734 | xfs_trans_inode_buf(tp, ibp); |
1727 | xfs_trans_log_buf(tp, ibp, offset, | 1735 | xfs_trans_log_buf(tp, ibp, offset, |
1728 | (offset + sizeof(xfs_agino_t) - 1)); | 1736 | (offset + sizeof(xfs_agino_t) - 1)); |
@@ -1796,6 +1804,10 @@ xfs_iunlink_remove( | |||
1796 | dip->di_next_unlinked = cpu_to_be32(NULLAGINO); | 1804 | dip->di_next_unlinked = cpu_to_be32(NULLAGINO); |
1797 | offset = ip->i_imap.im_boffset + | 1805 | offset = ip->i_imap.im_boffset + |
1798 | offsetof(xfs_dinode_t, di_next_unlinked); | 1806 | offsetof(xfs_dinode_t, di_next_unlinked); |
1807 | |||
1808 | /* need to recalc the inode CRC if appropriate */ | ||
1809 | xfs_dinode_calc_crc(mp, dip); | ||
1810 | |||
1799 | xfs_trans_inode_buf(tp, ibp); | 1811 | xfs_trans_inode_buf(tp, ibp); |
1800 | xfs_trans_log_buf(tp, ibp, offset, | 1812 | xfs_trans_log_buf(tp, ibp, offset, |
1801 | (offset + sizeof(xfs_agino_t) - 1)); | 1813 | (offset + sizeof(xfs_agino_t) - 1)); |
@@ -1809,6 +1821,10 @@ xfs_iunlink_remove( | |||
1809 | last_dip->di_next_unlinked = cpu_to_be32(next_agino); | 1821 | last_dip->di_next_unlinked = cpu_to_be32(next_agino); |
1810 | ASSERT(next_agino != 0); | 1822 | ASSERT(next_agino != 0); |
1811 | offset = last_offset + offsetof(xfs_dinode_t, di_next_unlinked); | 1823 | offset = last_offset + offsetof(xfs_dinode_t, di_next_unlinked); |
1824 | |||
1825 | /* need to recalc the inode CRC if appropriate */ | ||
1826 | xfs_dinode_calc_crc(mp, last_dip); | ||
1827 | |||
1812 | xfs_trans_inode_buf(tp, last_ibp); | 1828 | xfs_trans_inode_buf(tp, last_ibp); |
1813 | xfs_trans_log_buf(tp, last_ibp, offset, | 1829 | xfs_trans_log_buf(tp, last_ibp, offset, |
1814 | (offset + sizeof(xfs_agino_t) - 1)); | 1830 | (offset + sizeof(xfs_agino_t) - 1)); |