Lines Matching full:mp
35 struct xfs_mount *mp, in xfs_failure_pgoff() argument
39 loff_t pos = XFS_FSB_TO_B(mp, rec->rm_offset); in xfs_failure_pgoff()
42 pos += XFS_FSB_TO_B(mp, in xfs_failure_pgoff()
49 struct xfs_mount *mp, in xfs_failure_pgcnt() argument
64 return XFS_FSB_TO_B(mp, end_cross - start_cross) >> PAGE_SHIFT; in xfs_failure_pgcnt()
73 struct xfs_mount *mp = cur->bc_mp; in xfs_dax_failure_fn() local
85 error = xfs_iget(mp, cur->bc_tp, rec->rm_owner, XFS_IGET_INCORE, in xfs_dax_failure_fn()
96 xfs_failure_pgoff(mp, rec, notify), in xfs_dax_failure_fn()
97 xfs_failure_pgcnt(mp, rec, notify), in xfs_dax_failure_fn()
105 struct xfs_mount *mp, in xfs_dax_notify_ddev_failure() argument
115 xfs_fsblock_t fsbno = XFS_DADDR_TO_FSB(mp, daddr); in xfs_dax_notify_ddev_failure()
116 xfs_agnumber_t agno = XFS_FSB_TO_AGNO(mp, fsbno); in xfs_dax_notify_ddev_failure()
117 xfs_fsblock_t end_fsbno = XFS_DADDR_TO_FSB(mp, daddr + bblen); in xfs_dax_notify_ddev_failure()
118 xfs_agnumber_t end_agno = XFS_FSB_TO_AGNO(mp, end_fsbno); in xfs_dax_notify_ddev_failure()
120 error = xfs_trans_alloc_empty(mp, &tp); in xfs_dax_notify_ddev_failure()
131 pag = xfs_perag_get(mp, agno); in xfs_dax_notify_ddev_failure()
138 cur = xfs_rmapbt_init_cursor(mp, tp, agf_bp, pag); in xfs_dax_notify_ddev_failure()
145 ri_low.rm_startblock = XFS_FSB_TO_AGBNO(mp, fsbno); in xfs_dax_notify_ddev_failure()
147 ri_high.rm_startblock = XFS_FSB_TO_AGBNO(mp, end_fsbno); in xfs_dax_notify_ddev_failure()
163 fsbno = XFS_AGB_TO_FSB(mp, agno + 1, 0); in xfs_dax_notify_ddev_failure()
168 xfs_force_shutdown(mp, SHUTDOWN_CORRUPT_ONDISK); in xfs_dax_notify_ddev_failure()
182 struct xfs_mount *mp = dax_holder(dax_dev); in xfs_dax_notify_failure() local
186 if (!(mp->m_super->s_flags & SB_BORN)) { in xfs_dax_notify_failure()
187 xfs_warn(mp, "filesystem is not ready for notify_failure()!"); in xfs_dax_notify_failure()
191 if (mp->m_rtdev_targp && mp->m_rtdev_targp->bt_daxdev == dax_dev) { in xfs_dax_notify_failure()
192 xfs_debug(mp, in xfs_dax_notify_failure()
197 if (mp->m_logdev_targp && mp->m_logdev_targp->bt_daxdev == dax_dev && in xfs_dax_notify_failure()
198 mp->m_logdev_targp != mp->m_ddev_targp) { in xfs_dax_notify_failure()
199 xfs_err(mp, "ondisk log corrupt, shutting down fs!"); in xfs_dax_notify_failure()
200 xfs_force_shutdown(mp, SHUTDOWN_CORRUPT_ONDISK); in xfs_dax_notify_failure()
204 if (!xfs_has_rmapbt(mp)) { in xfs_dax_notify_failure()
205 xfs_debug(mp, "notify_failure() needs rmapbt enabled!"); in xfs_dax_notify_failure()
209 ddev_start = mp->m_ddev_targp->bt_dax_part_off; in xfs_dax_notify_failure()
210 ddev_end = ddev_start + bdev_nr_bytes(mp->m_ddev_targp->bt_bdev) - 1; in xfs_dax_notify_failure()
228 return xfs_dax_notify_ddev_failure(mp, BTOBB(offset), BTOBB(len), in xfs_dax_notify_failure()