Lines Matching refs:bcp
44 struct xfs_buf_cancel *bcp; in xlog_find_buffer_cancelled() local
50 list_for_each_entry(bcp, bucket, bc_list) { in xlog_find_buffer_cancelled()
51 if (bcp->bc_blkno == blkno && bcp->bc_len == len) in xlog_find_buffer_cancelled()
52 return bcp; in xlog_find_buffer_cancelled()
64 struct xfs_buf_cancel *bcp; in xlog_add_buffer_cancelled() local
73 bcp = xlog_find_buffer_cancelled(log, blkno, len); in xlog_add_buffer_cancelled()
74 if (bcp) { in xlog_add_buffer_cancelled()
75 bcp->bc_refcount++; in xlog_add_buffer_cancelled()
79 bcp = kmem_alloc(sizeof(struct xfs_buf_cancel), 0); in xlog_add_buffer_cancelled()
80 bcp->bc_blkno = blkno; in xlog_add_buffer_cancelled()
81 bcp->bc_len = len; in xlog_add_buffer_cancelled()
82 bcp->bc_refcount = 1; in xlog_add_buffer_cancelled()
83 list_add_tail(&bcp->bc_list, XLOG_BUF_CANCEL_BUCKET(log, blkno)); in xlog_add_buffer_cancelled()
113 struct xfs_buf_cancel *bcp; in xlog_put_buffer_cancelled() local
115 bcp = xlog_find_buffer_cancelled(log, blkno, len); in xlog_put_buffer_cancelled()
116 if (!bcp) { in xlog_put_buffer_cancelled()
121 if (--bcp->bc_refcount == 0) { in xlog_put_buffer_cancelled()
122 list_del(&bcp->bc_list); in xlog_put_buffer_cancelled()
123 kmem_free(bcp); in xlog_put_buffer_cancelled()