Lines Matching full:mp

44 	struct xfs_mount	*mp = sc->mp;  in xchk_setup_rtsummary()  local
49 rts = kvzalloc(struct_size(rts, words, mp->m_blockwsize), in xchk_setup_rtsummary()
66 error = xfile_create(descr, XFS_FSB_TO_B(mp, mp->m_rsumblocks), in xchk_setup_rtsummary()
76 error = xchk_install_live_inode(sc, mp->m_rsumip); in xchk_setup_rtsummary()
90 xfs_ilock(mp->m_rbmip, XFS_ILOCK_SHARED | XFS_ILOCK_RTBITMAP); in xchk_setup_rtsummary()
98 if (mp->m_sb.sb_rblocks) { in xchk_setup_rtsummary()
101 rts->rextents = xfs_rtb_to_rtx(mp, mp->m_sb.sb_rblocks); in xchk_setup_rtsummary()
104 rts->rbmblocks = xfs_rtbitmap_blockcount(mp, rts->rextents); in xchk_setup_rtsummary()
105 rts->rsumblocks = xfs_rtsummary_blockcount(mp, rts->rsumlevels, in xchk_setup_rtsummary()
148 struct xfs_mount *mp, in xchk_rtsum_inc() argument
158 struct xfs_mount *mp, in xchk_rtsum_record_free() argument
177 rbmoff = xfs_rtx_to_rbmblock(mp, rec->ar_startext); in xchk_rtsum_record_free()
179 offs = xfs_rtsumoffs(mp, lenlog, rbmoff); in xchk_rtsum_record_free()
181 rtbno = xfs_rtx_to_rtb(mp, rec->ar_startext); in xchk_rtsum_record_free()
182 rtlen = xfs_rtx_to_rtb(mp, rec->ar_extcount); in xchk_rtsum_record_free()
184 if (!xfs_verify_rtbext(mp, rtbno, rtlen)) { in xchk_rtsum_record_free()
185 xchk_ino_xref_set_corrupt(sc, mp->m_rbmip->i_ino); in xchk_rtsum_record_free()
194 value = xchk_rtsum_inc(sc->mp, &v); in xchk_rtsum_record_free()
195 trace_xchk_rtsum_record_free(mp, rec->ar_startext, rec->ar_extcount, in xchk_rtsum_record_free()
206 struct xfs_mount *mp = sc->mp; in xchk_rtsum_compute() local
210 rtbmp_blocks = xfs_rtbitmap_blockcount(mp, mp->m_sb.sb_rextents); in xchk_rtsum_compute()
211 if (XFS_FSB_TO_B(mp, rtbmp_blocks) != mp->m_rbmip->i_disk_size) in xchk_rtsum_compute()
214 return xfs_rtalloc_query_all(sc->mp, sc->tp, xchk_rtsum_record_free, in xchk_rtsum_compute()
226 struct xfs_mount *mp = sc->mp; in xchk_rtsum_compare() local
234 rts->args.mp = sc->mp; in xchk_rtsum_compare()
238 endoff = XFS_B_TO_FSB(mp, ip->i_disk_size); in xchk_rtsum_compare()
275 error = xfsum_copyout(sc, sumoff, rts->words, mp->m_blockwsize); in xchk_rtsum_compare()
283 mp->m_blockwsize << XFS_WORDLOG) != 0) { in xchk_rtsum_compare()
290 sumoff += mp->m_blockwsize; in xchk_rtsum_compare()
301 struct xfs_mount *mp = sc->mp; in xchk_rtsummary() local
306 if (mp->m_sb.sb_rextents != rts->rextents) { in xchk_rtsummary()
307 xchk_ino_set_corrupt(sc, mp->m_rbmip->i_ino); in xchk_rtsummary()
312 if (mp->m_rsumlevels != rts->rsumlevels) { in xchk_rtsummary()
313 xchk_ino_set_corrupt(sc, mp->m_rsumip->i_ino); in xchk_rtsummary()
318 if (mp->m_rsumblocks != rts->rsumblocks) { in xchk_rtsummary()
319 xchk_ino_set_corrupt(sc, mp->m_rsumip->i_ino); in xchk_rtsummary()
324 if (mp->m_rsumip->i_disk_size & mp->m_blockmask) { in xchk_rtsummary()
325 xchk_ino_set_corrupt(sc, mp->m_rsumip->i_ino); in xchk_rtsummary()
334 if (mp->m_rsumip->i_disk_size < XFS_FSB_TO_B(mp, rts->rsumblocks)) { in xchk_rtsummary()
335 xchk_ino_set_corrupt(sc, mp->m_rsumip->i_ino); in xchk_rtsummary()
351 xchk_ino_xref_set_corrupt(sc, mp->m_rbmip->i_ino); in xchk_rtsummary()
368 xfs_iunlock(mp->m_rbmip, XFS_ILOCK_SHARED | XFS_ILOCK_RTBITMAP); in xchk_rtsummary()