Lines Matching refs:ldip
221 struct xfs_log_dinode *ldip) in xlog_dinode_verify_extent_counts() argument
226 if (xfs_log_dinode_has_large_extent_counts(ldip)) { in xlog_dinode_verify_extent_counts()
228 (ldip->di_nrext64_pad != 0)) { in xlog_dinode_verify_extent_counts()
231 XFS_ERRLEVEL_LOW, mp, ldip, sizeof(*ldip)); in xlog_dinode_verify_extent_counts()
234 ldip->di_ino, xfs_has_large_extent_counts(mp), in xlog_dinode_verify_extent_counts()
235 ldip->di_nrext64_pad); in xlog_dinode_verify_extent_counts()
239 nextents = ldip->di_big_nextents; in xlog_dinode_verify_extent_counts()
240 anextents = ldip->di_big_anextents; in xlog_dinode_verify_extent_counts()
242 if (ldip->di_version == 3 && ldip->di_v3_pad != 0) { in xlog_dinode_verify_extent_counts()
245 XFS_ERRLEVEL_LOW, mp, ldip, sizeof(*ldip)); in xlog_dinode_verify_extent_counts()
248 ldip->di_ino, ldip->di_v3_pad); in xlog_dinode_verify_extent_counts()
252 nextents = ldip->di_nextents; in xlog_dinode_verify_extent_counts()
253 anextents = ldip->di_anextents; in xlog_dinode_verify_extent_counts()
256 if (unlikely(nextents + anextents > ldip->di_nblocks)) { in xlog_dinode_verify_extent_counts()
258 XFS_ERRLEVEL_LOW, mp, ldip, sizeof(*ldip)); in xlog_dinode_verify_extent_counts()
261 ldip->di_ino, xfs_has_large_extent_counts(mp), nextents, in xlog_dinode_verify_extent_counts()
262 anextents, ldip->di_nblocks); in xlog_dinode_verify_extent_counts()
286 struct xfs_log_dinode *ldip; in xlog_recover_inode_commit_pass2() local
331 ldip = item->ri_buf[1].i_addr; in xlog_recover_inode_commit_pass2()
332 if (XFS_IS_CORRUPT(mp, ldip->di_magic != XFS_DINODE_MAGIC)) { in xlog_recover_inode_commit_pass2()
375 if (ldip->di_flushiter < be16_to_cpu(dip->di_flushiter)) { in xlog_recover_inode_commit_pass2()
381 ldip->di_flushiter < (DI_MAX_FLUSH >> 1)) { in xlog_recover_inode_commit_pass2()
391 ldip->di_flushiter = 0; in xlog_recover_inode_commit_pass2()
395 if (unlikely(S_ISREG(ldip->di_mode))) { in xlog_recover_inode_commit_pass2()
396 if ((ldip->di_format != XFS_DINODE_FMT_EXTENTS) && in xlog_recover_inode_commit_pass2()
397 (ldip->di_format != XFS_DINODE_FMT_BTREE)) { in xlog_recover_inode_commit_pass2()
400 XFS_ERRLEVEL_LOW, mp, ldip, sizeof(*ldip)); in xlog_recover_inode_commit_pass2()
403 in_f->ilf_ino, ldip->di_format); in xlog_recover_inode_commit_pass2()
407 } else if (unlikely(S_ISDIR(ldip->di_mode))) { in xlog_recover_inode_commit_pass2()
408 if ((ldip->di_format != XFS_DINODE_FMT_EXTENTS) && in xlog_recover_inode_commit_pass2()
409 (ldip->di_format != XFS_DINODE_FMT_BTREE) && in xlog_recover_inode_commit_pass2()
410 (ldip->di_format != XFS_DINODE_FMT_LOCAL)) { in xlog_recover_inode_commit_pass2()
413 XFS_ERRLEVEL_LOW, mp, ldip, sizeof(*ldip)); in xlog_recover_inode_commit_pass2()
416 in_f->ilf_ino, ldip->di_format); in xlog_recover_inode_commit_pass2()
422 error = xlog_dinode_verify_extent_counts(mp, ldip); in xlog_recover_inode_commit_pass2()
426 if (unlikely(ldip->di_forkoff > mp->m_sb.sb_inodesize)) { in xlog_recover_inode_commit_pass2()
428 XFS_ERRLEVEL_LOW, mp, ldip, sizeof(*ldip)); in xlog_recover_inode_commit_pass2()
431 in_f->ilf_ino, ldip->di_forkoff); in xlog_recover_inode_commit_pass2()
438 mp, ldip, sizeof(*ldip)); in xlog_recover_inode_commit_pass2()
456 xfs_log_dinode_to_disk(ldip, dip, current_lsn); in xlog_recover_inode_commit_pass2()