Lines Matching refs:busyp
31 struct xfs_extent_busy *busyp; in xfs_extent_busy_insert() local
49 busyp = rb_entry(parent, struct xfs_extent_busy, rb_node); in xfs_extent_busy_insert()
51 if (new->bno < busyp->bno) { in xfs_extent_busy_insert()
53 ASSERT(new->bno + new->length <= busyp->bno); in xfs_extent_busy_insert()
54 } else if (new->bno > busyp->bno) { in xfs_extent_busy_insert()
56 ASSERT(bno >= busyp->bno + busyp->length); in xfs_extent_busy_insert()
86 struct xfs_extent_busy *busyp; in xfs_extent_busy_search() local
93 busyp = rb_entry(rbp, struct xfs_extent_busy, rb_node); in xfs_extent_busy_search()
94 if (bno < busyp->bno) { in xfs_extent_busy_search()
96 if (bno + len > busyp->bno) in xfs_extent_busy_search()
99 } else if (bno > busyp->bno) { in xfs_extent_busy_search()
101 if (bno < busyp->bno + busyp->length) in xfs_extent_busy_search()
106 match = (busyp->length == len) ? 1 : -1; in xfs_extent_busy_search()
129 struct xfs_extent_busy *busyp, in xfs_extent_busy_update_extent() argument
136 xfs_agblock_t bbno = busyp->bno; in xfs_extent_busy_update_extent()
137 xfs_agblock_t bend = bbno + busyp->length; in xfs_extent_busy_update_extent()
144 if (busyp->flags & XFS_EXTENT_BUSY_DISCARDED) { in xfs_extent_busy_update_extent()
220 rb_erase(&busyp->rb_node, &pag->pagb_tree); in xfs_extent_busy_update_extent()
221 busyp->length = 0; in xfs_extent_busy_update_extent()
238 busyp->bno = fend; in xfs_extent_busy_update_extent()
239 busyp->length = bend - fend; in xfs_extent_busy_update_extent()
254 busyp->length = fbno - busyp->bno; in xfs_extent_busy_update_extent()
289 struct xfs_extent_busy *busyp = in xfs_extent_busy_reuse() local
291 xfs_agblock_t bbno = busyp->bno; in xfs_extent_busy_reuse()
292 xfs_agblock_t bend = bbno + busyp->length; in xfs_extent_busy_reuse()
302 if (!xfs_extent_busy_update_extent(mp, pag, busyp, fbno, flen, in xfs_extent_busy_reuse()
340 struct xfs_extent_busy *busyp = in xfs_extent_busy_trim() local
343 xfs_agblock_t bbno = busyp->bno; in xfs_extent_busy_trim()
344 xfs_agblock_t bend = bbno + busyp->length; in xfs_extent_busy_trim()
501 struct xfs_extent_busy *busyp) in xfs_extent_busy_clear_one() argument
503 if (busyp->length) { in xfs_extent_busy_clear_one()
504 trace_xfs_extent_busy_clear(mp, busyp->agno, busyp->bno, in xfs_extent_busy_clear_one()
505 busyp->length); in xfs_extent_busy_clear_one()
506 rb_erase(&busyp->rb_node, &pag->pagb_tree); in xfs_extent_busy_clear_one()
509 list_del_init(&busyp->list); in xfs_extent_busy_clear_one()
510 kmem_free(busyp); in xfs_extent_busy_clear_one()
539 struct xfs_extent_busy *busyp, *n; in xfs_extent_busy_clear() local
544 list_for_each_entry_safe(busyp, n, list, list) { in xfs_extent_busy_clear()
545 if (busyp->agno != agno) { in xfs_extent_busy_clear()
548 agno = busyp->agno; in xfs_extent_busy_clear()
554 if (do_discard && busyp->length && in xfs_extent_busy_clear()
555 !(busyp->flags & XFS_EXTENT_BUSY_SKIP_DISCARD)) { in xfs_extent_busy_clear()
556 busyp->flags = XFS_EXTENT_BUSY_DISCARDED; in xfs_extent_busy_clear()
558 xfs_extent_busy_clear_one(mp, pag, busyp); in xfs_extent_busy_clear()